Commit eaae35b4c482088a8e5092923520eda82998d432
1 parent
46ee72669d
Exists in
master
and in
6 other branches
update
Showing 2 changed files with 83 additions and 2 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/AntExRecordFacade.java
View file @
eaae35b
... | ... | @@ -275,12 +275,17 @@ |
275 | 275 | } |
276 | 276 | } |
277 | 277 | } |
278 | + //产检医院,省市县医院 | |
279 | + if (StringUtils.isNotEmpty(antExManagerQueryRequest.gethId()) &&( | |
280 | + StringUtils.isEmpty(antExManagerQueryRequest.getCzhospitalId()) || StringUtils.isEmpty(antExManagerQueryRequest.getCzcityId()) | |
281 | + || StringUtils.isEmpty(antExManagerQueryRequest.getCzareaId())|| StringUtils.isEmpty(antExManagerQueryRequest.getCzhospitalId()) ) ) { | |
278 | 282 | |
279 | - if (org.apache.commons.lang.StringUtils.isNotEmpty(antExManagerQueryRequest.gethId())) { | |
280 | 283 | List<String> orgId = new ArrayList<>(); |
281 | 284 | orgId.add(antExManagerQueryRequest.gethId()); |
282 | 285 | hospitalList.retainAll(orgId); |
283 | - } else if (com.lyms.platform.common.utils.StringUtils.isNotEmpty(antExManagerQueryRequest.getCprovinceId())) { | |
286 | + } else if (com.lyms.platform.common.utils.StringUtils.isNotEmpty(antExManagerQueryRequest.getCprovinceId()) &&( | |
287 | + StringUtils.isEmpty(antExManagerQueryRequest.getCzhospitalId()) || StringUtils.isEmpty(antExManagerQueryRequest.getCzcityId()) | |
288 | + || StringUtils.isEmpty(antExManagerQueryRequest.getCzareaId())|| StringUtils.isEmpty(antExManagerQueryRequest.getCzhospitalId()))) { | |
284 | 289 | OrganizationQuery organizationQuery = new OrganizationQuery(); |
285 | 290 | organizationQuery.setYn(YnEnums.YES.getId()); |
286 | 291 | organizationQuery.setProvinceId(antExManagerQueryRequest.getCprovinceId()); |
287 | 292 | |
... | ... | @@ -301,7 +306,42 @@ |
301 | 306 | } |
302 | 307 | hospitalList.retainAll(orgId); |
303 | 308 | } |
309 | + | |
310 | + //初诊医院,省市县医院 | |
311 | + if (StringUtils.isNotEmpty(antExManagerQueryRequest.getCzhospitalId()) && ( | |
312 | + StringUtils.isEmpty(antExManagerQueryRequest.gethId()) || StringUtils.isEmpty(antExManagerQueryRequest.getCprovinceId()) | |
313 | + || StringUtils.isEmpty(antExManagerQueryRequest.getCcityId()) || StringUtils.isEmpty(antExManagerQueryRequest.getCareaId()) )) { | |
314 | + | |
315 | + List<String> orgId = new ArrayList<>(); | |
316 | + orgId.add(antExManagerQueryRequest.getCzhospitalId()); | |
317 | + hospitalList.retainAll(orgId); | |
318 | + } else if (com.lyms.platform.common.utils.StringUtils.isNotEmpty(antExManagerQueryRequest.getCzprovinceId())&& ( | |
319 | + StringUtils.isEmpty(antExManagerQueryRequest.gethId()) || StringUtils.isEmpty(antExManagerQueryRequest.getCprovinceId()) | |
320 | + || StringUtils.isEmpty(antExManagerQueryRequest.getCcityId()) || StringUtils.isEmpty(antExManagerQueryRequest.getCareaId()) )) { | |
321 | + OrganizationQuery organizationQuery = new OrganizationQuery(); | |
322 | + organizationQuery.setYn(YnEnums.YES.getId()); | |
323 | + organizationQuery.setProvinceId(antExManagerQueryRequest.getCzprovinceId()); | |
324 | + if (com.lyms.platform.common.utils.StringUtils.isNotEmpty(antExManagerQueryRequest.getCzcityId())) { | |
325 | + organizationQuery.setCityId(antExManagerQueryRequest.getCzcityId()); | |
326 | + if (com.lyms.platform.common.utils.StringUtils.isNotEmpty(antExManagerQueryRequest.getCzareaId())) { | |
327 | + organizationQuery.setAreaId(antExManagerQueryRequest.getCzareaId()); | |
328 | + } | |
329 | + } | |
330 | + List<String> orgId = new ArrayList<>(); | |
331 | + List<Organization> organizations = organizationService.queryOrganization(organizationQuery); | |
332 | + if (CollectionUtils.isNotEmpty(organizations)) { | |
333 | + for (Organization org : organizations) { | |
334 | + if (null != org.getId()) { | |
335 | + orgId.add(org.getId() + ""); | |
336 | + } | |
337 | + } | |
338 | + } | |
339 | + hospitalList.retainAll(orgId); | |
340 | + } | |
341 | + // 产检医院,初诊医院只能选择其中一个查询 | |
304 | 342 | antExRecordQuery.setHospitalList(hospitalList); |
343 | + | |
344 | + | |
305 | 345 | } else { |
306 | 346 | String hospital = autoMatchFacade.getHospitalId(userId); |
307 | 347 | antExRecordQuery.setHospitalId(hospital); |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/request/AntExManagerQueryRequest.java
View file @
eaae35b
... | ... | @@ -16,6 +16,15 @@ |
16 | 16 | @Form |
17 | 17 | public class AntExManagerQueryRequest extends BasePageQueryRequest { |
18 | 18 | |
19 | + //初诊省份 | |
20 | + private String czprovinceId; | |
21 | + //初诊城市 | |
22 | + private String czcityId; | |
23 | + //初诊区域 | |
24 | + private String czareaId; | |
25 | + // 初诊医院id | |
26 | + private String czhospitalId; | |
27 | + | |
19 | 28 | //类型 1 复诊 2 初诊 |
20 | 29 | private Integer type; |
21 | 30 | /*滦平 start 20201105 */ |
... | ... | @@ -474,6 +483,38 @@ |
474 | 483 | |
475 | 484 | public void setBarCode(String barCode) { |
476 | 485 | this.barCode = barCode; |
486 | + } | |
487 | + | |
488 | + public String getCzprovinceId() { | |
489 | + return czprovinceId; | |
490 | + } | |
491 | + | |
492 | + public void setCzprovinceId(String czprovinceId) { | |
493 | + this.czprovinceId = czprovinceId; | |
494 | + } | |
495 | + | |
496 | + public String getCzcityId() { | |
497 | + return czcityId; | |
498 | + } | |
499 | + | |
500 | + public void setCzcityId(String czcityId) { | |
501 | + this.czcityId = czcityId; | |
502 | + } | |
503 | + | |
504 | + public String getCzareaId() { | |
505 | + return czareaId; | |
506 | + } | |
507 | + | |
508 | + public void setCzareaId(String czareaId) { | |
509 | + this.czareaId = czareaId; | |
510 | + } | |
511 | + | |
512 | + public String getCzhospitalId() { | |
513 | + return czhospitalId; | |
514 | + } | |
515 | + | |
516 | + public void setCzhospitalId(String czhospitalId) { | |
517 | + this.czhospitalId = czhospitalId; | |
477 | 518 | } |
478 | 519 | } |