Commit b05d5e7c0d81c2913f5f7fa55918eeb494914325
1 parent
1d0c4a6fbe
Exists in
master
and in
6 other branches
威海体重
Showing 1 changed file with 8 additions and 3 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/service/impl/PatientWeightServiceImpl.java
View file @
b05d5e7
... | ... | @@ -1760,9 +1760,13 @@ |
1760 | 1760 | if (patient != null) |
1761 | 1761 | { |
1762 | 1762 | |
1763 | - PatientWeight patientWeight = mongoTemplate.findOne(Query.query(Criteria.where("patientId").is(patient.getId()).and("yn").ne("1")), PatientWeight.class); | |
1764 | - if (type == 1 && patientWeight != null) | |
1763 | + PatientWeight patientWeight = mongoTemplate.findOne(Query.query(Criteria.where("patientId").is(patient.getId()).and("yn").is("1")), PatientWeight.class); | |
1764 | + if (patientWeight == null) | |
1765 | 1765 | { |
1766 | + continue; | |
1767 | + } | |
1768 | + if (type == 1) | |
1769 | + { | |
1766 | 1770 | Date currentDate = new Date(); |
1767 | 1771 | DateUtil.formatYmd(currentDate); |
1768 | 1772 | if (!(patientWeight.getModified().getTime() < new Date().getTime() |
1769 | 1773 | |
... | ... | @@ -1811,10 +1815,11 @@ |
1811 | 1815 | mr.setTempId(""); |
1812 | 1816 | mr.setPatientId(patient.getId()); |
1813 | 1817 | mr.setSmsStatus(SmsStatusEnums.WFS.getId()); |
1814 | - mr.setServiceType(1); //判断发送类型 | |
1818 | + mr.setServiceType(startType); //判断发送类型 | |
1815 | 1819 | |
1816 | 1820 | PatientServiceQuery patientQuery = new PatientServiceQuery(); |
1817 | 1821 | patientQuery.setHospitalId(patient.getHospitalId()); |
1822 | + patientQuery.setParentid(patientId); | |
1818 | 1823 | patientQuery.setSerType(PatientSerEnums.SerTypeEnums.tz.getId()); |
1819 | 1824 | |
1820 | 1825 | List<PatientService> patientServices = patientServiceService.queryPatientService(patientQuery); |