Commit d7f105c798f126d79d30422f3c512312bc491a9c
Exists in
master
and in
6 other branches
Merge remote-tracking branch 'origin/master'
Showing 4 changed files
- platform-dal/src/main/java/com/lyms/platform/query/BabyModelQuery.java
- platform-dal/src/main/java/com/lyms/platform/query/MatDeliverFollowQuery.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/worker/DueOrgCountWorker.java
platform-dal/src/main/java/com/lyms/platform/query/BabyModelQuery.java
View file @
d7f105c
... | ... | @@ -931,6 +931,22 @@ |
931 | 931 | } |
932 | 932 | } |
933 | 933 | |
934 | + if (null != babyWeightStart) { | |
935 | + if (null != c) { | |
936 | + c = c.and("babyWeight").gte(babyWeightStart); | |
937 | + } else { | |
938 | + c = Criteria.where("babyWeight").gte(babyWeightStart); | |
939 | + } | |
940 | + } | |
941 | + | |
942 | + if (null != babyWeightEnd) { | |
943 | + if (null != c) { | |
944 | + c = c.lte(babyWeightEnd); | |
945 | + } else { | |
946 | + c = Criteria.where("babyWeight").lte(babyWeightEnd); | |
947 | + } | |
948 | + } | |
949 | + | |
934 | 950 | |
935 | 951 | if (null != buildDateStart) { |
936 | 952 | if (null != c) { |
platform-dal/src/main/java/com/lyms/platform/query/MatDeliverFollowQuery.java
View file @
d7f105c
... | ... | @@ -253,12 +253,6 @@ |
253 | 253 | condition = condition.and("hospitalId",hospitalId , MongoOper.IS); |
254 | 254 | } |
255 | 255 | |
256 | - if (visitStartDate!=null) { | |
257 | - condition = condition.and("visitDate",visitStartDate , MongoOper.GTE); | |
258 | - } | |
259 | - if (visitEndDate!=null) { | |
260 | - condition = condition.and("visitDate",visitEndDate , MongoOper.LTE); | |
261 | - } | |
262 | 256 | if (StringUtils.isNotBlank(deliverId)) { |
263 | 257 | condition = condition.and("deliverId",deliverId , MongoOper.IS); |
264 | 258 | } |
... | ... | @@ -286,6 +280,9 @@ |
286 | 280 | Criteria c = null; |
287 | 281 | if(null != createdTimeStart && createdTimeEnd != null){ |
288 | 282 | c = Criteria.where("createDate").gte(createdTimeStart).lte(createdTimeEnd); |
283 | + } | |
284 | + if(null != visitStartDate && visitEndDate != null){ | |
285 | + c = Criteria.where("visitDate").gte(visitStartDate).lte(visitEndDate); | |
289 | 286 | } |
290 | 287 | if(null != updateDateStart && updateDateEnd != null){ |
291 | 288 | c = Criteria.where("updateDate").gte(updateDateStart).lte(updateDateEnd); |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/MatDeliverFacade.java
View file @
d7f105c
... | ... | @@ -752,6 +752,13 @@ |
752 | 752 | } |
753 | 753 | } |
754 | 754 | } |
755 | + else | |
756 | + { | |
757 | + if (CollectionUtils.isNotEmpty(updateBaby) && updateBaby.get(0).getDataStatus() == null) | |
758 | + { | |
759 | + babyModel1.setDataStatus(1); | |
760 | + } | |
761 | + } | |
755 | 762 | } else { |
756 | 763 | babyModel1.setYn(YnEnums.NO.getId()); |
757 | 764 | if (CollectionUtils.isNotEmpty(updateBaby)) { |
... | ... | @@ -2605,7 +2612,7 @@ |
2605 | 2612 | } |
2606 | 2613 | } |
2607 | 2614 | |
2608 | - public void exporDueOrgCount(String time, Integer userId, String hospitalId, String proviceId, | |
2615 | + public void exporDueOrgCount(String time, Integer userId, String hospitalId, String provinceId, | |
2609 | 2616 | String cityId, String areaId, HttpServletResponse httpServletResponse) { |
2610 | 2617 | |
2611 | 2618 | try { |
2612 | 2619 | |
... | ... | @@ -2624,12 +2631,12 @@ |
2624 | 2631 | } |
2625 | 2632 | |
2626 | 2633 | Map<String,String> params = new HashMap<>(); |
2627 | - params.put("proviceId",proviceId); | |
2634 | + params.put("provinceId",provinceId); | |
2628 | 2635 | params.put("cityId", cityId); |
2629 | 2636 | params.put("areaId", areaId); |
2630 | 2637 | |
2631 | 2638 | //获取用户拥有的权限医院和条件筛选的医院交集 |
2632 | - List<String> hospitalIds = areaCountFacade.getCurrentUserHospPermissions(userId, proviceId, | |
2639 | + List<String> hospitalIds = areaCountFacade.getCurrentUserHospPermissions(userId, provinceId, | |
2633 | 2640 | cityId, areaId); |
2634 | 2641 | |
2635 | 2642 | List<Map<String,String>> list = getDatas(hospitalIds, time,params, basicConfigs); |
... | ... | @@ -2673,7 +2680,7 @@ |
2673 | 2680 | } |
2674 | 2681 | } |
2675 | 2682 | |
2676 | - public BaseObjectResponse getDueOrgCount(String time, Integer userId, String hospitalId, String proviceId, String cityId, String areaId) { | |
2683 | + public BaseObjectResponse getDueOrgCount(String time, Integer userId, String hospitalId, String provinceId, String cityId, String areaId) { | |
2677 | 2684 | |
2678 | 2685 | |
2679 | 2686 | //本市户籍 |
2680 | 2687 | |
... | ... | @@ -2690,12 +2697,12 @@ |
2690 | 2697 | } |
2691 | 2698 | |
2692 | 2699 | Map<String,String> params = new HashMap<>(); |
2693 | - params.put("proviceId",proviceId); | |
2700 | + params.put("provinceId",provinceId); | |
2694 | 2701 | params.put("cityId", cityId); |
2695 | 2702 | params.put("areaId", areaId); |
2696 | 2703 | |
2697 | 2704 | //获取用户拥有的权限医院和条件筛选的医院交集 |
2698 | - List<String> hospitalIds = areaCountFacade.getCurrentUserHospPermissions(userId, proviceId, | |
2705 | + List<String> hospitalIds = areaCountFacade.getCurrentUserHospPermissions(userId, provinceId, | |
2699 | 2706 | cityId, areaId); |
2700 | 2707 | |
2701 | 2708 | List<Map<String,String>> list = getDatas(hospitalIds, time,params, basicConfigs); |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/worker/DueOrgCountWorker.java
View file @
d7f105c
... | ... | @@ -343,7 +343,7 @@ |
343 | 343 | if (StringUtils.isNotEmpty(time)) |
344 | 344 | { |
345 | 345 | babyModelQuery5.setBirthStart(DateUtil.getSNDate(time)[0]); |
346 | - babyModelQuery5.setBirthEnd(DateUtil.getSNDate(time)[1]); | |
346 | + babyModelQuery5.setBirthEnd(DateUtil.addDay(DateUtil.getSNDate(time)[1],1)); | |
347 | 347 | } |
348 | 348 | babyModelQuery5.setBabyWeightStart("4"); |
349 | 349 | int bigBoyCount = babyService.queryBabyCount(babyModelQuery5); |
350 | 350 | |
... | ... | @@ -357,11 +357,13 @@ |
357 | 357 | babyModelQuery6.setHospitalId(hospialId); |
358 | 358 | if (StringUtils.isNotEmpty(time)) |
359 | 359 | { |
360 | - babyModelQuery5.setBirthStart(DateUtil.getSNDate(time)[0]); | |
361 | - babyModelQuery5.setBirthEnd(DateUtil.getSNDate(time)[1]); | |
360 | + babyModelQuery6.setBirthStart(DateUtil.getSNDate(time)[0]); | |
361 | + babyModelQuery6.setBirthEnd(DateUtil.addDay(DateUtil.getSNDate(time)[1],1)); | |
362 | 362 | } |
363 | - babyModelQuery6.setBabyWeightEnd("2.5"); | |
364 | - int lowWeightCount = babyService.queryBabyCount(babyModelQuery5); | |
363 | + babyModelQuery6.setBabyWeightStart("0"); | |
364 | + babyModelQuery6.setBabyWeightEnd("2.6"); | |
365 | + | |
366 | + int lowWeightCount = babyService.queryBabyCount(babyModelQuery6); | |
365 | 367 | //低出生体重数 |
366 | 368 | map.put("lowWeightCount", String.valueOf(lowWeightCount)); |
367 | 369 | |
368 | 370 | |
... | ... | @@ -372,11 +374,11 @@ |
372 | 374 | if (StringUtils.isNotEmpty(time)) |
373 | 375 | { |
374 | 376 | patientsQuery1.setFmDateStart(DateUtil.getSNDate(time)[0]); |
375 | - patientsQuery1.setFmDateEnd(DateUtil.getSNDate(time)[1]); | |
377 | + patientsQuery1.setFmDateEnd(DateUtil.addDay(DateUtil.getSNDate(time)[1],1)); | |
376 | 378 | } |
377 | 379 | patientsQuery1.setFmHospital(hospialId); |
378 | 380 | patientsQuery1.setFmWeekStart(0); |
379 | - patientsQuery1.setFmWeekEnd(36); | |
381 | + patientsQuery1.setFmWeekEnd(36*7); | |
380 | 382 | List<Patients> patientses = patientsService.queryPatient(patientsQuery1); |
381 | 383 | if (CollectionUtils.isNotEmpty(patientses)) |
382 | 384 | { |
... | ... | @@ -396,7 +398,14 @@ |
396 | 398 | { |
397 | 399 | for (MaternalDeliverModel fm : fmList) |
398 | 400 | { |
399 | - zcBabyCount+=fm.getBaby().size(); | |
401 | + for (MaternalDeliverModel.Baby baby : fm.getBaby()) | |
402 | + { | |
403 | + //只统计活产 | |
404 | + if ("0".equals(baby.getPregnancyOut())) | |
405 | + { | |
406 | + zcBabyCount++; | |
407 | + } | |
408 | + } | |
400 | 409 | } |
401 | 410 | } |
402 | 411 | fmList.clear(); |
... | ... | @@ -419,6 +428,7 @@ |
419 | 428 | patientsQuery2.setType(3); |
420 | 429 | patientsQuery2.setProvinceRegisterId(params.get("provinceId")); |
421 | 430 | patientsQuery2.setNoCityRegisterId(params.get("cityId")); |
431 | + | |
422 | 432 | int bswsCount = patientsService.queryPatientCount(patientsQuery2); |
423 | 433 | map.put("bswsCount", String.valueOf(bswsCount)); |
424 | 434 | |
... | ... | @@ -433,7 +443,7 @@ |
433 | 443 | patientsQuery3.setFmHospital(hospialId); |
434 | 444 | patientsQuery3.setType(3); |
435 | 445 | patientsQuery3.setNoProvinceRegisterId(params.get("provinceId")); |
436 | - int wsCount = patientsService.queryPatientCount(patientsQuery2); | |
446 | + int wsCount = patientsService.queryPatientCount(patientsQuery3); | |
437 | 447 | map.put("wsCount", String.valueOf(wsCount)); |
438 | 448 | |
439 | 449 |