Commit 9213322ea243b5eff5ca741e077369bd3125a716
1 parent
d749c2c746
Exists in
dev
小程序调用-产后康复
Showing 1 changed file with 7 additions and 2 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/PatientFacade.java
View file @
9213322
| ... | ... | @@ -3917,11 +3917,16 @@ |
| 3917 | 3917 | if (chuModel != null) { |
| 3918 | 3918 | // 营养报告体重优先取后填的,其他逻辑不动 |
| 3919 | 3919 | PatientWeight patientWeight = mongoTemplate.findOne(Query.query(Criteria.where("patientId").is(p.getId())), PatientWeight.class); |
| 3920 | - if(patientWeight.getModified().compareTo(chuModel.getModified())>0){ | |
| 3921 | - patientBaseResult.setWeight(StringUtils.isNotEmpty(patientWeight.getNowWeight()) ? patientWeight.getNowWeight() : ""); | |
| 3920 | + if(patientWeight!= null){ | |
| 3921 | + if(patientWeight.getModified().compareTo(chuModel.getModified())>0){ | |
| 3922 | + patientBaseResult.setWeight(StringUtils.isNotEmpty(patientWeight.getNowWeight()) ? patientWeight.getNowWeight() : ""); | |
| 3923 | + }else{ | |
| 3924 | + patientBaseResult.setWeight(StringUtils.isNotEmpty(chuModel.getWeight()) ? chuModel.getWeight() : ""); | |
| 3925 | + } | |
| 3922 | 3926 | }else{ |
| 3923 | 3927 | patientBaseResult.setWeight(StringUtils.isNotEmpty(chuModel.getWeight()) ? chuModel.getWeight() : ""); |
| 3924 | 3928 | } |
| 3929 | + | |
| 3925 | 3930 | patientBaseResult.setBeforWeight(StringUtils.isNotEmpty(chuModel.getYqWeight()) ? chuModel.getYqWeight() : ""); |
| 3926 | 3931 | patientBaseResult.setHeight(StringUtils.isNotEmpty(chuModel.getHeight()) ? chuModel.getHeight() : ""); |
| 3927 | 3932 | if (StringUtils.isNotEmpty(chuModel.getHeight()) && StringUtils.isNotEmpty(chuModel.getWeight())) { |