Commit 0308e97e0999169310bea741467f54c6985ac93f
1 parent
9337de1edc
Exists in
master
and in
6 other branches
分娩记录
Showing 4 changed files with 41 additions and 9 deletions
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/MatDeliverController.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/MatDeliverFacade.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/request/ChildbirthManagerRequest.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/worker/MaterDeliverWorker.java
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/MatDeliverController.java
View file @
0308e97
... | ... | @@ -275,7 +275,7 @@ |
275 | 275 | { |
276 | 276 | String cdColum = "dueDate,fmHospital,name,age,cardNo,buildWeek,czWeek,hivkt," + |
277 | 277 | "syjg,ygbmky,dueWeek,deliveryMode,maternalInfo,tireNumber,livingNumber," + |
278 | - "deliverDoctor,phone,rhloseBloodL,gcStatus,recordsNum"; | |
278 | + "deliverDoctor,phone,rhloseBloodL,gcStatus,recordsNum,yyzyfmHospitalId,firstHospitalId"; | |
279 | 279 | childbirthManagerRequest.setInitQuery(cdColum); |
280 | 280 | childbirthManagerRequest.setInitQueryMap(childbirthManagerRequest.getInitQueryMapCd()); |
281 | 281 | } |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/MatDeliverFacade.java
View file @
0308e97
... | ... | @@ -2693,6 +2693,10 @@ |
2693 | 2693 | if (StringUtils.isNotEmpty(childbirthManagerRequest.getDeliverDoctor())&&"2100001605".equals(hid)) { |
2694 | 2694 | patientsQuery.setDeliverDoctor(childbirthManagerRequest.getDeliverDoctor()); |
2695 | 2695 | } |
2696 | + | |
2697 | + patientsQuery.setYyzyfmHospitalId(childbirthManagerRequest.getYyzyfmHospitalId()); | |
2698 | + patientsQuery.setHospitalId(childbirthManagerRequest.getFirstHospitalId()); | |
2699 | + | |
2696 | 2700 | System.out.println("fm patient query = "+ patientsQuery.convertToQuery().convertToMongoQuery()); |
2697 | 2701 | List <Patients> patientsList = patientsService.queryPatient(patientsQuery); |
2698 | 2702 |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/request/ChildbirthManagerRequest.java
View file @
0308e97
... | ... | @@ -192,7 +192,27 @@ |
192 | 192 | |
193 | 193 | //隆化接生医生 |
194 | 194 | private String deliverDoctor; |
195 | + //预约住院分娩医院id | |
196 | + private String yyzyfmHospitalId; | |
197 | + //建档医院id | |
198 | + private String firstHospitalId; | |
195 | 199 | |
200 | + public String getYyzyfmHospitalId() { | |
201 | + return yyzyfmHospitalId; | |
202 | + } | |
203 | + | |
204 | + public void setYyzyfmHospitalId(String yyzyfmHospitalId) { | |
205 | + this.yyzyfmHospitalId = yyzyfmHospitalId; | |
206 | + } | |
207 | + | |
208 | + public String getFirstHospitalId() { | |
209 | + return firstHospitalId; | |
210 | + } | |
211 | + | |
212 | + public void setFirstHospitalId(String firstHospitalId) { | |
213 | + this.firstHospitalId = firstHospitalId; | |
214 | + } | |
215 | + | |
196 | 216 | public String getDeliverDoctor() { |
197 | 217 | return deliverDoctor; |
198 | 218 | } |
... | ... | @@ -670,6 +690,8 @@ |
670 | 690 | initQueryMapCd.put("livingNumber", "活产数"); |
671 | 691 | initQueryMapCd.put("deliverDoctor", "接生医生"); |
672 | 692 | initQueryMapCd.put("phone", "联系方式"); |
693 | + initQueryMapCd.put("yyzyfmHospitalId", "预约住院分娩医院"); | |
694 | + initQueryMapCd.put("firstHospitalId", "首次建档医院"); | |
673 | 695 | initQueryMapCd.put("rhloseBloodL", "产后24小时内失血量"); |
674 | 696 | // initQueryMapCd.put("apgarScorePf1", "Apgar1分钟"); |
675 | 697 | // initQueryMapCd.put("apgarScorePf5", "Apgar5分钟"); |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/worker/MaterDeliverWorker.java
View file @
0308e97
... | ... | @@ -90,9 +90,8 @@ |
90 | 90 | childbirthManagerQueryModel.setCoupon(patients.isSendCoupon() == null |
91 | 91 | ? null : String.valueOf(patients.isSendCoupon())); |
92 | 92 | |
93 | - //建档机构的医院id | |
94 | - String hospitalId = null; | |
95 | 93 | |
94 | + | |
96 | 95 | // 承德定制使用 |
97 | 96 | if(antExService != null && initQuery.contains("fmHospital") && initQuery.contains("buildWeek") |
98 | 97 | && initQuery.contains("czWeek") && initQuery.contains("hivkt") |
... | ... | @@ -114,7 +113,6 @@ |
114 | 113 | List <Patients> patientsList = new ArrayList <>(); |
115 | 114 | //获取主档案 |
116 | 115 | Patients patients1 = mongoTemplate.findOne(Query.query(Criteria.where("id").is(patients.getSource())), Patients.class); |
117 | - hospitalId = patients1.getHospitalId(); | |
118 | 116 | patientsList.add(patients1); |
119 | 117 | //获取隐藏档案 |
120 | 118 | List<Patients> pats = mongoTemplate.find(Query.query(Criteria.where("source").is(patients.getSource()).and("enable").is("2")), Patients.class); |
... | ... | @@ -123,10 +121,6 @@ |
123 | 121 | setCzInfo(p, childbirthManagerQueryModel); |
124 | 122 | } |
125 | 123 | } |
126 | - else | |
127 | - { | |
128 | - hospitalId = patients.getHospitalId(); | |
129 | - } | |
130 | 124 | |
131 | 125 | } |
132 | 126 | |
... | ... | @@ -156,7 +150,19 @@ |
156 | 150 | } |
157 | 151 | |
158 | 152 | //建档机构 |
159 | - if(StringUtils.isNotEmpty(hospitalId)){ | |
153 | + if(initQuery.contains("firstHospitalId")){ | |
154 | + //建档机构的医院id | |
155 | + String hospitalId = null; | |
156 | + if(StringUtils.isEmpty(patients.getSource())) | |
157 | + { | |
158 | + hospitalId = patients.getHospitalId(); | |
159 | + } | |
160 | + else | |
161 | + { | |
162 | + //获取主档案 | |
163 | + Patients patients1 = mongoTemplate.findOne(Query.query(Criteria.where("id").is(patients.getSource())), Patients.class); | |
164 | + hospitalId = patients1.getHospitalId(); | |
165 | + } | |
160 | 166 | String organizationName = organizationService.getOrganizationName(hospitalId); |
161 | 167 | if(org.apache.commons.lang.StringUtils.isNotEmpty(organizationName)){ |
162 | 168 | childbirthManagerQueryModel.setFirstHospitalId(organizationName); |