Commit 5caccd0045b57572637137f4e7bb89f6d65c066d
1 parent
c26252dab3
Exists in
master
and in
6 other branches
分娩记录出生证明获取修改
Showing 1 changed file with 54 additions and 30 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/BookbuildingFacade.java
View file @
5caccd0
... | ... | @@ -1779,41 +1779,65 @@ |
1779 | 1779 | patient.setAreaPostRestId(yunRequest.getChildbirthAreaId()); |
1780 | 1780 | patient.setStreetPostRestId(yunRequest.getChildbirthStreetId()); |
1781 | 1781 | |
1782 | - //丈夫信息 | |
1783 | - patient.setHusbandName(yunRequest.getHusbandName()); | |
1784 | - patient.setHcertificateTypeId(yunRequest.getHusbandCertificateTypeId()); | |
1785 | 1782 | |
1786 | - if (StringUtils.isNotEmpty(yunRequest.getHusbandCertificateTypeId()) && StringUtils.isNotEmpty(yunRequest.getHusbandCertificateNum())) { | |
1787 | - BasicConfigQuery basicConfigQuery = new BasicConfigQuery(); | |
1788 | - basicConfigQuery.setId(yunRequest.getHusbandCertificateTypeId()); | |
1789 | - basicConfigQuery.setYn(YnEnums.YES.getId()); | |
1790 | - List<BasicConfig> data = basicConfigService.queryBasicConfig(basicConfigQuery); | |
1791 | - if (CollectionUtils.isNotEmpty(data)) { | |
1792 | - //身份证类型得到丈夫的生日 必须为身份证类型 | |
1793 | - if (StringUtils.isNotEmpty(data.get(0).getCode()) && "SFZ".endsWith(data.get(0).getCode())) { | |
1794 | - String cardNo = yunRequest.getHusbandCertificateNum(); | |
1795 | - Date birth = StringUtils.getBirthDay(cardNo); | |
1796 | - patient.setHusbandBirth(birth); | |
1783 | + if(yunRequest.getReqHusband() != null && yunRequest.getReqHusband()) | |
1784 | + { | |
1785 | + //丈夫信息 | |
1786 | + patient.setHusbandName(""); | |
1787 | + patient.setHcertificateTypeId(""); | |
1788 | + patient.setHusbandBirth(null); | |
1789 | + patient.setHcertificateNum(""); | |
1790 | + patient.setHusbandPhone(""); | |
1791 | + patient.setHcountryId(""); | |
1792 | + patient.setHnationId(""); | |
1793 | + patient.setHprofessionTypeId(""); | |
1794 | + patient.setHworkUnit(""); | |
1795 | + patient.setHaddressRegister(""); | |
1796 | + patient.setHprovinceRegisterId(""); | |
1797 | + patient.setHcityRegisterId(""); | |
1798 | + patient.setHareaRegisterId(""); | |
1799 | + patient.setHstreetRegisterId(""); | |
1800 | + patient.setHlevelTypeId(""); | |
1801 | + } | |
1802 | + else | |
1803 | + { | |
1804 | + //丈夫信息 | |
1805 | + patient.setHusbandName(yunRequest.getHusbandName()); | |
1806 | + patient.setHcertificateTypeId(yunRequest.getHusbandCertificateTypeId()); | |
1807 | + | |
1808 | + if (StringUtils.isNotEmpty(yunRequest.getHusbandCertificateTypeId()) && StringUtils.isNotEmpty(yunRequest.getHusbandCertificateNum())) { | |
1809 | + BasicConfigQuery basicConfigQuery = new BasicConfigQuery(); | |
1810 | + basicConfigQuery.setId(yunRequest.getHusbandCertificateTypeId()); | |
1811 | + basicConfigQuery.setYn(YnEnums.YES.getId()); | |
1812 | + List<BasicConfig> data = basicConfigService.queryBasicConfig(basicConfigQuery); | |
1813 | + if (CollectionUtils.isNotEmpty(data)) { | |
1814 | + //身份证类型得到丈夫的生日 必须为身份证类型 | |
1815 | + if (StringUtils.isNotEmpty(data.get(0).getCode()) && "SFZ".endsWith(data.get(0).getCode())) { | |
1816 | + String cardNo = yunRequest.getHusbandCertificateNum(); | |
1817 | + Date birth = StringUtils.getBirthDay(cardNo); | |
1818 | + patient.setHusbandBirth(birth); | |
1819 | + } | |
1797 | 1820 | } |
1798 | 1821 | } |
1799 | - } | |
1800 | 1822 | |
1801 | - if (StringUtils.isNotEmpty(yunRequest.getHusbandBirth())) {//如果前端传入的丈夫生日,则用传入的数据 | |
1802 | - patient.setHusbandBirth(DateUtil.parseYMD(yunRequest.getHusbandBirth())); | |
1823 | + if (StringUtils.isNotEmpty(yunRequest.getHusbandBirth())) {//如果前端传入的丈夫生日,则用传入的数据 | |
1824 | + patient.setHusbandBirth(DateUtil.parseYMD(yunRequest.getHusbandBirth())); | |
1825 | + } | |
1826 | + | |
1827 | + patient.setHcertificateNum(yunRequest.getHusbandCertificateNum()); | |
1828 | + patient.setHusbandPhone(yunRequest.getHusbandPhone()); | |
1829 | + patient.setHcountryId(yunRequest.getHusbandCountryId()); | |
1830 | + patient.setHnationId(yunRequest.getHusbandNationId()); | |
1831 | + patient.setHprofessionTypeId(yunRequest.getHusbandProfessionTypeId()); | |
1832 | + patient.setHworkUnit(yunRequest.getHusbandWorkUnit()); | |
1833 | + patient.setHaddressRegister(yunRequest.getHusbandAddressRegister()); | |
1834 | + patient.setHprovinceRegisterId(yunRequest.getHusbandProvinceRegisterId()); | |
1835 | + patient.setHcityRegisterId(yunRequest.getHusbandCityRegisterId()); | |
1836 | + patient.setHareaRegisterId(yunRequest.getHusbandAreaRegisterId()); | |
1837 | + patient.setHstreetRegisterId(yunRequest.getHusbandStreetRegisterId()); | |
1838 | + patient.setHlevelTypeId(yunRequest.getHusbandLevelTypeId()); | |
1803 | 1839 | } |
1804 | 1840 | |
1805 | - patient.setHcertificateNum(yunRequest.getHusbandCertificateNum()); | |
1806 | - patient.setHusbandPhone(yunRequest.getHusbandPhone()); | |
1807 | - patient.setHcountryId(yunRequest.getHusbandCountryId()); | |
1808 | - patient.setHnationId(yunRequest.getHusbandNationId()); | |
1809 | - patient.setHprofessionTypeId(yunRequest.getHusbandProfessionTypeId()); | |
1810 | - patient.setHworkUnit(yunRequest.getHusbandWorkUnit()); | |
1811 | - patient.setHaddressRegister(yunRequest.getHusbandAddressRegister()); | |
1812 | - patient.setHprovinceRegisterId(yunRequest.getHusbandProvinceRegisterId()); | |
1813 | - patient.setHcityRegisterId(yunRequest.getHusbandCityRegisterId()); | |
1814 | - patient.setHareaRegisterId(yunRequest.getHusbandAreaRegisterId()); | |
1815 | - patient.setHstreetRegisterId(yunRequest.getHusbandStreetRegisterId()); | |
1816 | - patient.setHlevelTypeId(yunRequest.getHusbandLevelTypeId()); | |
1817 | 1841 | |
1818 | 1842 | if (yunRequest.getExpType() != null) { |
1819 | 1843 | if (yunRequest.getExpType() == ExpYunEnums.SGY.getId()) { |