Commit e382f32f4e57481e431e0652eb888efb809d44de
1 parent
831eec37ab
Exists in
master
and in
6 other branches
婚检
Showing 1 changed file with 13 additions and 0 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/service/impl/PreEugebicsServiceImpl.java
View file @
e382f32
| ... | ... | @@ -839,6 +839,19 @@ |
| 839 | 839 | query.setHospitalId(hospitalId); |
| 840 | 840 | query.setCertificateNum(cardNo); |
| 841 | 841 | List <PremaritalCheckup> hjList = premaritalCheckupService.queryPremaritalCheckup(query); |
| 842 | + if(CollectionUtils.isEmpty(hjList)) | |
| 843 | + { | |
| 844 | + Query yquery = new Query(); | |
| 845 | + yquery.addCriteria(Criteria.where("hospitalId").is(hospitalId)); | |
| 846 | + yquery.addCriteria(Criteria.where("husbandCardNo").is(cardNo)); | |
| 847 | + List <PreEugenicsBaseModel> yjList = mongoTemplate.find(yquery, PreEugenicsBaseModel.class); | |
| 848 | + if (CollectionUtils.isNotEmpty(yjList) && StringUtils.isNotEmpty(yjList.get(0).getWifeCardNo())) | |
| 849 | + { | |
| 850 | + query.setCertificateNum(yjList.get(0).getWifeCardNo()); | |
| 851 | + hjList = premaritalCheckupService.queryPremaritalCheckup(query); | |
| 852 | + } | |
| 853 | + } | |
| 854 | + | |
| 842 | 855 | if(CollectionUtils.isNotEmpty(hjList)){ |
| 843 | 856 | PremaritalCheckup premaritalCheckup = hjList.get(0); |
| 844 | 857 | map.put("menarcheAge", premaritalCheckup.getMenarcheAge());//初潮年龄 |