Commit 4a8863f122b1a789a694fb47dede285e3abbcac3

Authored by liquanyu
1 parent 04598a153e
Exists in master and in 1 other branch dev

update

Showing 8 changed files with 51 additions and 42 deletions

platform-biz-patient-service/src/main/java/com/lyms/platform/biz/service/AntenatalExaminationService.java View file @ 4a8863f
... ... @@ -152,6 +152,7 @@
152 152 PatientsQuery patientsQuery = new PatientsQuery();
153 153 patientsQuery.setYn(YnEnums.YES.getId());
154 154 patientsQuery.setPid(pid);
  155 + patientsQuery.setType(1);
155 156 List<Patients> pats = patientsService.queryPatient1(patientsQuery,"created");
156 157  
157 158 Map<String,List<Patients>> temps = new HashMap<String, List<Patients>>();
platform-biz-service/src/main/resources/mainOrm/master/MasterMysqlAntexc.xml View file @ 4a8863f
... ... @@ -2524,12 +2524,7 @@
2524 2524  
2525 2525 SELECT count(f.id) as matdeliverHivktCheckzqCount ,o.id as hospitalId from report_matdeliver f INNER JOIN organization o on f.fmHospital = o.id
2526 2526 INNER JOIN (select a.sourceId,a.checkTime from report_antexchu a where a.type =1 and a.hivkt is not null
2527   - <if test="startDate != null">
2528   - and a.checkTime >= #{startDate}
2529   - </if>
2530   - <if test="endDate != null">
2531   - and a.checkTime <![CDATA[ <= ]]> #{endDate}
2532   - </if>
  2527 +
2533 2528 ) c on c.sourceId= f.sourceId
2534 2529 where DATEDIFF(f.lastMenses,c.checkTime) <![CDATA[ <= ]]> 83
2535 2530 <if test="hospitalId != null and hospitalId != ''">
... ... @@ -2544,6 +2539,14 @@
2544 2539 <if test="areaId != null and areaId != ''">
2545 2540 and o.area_id = #{areaId,jdbcType=VARCHAR}
2546 2541 </if>
  2542 +
  2543 + <if test="startDate != null">
  2544 + and f.dueDate1 >= #{startDate}
  2545 + </if>
  2546 + <if test="endDate != null">
  2547 + and f.dueDate1 <![CDATA[ <= ]]> #{endDate}
  2548 + </if>
  2549 +
2547 2550 GROUP BY o.id
2548 2551  
2549 2552 </select>
... ... @@ -2552,12 +2555,7 @@
2552 2555 <select id="getHasMatdeliverHivktCheckzqCount" resultType="java.util.Map" parameterType="java.util.Map">
2553 2556 SELECT count(f.id) as hasMatdeliverHivktCheckzqCount ,o.id as hospitalId from report_matdeliver f INNER JOIN organization o on f.fmHospital = o.id
2554 2557 INNER JOIN (select a.sourceId,a.checkTime from report_antexchu a where a.type =1 and a.hivkt ='yang'
2555   - <if test="startDate != null">
2556   - and a.checkTime >= #{startDate}
2557   - </if>
2558   - <if test="endDate != null">
2559   - and a.checkTime <![CDATA[ <= ]]> #{endDate}
2560   - </if>
  2558 +
2561 2559 ) c on c.sourceId= f.sourceId
2562 2560 where DATEDIFF(f.lastMenses,c.checkTime) <![CDATA[ <= ]]> 83
2563 2561 <if test="hospitalId != null and hospitalId != ''">
... ... @@ -2571,6 +2569,12 @@
2571 2569 </if>
2572 2570 <if test="areaId != null and areaId != ''">
2573 2571 and o.area_id = #{areaId,jdbcType=VARCHAR}
  2572 + </if>
  2573 + <if test="startDate != null">
  2574 + and f.dueDate1 >= #{startDate}
  2575 + </if>
  2576 + <if test="endDate != null">
  2577 + and f.dueDate1 <![CDATA[ <= ]]> #{endDate}
2574 2578 </if>
2575 2579 GROUP BY o.id
2576 2580 </select>
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/AreaCountFacade.java View file @ 4a8863f
... ... @@ -349,8 +349,7 @@
349 349 hospitalIds.subList(i, end),
350 350 startTime,
351 351 endTime,
352   - checkStartTime,
353   - checkEndTime,
  352 +
354 353 pointType, recordService);
355 354 listFuture.add(commonThreadPool.submit(checkPointCountWorker));
356 355 }
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/BabyStatisticsManagerFacade.java View file @ 4a8863f
... ... @@ -176,10 +176,12 @@
176 176 return babyStatisticsManagerBuildDoctorListResult;
177 177 }
178 178 babyModelQuery.setHospitalId(hospitalId);
179   - List list = new ArrayList();
180   - list.add("1");
181   - list.add("2");
182   - babyModelQuery.setEnableListNot(list);
  179 + List buildType = new ArrayList();
  180 + buildType.add(1);//ๅ„ฟ็ซฅ็›ดๆŽฅๅปบๆกฃ
  181 + buildType.add(2);//ไบงๅฆ‡ๅˆ†ๅจฉๅปบๆกฃ
  182 + babyModelQuery.setBuildTypeList(buildType);
  183 + babyModelQuery.setDataStatus(true);//ๆŽ’้™ค่‡ชๅŠจๅปบๆกฃๆ•ฐๆฎ
  184 + System.out.println(babyModelQuery.convertToQuery().convertToMongoQuery().toString());
183 185 List<BabyModel> babyModelList = babyService.queryBabyWithQuery(babyModelQuery);
184 186 List<BabyStatisticsManagerBuildDoctorListQueryModel> babyStatisticsManagerBuildDoctorListQueryModelList = new ArrayList<>();
185 187 if (CollectionUtils.isNotEmpty(babyModelList)) {
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/PatientSyncMysqlFacade.java View file @ 4a8863f
... ... @@ -1303,6 +1303,7 @@
1303 1303 {
1304 1304 patientsQuery.setPage(page);
1305 1305 System.out.println("syncPatientsToMysql" + page);
  1306 + System.out.println("syncPatientsToMysql query "+patientsQuery.convertToQuery().convertToMongoQuery().toString());
1306 1307 List<Patients> patientses = patientsService.queryPatient(patientsQuery);
1307 1308 if (CollectionUtils.isEmpty(patientses))
1308 1309 {
... ... @@ -1347,7 +1348,8 @@
1347 1348 while (true)
1348 1349 {
1349 1350 antExChuQuery.setPage(page);
1350   - System.out.println("syncAntexchuToMysql"+page);
  1351 + System.out.println("syncAntexchuToMysql" + page);
  1352 + System.out.println("syncAntexchuToMysql query "+antExChuQuery.convertToQuery().convertToMongoQuery().toString());
1351 1353 List <AntExChuModel> antExChus = antenatalExaminationService.queryAntExChu(antExChuQuery);
1352 1354 if (CollectionUtils.isEmpty(antExChus))
1353 1355 {
... ... @@ -1487,6 +1489,7 @@
1487 1489 {
1488 1490 antExQuery.setPage(page);
1489 1491 System.out.println("syncAntexToMysql" + page);
  1492 + System.out.println("syncAntexToMysql query "+antExQuery.convertToQuery().convertToMongoQuery().toString());
1490 1493 List <AntenatalExaminationModel> antexs = antenatalExaminationService.queryLastAntenx(antExQuery);
1491 1494 if (CollectionUtils.isEmpty(antexs))
1492 1495 {
... ... @@ -1576,6 +1579,7 @@
1576 1579 {
1577 1580 matDeliverQuery.setPage(page);
1578 1581 System.out.println("syncMatdeliverToMysql" + page);
  1582 + System.out.println("syncMatdeliverToMysql query "+matDeliverQuery.convertToQuery().convertToMongoQuery().toString());
1579 1583 List <MaternalDeliverModel> maternalDeliverModels = matDeliverService.pageQuery(matDeliverQuery);
1580 1584 if (CollectionUtils.isEmpty(maternalDeliverModels))
1581 1585 {
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/PredictedStatisticsFacade.java View file @ 4a8863f
... ... @@ -129,6 +129,7 @@
129 129 PatientsQuery patientsQuery = new PatientsQuery();
130 130 patientsQuery.setYn(YnEnums.YES.getId());
131 131 List<Integer> typeList = new ArrayList<>();
  132 + patientsQuery.setDueStatus(0);
132 133 typeList.add(1);
133 134 typeList.add(3);
134 135 patientsQuery.setTypeList(typeList);
platform-operate-api/src/main/java/com/lyms/platform/operate/web/worker/CheckPointCountWorker.java View file @ 4a8863f
... ... @@ -42,8 +42,7 @@
42 42 private List<String> hospitalIds;
43 43 private Date startTime;
44 44 private Date endTime;
45   - private Date checkStartTime;
46   - private Date checkEndTime;
  45 +
47 46 private Integer pointType;
48 47  
49 48 private AntExRecordService recordService;
... ... @@ -55,8 +54,7 @@
55 54 List<String> hospitalIds,
56 55 Date startTime,
57 56 Date endTime,
58   - Date checkStartTime,
59   - Date checkEndTime,
  57 +
60 58 Integer pointType,
61 59 AntExRecordService recordService
62 60 ) {
... ... @@ -67,8 +65,7 @@
67 65 this.hospitalIds = hospitalIds;
68 66 this.startTime = startTime;
69 67 this.endTime = endTime;
70   - this.checkStartTime = checkStartTime;
71   - this.checkEndTime = checkEndTime;
  68 +
72 69 this.pointType = pointType;
73 70 this.recordService = recordService;
74 71 }
75 72  
... ... @@ -103,23 +100,23 @@
103 100 buildCount = patientsService.queryPatientCount(patientsQuery);
104 101 }
105 102  
106   - System.out.println("checkPoint buildCount = "+patientsQuery.convertToQuery().convertToMongoQuery());
107   - AntExChuQuery antExChuQuery1 = new AntExChuQuery();
108   - antExChuQuery1.setHospitalId(hId);
109   - antExChuQuery1.setCheckTimeStart(checkStartTime);
110   - antExChuQuery1.setCheckTimeEnd(checkEndTime);
111   - antExChuQuery1.setYn(YnEnums.YES.getId());
112   - System.out.println("checkPoint chuCount = " + antExChuQuery1.convertToQuery().convertToMongoQuery());
113   - int chuCount = antenatalExaminationService.queryAntExChuCount(antExChuQuery1.convertToQuery());
  103 +// System.out.println("checkPoint buildCount = "+patientsQuery.convertToQuery().convertToMongoQuery());
  104 +// AntExChuQuery antExChuQuery1 = new AntExChuQuery();
  105 +// antExChuQuery1.setHospitalId(hId);
  106 +// antExChuQuery1.setCheckTimeStart(checkStartTime);
  107 +// antExChuQuery1.setCheckTimeEnd(checkEndTime);
  108 +// antExChuQuery1.setYn(YnEnums.YES.getId());
  109 +// System.out.println("checkPoint chuCount = " + antExChuQuery1.convertToQuery().convertToMongoQuery());
  110 +// int chuCount = antenatalExaminationService.queryAntExChuCount(antExChuQuery1.convertToQuery());
  111 +//
  112 +// AntExQuery antExQuery = new AntExQuery();
  113 +// antExQuery.setStart(checkStartTime);
  114 +// antExQuery.setEnd(checkEndTime);
  115 +// antExQuery.setHospitalId(hId);
  116 +// antExQuery.setYn(YnEnums.YES.getId());
  117 +// int exCount = antenatalExaminationService.queryAntenatalExaminationCount(antExQuery.convertToQuery());
114 118  
115   - AntExQuery antExQuery = new AntExQuery();
116   - antExQuery.setStart(checkStartTime);
117   - antExQuery.setEnd(checkEndTime);
118   - antExQuery.setHospitalId(hId);
119   - antExQuery.setYn(YnEnums.YES.getId());
120   - int exCount = antenatalExaminationService.queryAntenatalExaminationCount(antExQuery.convertToQuery());
121   -
122   - if (buildCount == 0 && chuCount == 0 && exCount == 0) {
  119 + if (buildCount == 0 ) {
123 120 continue;
124 121 }
125 122 List<Future> futures = new ArrayList<>();
platform-operate-api/src/main/java/com/lyms/platform/operate/web/worker/CheckWeeksNumWorker.java View file @ 4a8863f
... ... @@ -57,6 +57,7 @@
57 57 {
58 58 antExRecordQuery.setcDueWeekStart(0);
59 59 antExRecordQuery.setcDueWeekEnd((12 + 1) * 7 - 1);
  60 + System.out.println(antExRecordQuery.convertToQuery().convertToMongoQuery().toString());
60 61 int itemnum12 = recordService.count(antExRecordQuery);
61 62 map.put("itemnum12",itemnum12);
62 63 }