Commit 6bfe551e4fd175aeea3dfe2383ac828452081946
1 parent
94dee293fb
Exists in
master
and in
6 other branches
设置修改分娩时间
Showing 1 changed file with 25 additions and 3 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/AntenatalExaminationFacade.java
View file @
6bfe551
... | ... | @@ -1109,7 +1109,7 @@ |
1109 | 1109 | Date currentDate = DateUtil.formatDate(new Date()); |
1110 | 1110 | |
1111 | 1111 | |
1112 | - if ((date.getTime() <= currentDate.getTime() || patients.getBuildType() == 2) || patients.getType() == 3 && patients.getFmDate() != null) { | |
1112 | + if ((date.getTime() <= currentDate.getTime() || patients.getBuildType() == 2|| patients.getIsAutoFm() == 1) || patients.getType() == 3 && patients.getFmDate() != null) { | |
1113 | 1113 | //建档记录 |
1114 | 1114 | if (null != patients.getHospitalId()) { |
1115 | 1115 | organization = organizationService.getOrganization(Integer.valueOf(patients.getHospitalId())); |
... | ... | @@ -1170,8 +1170,7 @@ |
1170 | 1170 | } |
1171 | 1171 | } |
1172 | 1172 | |
1173 | - | |
1174 | - if (null != map) { | |
1173 | + /*if (null != map) { | |
1175 | 1174 | Object obj = map.get(listDate.get(i).getId()); |
1176 | 1175 | if (obj instanceof MaternalDeliverModel) { |
1177 | 1176 | MaternalDeliverModel model = (MaternalDeliverModel) obj; |
... | ... | @@ -1180,6 +1179,29 @@ |
1180 | 1179 | } |
1181 | 1180 | |
1182 | 1181 | listData.add(new AntData((MaternalDeliverModel) obj, patientses.get(0).getLastMenses(), null != organization ? organization.getName() : "")); |
1182 | + } | |
1183 | + }*/ | |
1184 | + if (null != map) { | |
1185 | + MatDeliverQuery matDeliverQuery = new MatDeliverQuery(); | |
1186 | + matDeliverQuery.setYn(YnEnums.YES.getId()); | |
1187 | + matDeliverQuery.setPid(pid); | |
1188 | + matDeliverQuery.setNeStart(true); | |
1189 | + matDeliverQuery.setNeEnd(true); | |
1190 | + matDeliverQuery.setCreatedStart(dueDate); | |
1191 | + if (CollectionUtils.isNotEmpty(listDate)) { | |
1192 | + //下次建档记录前都是产后复查,如果没有下个产程的数据就直接显示 | |
1193 | + if (listDate.size() > 1 && i > 1) { | |
1194 | + matDeliverQuery.setEndStart(listDate.get(i - 1).getDate()); | |
1195 | + } | |
1196 | + } | |
1197 | + List<MaternalDeliverModel> l= matDeliverService.query(matDeliverQuery); | |
1198 | + if (CollectionUtils.isNotEmpty(l)) { | |
1199 | + MaternalDeliverModel model = l.get(0); | |
1200 | + if (null != model.getHospitalId()) { | |
1201 | + organization = organizationService.getOrganization(Integer.valueOf(model.getHospitalId())); | |
1202 | + } | |
1203 | + | |
1204 | + listData.add(new AntData((MaternalDeliverModel) model, patientses.get(0).getLastMenses(), null != organization ? organization.getName() : "")); | |
1183 | 1205 | } |
1184 | 1206 | } |
1185 | 1207 |