Commit 280157da91c20511d2f2345b4db7938694f1520a
1 parent
a6bf551e42
Exists in
master
and in
6 other branches
update
Showing 4 changed files with 45 additions and 17 deletions
- platform-common/src/main/java/com/lyms/platform/common/enums/EyeHighRiskEnums.java
- platform-common/src/main/java/com/lyms/platform/common/enums/HandleOpinionsEnums.java
- platform-dal/src/main/java/com/lyms/platform/pojo/BabyEyeCheck.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/service/impl/BabyEyeCheckServiceImpl.java
platform-common/src/main/java/com/lyms/platform/common/enums/EyeHighRiskEnums.java
View file @
280157d
platform-common/src/main/java/com/lyms/platform/common/enums/HandleOpinionsEnums.java
View file @
280157d
platform-dal/src/main/java/com/lyms/platform/pojo/BabyEyeCheck.java
View file @
280157d
... | ... | @@ -322,8 +322,8 @@ |
322 | 322 | //三棱镜右 |
323 | 323 | private String prismRight; |
324 | 324 | |
325 | - //合作 0合作 1签合作 | |
326 | - private Integer cooperation; | |
325 | + //合作 0欠合作 1不合作 | |
326 | + private String cooperation; | |
327 | 327 | |
328 | 328 | public Integer getVisionJudgment1() { |
329 | 329 | return visionJudgment1; |
330 | 330 | |
... | ... | @@ -365,11 +365,11 @@ |
365 | 365 | this.prismRight = prismRight; |
366 | 366 | } |
367 | 367 | |
368 | - public Integer getCooperation() { | |
368 | + public String getCooperation() { | |
369 | 369 | return cooperation; |
370 | 370 | } |
371 | 371 | |
372 | - public void setCooperation(Integer cooperation) { | |
372 | + public void setCooperation(String cooperation) { | |
373 | 373 | this.cooperation = cooperation; |
374 | 374 | } |
375 | 375 |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/service/impl/BabyEyeCheckServiceImpl.java
View file @
280157d
... | ... | @@ -2,6 +2,7 @@ |
2 | 2 | |
3 | 3 | import com.lyms.platform.biz.service.BasicConfigService; |
4 | 4 | import com.lyms.platform.biz.service.YunBookbuildingService; |
5 | +import com.lyms.platform.common.dao.BaseQuery; | |
5 | 6 | import com.lyms.platform.common.enums.*; |
6 | 7 | import com.lyms.platform.common.pojo.SyncDataModel; |
7 | 8 | import com.lyms.platform.common.result.*; |
... | ... | @@ -19,10 +20,7 @@ |
19 | 20 | import com.lyms.platform.operate.web.utils.ResponseUtil; |
20 | 21 | import com.lyms.platform.permission.dao.master.BabyEyeCheckMapper; |
21 | 22 | import com.lyms.platform.permission.dao.master.CouponMapper; |
22 | -import com.lyms.platform.pojo.BabyEyeCheck; | |
23 | -import com.lyms.platform.pojo.BabyModel; | |
24 | -import com.lyms.platform.pojo.FilePathModel; | |
25 | -import com.lyms.platform.pojo.Patients; | |
23 | +import com.lyms.platform.pojo.*; | |
26 | 24 | import org.apache.commons.collections.map.HashedMap; |
27 | 25 | import org.springframework.beans.factory.annotation.Autowired; |
28 | 26 | import org.springframework.data.domain.Sort; |
29 | 27 | |
30 | 28 | |
... | ... | @@ -96,12 +94,12 @@ |
96 | 94 | |
97 | 95 | if ("yang".equals(babyEyeCheck.getExtRightEyelook()) || "yang".equals(babyEyeCheck.getExtLeftEyelook()) || "yang".equals(babyEyeCheck.getBlinkRightReflex()) |
98 | 96 | || "yang".equals(babyEyeCheck.getBlinkLefttReflex()) || "yang".equals(babyEyeCheck.getPupillaryRightReflex()) || "yang".equals(babyEyeCheck.getPupillaryLeftReflex()) |
99 | - || "yang".equals(babyEyeCheck.getRedRightReflex()) || "yang".equals(babyEyeCheck.getRedLeftReflex()) || "yang".equals(babyEyeCheck.getRedReflex()) || "ruoyang".equals(babyEyeCheck.getRedReflex()) | |
97 | + || "yang".equals(babyEyeCheck.getRedRightReflex()) || "yang".equals(babyEyeCheck.getRedLeftReflex()) || "yang".equals(babyEyeCheck.getRedReflex()) | |
100 | 98 | || "yang".equals(babyEyeCheck.getConjunctiva()) || "yang".equals(babyEyeCheck.getCorneal()) || "yang".equals(babyEyeCheck.getLacrimalApparatus()) |
101 | 99 | || "yang".equals(babyEyeCheck.getNystagmus()) || "yang".equals(babyEyeCheck.getExtEyelook()) |
102 | 100 | || "ruoyang".equals(babyEyeCheck.getRedRightReflex()) || "ruoyang".equals(babyEyeCheck.getRedLeftReflex()) |
101 | + || "ruoyang".equals(babyEyeCheck.getRedReflex()) | |
103 | 102 | |
104 | - | |
105 | 103 | ) { |
106 | 104 | //器械判定阳性 |
107 | 105 | babyEyeCheck.setApparatus("2"); |
... | ... | @@ -323,7 +321,7 @@ |
323 | 321 | |
324 | 322 | map.put("prismLeft", babyEyeCheck.getPrismLeft()); |
325 | 323 | map.put("prismRight", babyEyeCheck.getPrismRight()); |
326 | - map.put("cooperation", babyEyeCheck.getCooperation() == null ? "" : babyEyeCheck.getCooperation() == 0 ? "合作" : "欠合作"); | |
324 | + map.put("cooperation", !StringUtils.isNotEmpty(babyEyeCheck.getCooperation()) ? "" : "0".equals(babyEyeCheck.getCooperation()) ? "欠合作" : "不合作"); | |
327 | 325 | |
328 | 326 | FilePathModel filePath = yunBookbuildingService.findFilePathByBabyId(babyEyeCheck.getId()); |
329 | 327 | map.put("filePath", filePath); |
... | ... | @@ -407,7 +405,10 @@ |
407 | 405 | } |
408 | 406 | |
409 | 407 | @Override |
410 | - public BaseResponse list(Integer userId, Date startDate, Date endDate, String doctor, String key, Integer currentMonthStart, Integer currentMonthEnd, String chechMonth, boolean positive, String positiveIds, Integer page, Integer limit, Date bookStartDate, Date bookEndDate, String apparatusPositive, String doctorPositive, String yin) { | |
408 | + public BaseResponse list(Integer userId, Date startDate, Date endDate, String doctor, String key, Integer currentMonthStart, | |
409 | + Integer currentMonthEnd, String chechMonth, boolean positive, String positiveIds, | |
410 | + Integer page, Integer limit, Date bookStartDate, Date bookEndDate, | |
411 | + String apparatusPositive, String doctorPositive, String yin) { | |
411 | 412 | String hospitalId = autoMatchFacade.getHospitalId(userId); |
412 | 413 | Criteria criteria = Criteria.where("yn").ne("0").and("hospitalId").is(hospitalId); |
413 | 414 | if (startDate != null && endDate != null) { |
414 | 415 | |
415 | 416 | |
... | ... | @@ -444,10 +445,20 @@ |
444 | 445 | criteria.and("babyId").in(babyIds); |
445 | 446 | } |
446 | 447 | if (positive) { |
448 | + | |
447 | 449 | Query query = new Query(criteria); |
448 | 450 | query.with(new Sort(Sort.Direction.DESC, "checkTime")); |
451 | + query.addCriteria(new Criteria().orOperator(Criteria.where("apparatus").is("2"), Criteria.where("doctorJudgement").is("2"))); | |
452 | + System.out.println(query.toString()); | |
453 | + | |
454 | + int count = (int)mongoTemplate.count(query, BabyEyeCheck.class); | |
455 | + | |
456 | + BaseQuery param = new BaseQuery(); | |
457 | + param.mysqlBuild( count); | |
458 | + query.skip(param.getOffset()).limit(param.getLimit()); | |
459 | + | |
449 | 460 | List<BabyEyeCheck> babyEyeChecks = mongoTemplate.find(query, BabyEyeCheck.class); |
450 | - doFilter(babyEyeChecks); | |
461 | + // doFilter(babyEyeChecks); | |
451 | 462 | |
452 | 463 | if (StringUtils.isNotEmpty(positiveIds)) { |
453 | 464 | List<String> ids = CollectionUtils.asList(positiveIds, String.class); |
454 | 465 | |
... | ... | @@ -455,10 +466,10 @@ |
455 | 466 | doFilter(babyEyeChecks, ids); |
456 | 467 | } |
457 | 468 | } |
458 | - Integer count = babyEyeChecks.size(); | |
469 | + //Integer count = babyEyeChecks.size(); | |
459 | 470 | |
460 | - List<BabyEyeCheck> datas = CollectionUtils.getPageIds(babyEyeChecks, page, limit); | |
461 | - List<Map<String, Object>> maps = setDatas(datas); | |
471 | + // List<BabyEyeCheck> datas = CollectionUtils.getPageIds(babyEyeChecks, page, limit); | |
472 | + List<Map<String, Object>> maps = setDatas(babyEyeChecks); | |
462 | 473 | return RespBuilder.buildSuccess(new PageResult(count, page, limit, maps)); |
463 | 474 | } |
464 | 475 | PageResult pageResult = findMongoPage(BabyEyeCheck.class, new Query(criteria).with(new Sort(Sort.Direction.DESC, "checkTime")), page, limit); |
... | ... | @@ -567,6 +578,19 @@ |
567 | 578 | } |
568 | 579 | if ("yang".equals(babyEyeCheck.getRefraction2())) { |
569 | 580 | positive.append("屈光(医生判定)"); |
581 | + } | |
582 | + | |
583 | + if ("ruoyang".equals(babyEyeCheck.getRedRightReflex())) | |
584 | + { | |
585 | + positive.append("瞳孔红光反射(右)(稍减弱)"); | |
586 | + } | |
587 | + if ("ruoyang".equals(babyEyeCheck.getRedLeftReflex())) | |
588 | + { | |
589 | + positive.append("瞳孔红光反射(左)(稍减弱)"); | |
590 | + } | |
591 | + if ("ruoyang".equals(babyEyeCheck.getRedReflex())) | |
592 | + { | |
593 | + positive.append("红光反射(稍减弱)"); | |
570 | 594 | } |
571 | 595 | |
572 | 596 | temp.put("positive", positive.toString()); |