Commit ba9db040cbf96a9141e2cc6c25332aa3c23d4e4f
1 parent
97dc4911dd
Exists in
master
and in
6 other branches
自定义高危历史数据处理
Showing 6 changed files with 31 additions and 9 deletions
- platform-dal/src/main/java/com/lyms/platform/pojo/HosptialHighRisk.java
- platform-dal/src/main/java/com/lyms/platform/query/AntExQuery.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/TestController.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/HosptialHighRiskFacade.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/worker/AntexOtherHighRiskWorker.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/worker/AntexcOtherHighRiskWorker.java
platform-dal/src/main/java/com/lyms/platform/pojo/HosptialHighRisk.java
View file @
ba9db04
... | ... | @@ -35,6 +35,16 @@ |
35 | 35 | //颜色 |
36 | 36 | private String color; |
37 | 37 | |
38 | + private String colorName; | |
39 | + | |
40 | + public String getColorName() { | |
41 | + return colorName; | |
42 | + } | |
43 | + | |
44 | + public void setColorName(String colorName) { | |
45 | + this.colorName = colorName; | |
46 | + } | |
47 | + | |
38 | 48 | public String getCode() { |
39 | 49 | return code; |
40 | 50 | } |
platform-dal/src/main/java/com/lyms/platform/query/AntExQuery.java
View file @
ba9db04
... | ... | @@ -151,7 +151,6 @@ |
151 | 151 | } |
152 | 152 | if(null!=otherRisk){ |
153 | 153 | condition= condition.and("otherRisk",otherRisk, MongoOper.NE); |
154 | - condition= condition.and("otherRisk",true, MongoOper.EXISTS); | |
155 | 154 | } |
156 | 155 | if(null!=checkDoctor){ |
157 | 156 | condition= condition.and("checkDoctor",checkDoctor, MongoOper.IS); |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/TestController.java
View file @
ba9db04
... | ... | @@ -20,6 +20,7 @@ |
20 | 20 | import com.lyms.platform.operate.web.result.HighScoreResult; |
21 | 21 | import com.lyms.platform.operate.web.service.IBloodPressureService; |
22 | 22 | import com.lyms.platform.operate.web.service.SyncDataTaskService; |
23 | +import com.lyms.platform.operate.web.worker.AntexOtherHighRiskWorker; | |
23 | 24 | import com.lyms.platform.operate.web.worker.AntexcOtherHighRiskWorker; |
24 | 25 | import com.lyms.platform.operate.web.worker.BabyBuildSerToPatientSerWorker; |
25 | 26 | import com.lyms.platform.operate.web.worker.BuildSerToPatientSerWorker; |
... | ... | @@ -206,7 +207,7 @@ |
206 | 207 | int patientCount = antenatalExaminationService.queryAntenatalExaminationCount(antExQuery.convertToQuery()); |
207 | 208 | System.out.println("一共需要处理数据量:" + patientCount); |
208 | 209 | |
209 | - commonThreadPool.execute(new AntexcOtherHighRiskWorker(0, patientCount, antenatalExaminationService, hosptialHighRiskService, basicConfigService, 1000, patientCount)); | |
210 | + commonThreadPool.execute(new AntexOtherHighRiskWorker(0, patientCount, antenatalExaminationService, hosptialHighRiskService, basicConfigService, 1000, patientCount)); | |
210 | 211 | BaseResponse baseResponse = new BaseResponse(); |
211 | 212 | baseResponse.setErrormsg("一共需要处理数据量:" + patientCount); |
212 | 213 | return baseResponse; |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/HosptialHighRiskFacade.java
View file @
ba9db04
... | ... | @@ -40,6 +40,15 @@ |
40 | 40 | colorMap.put("315107bd-91fe-42a1-9237-752f3c046a40", "risk_" + RiskDefaultTypeEnum.getColor("黄色")); |
41 | 41 | } |
42 | 42 | |
43 | + private static Map<String, String> scoreMap = new HashMap<>(); | |
44 | + | |
45 | + static { | |
46 | + scoreMap.put("5769eef90cf22c3157577422", "5"); | |
47 | + scoreMap.put("5769f0640cf2d37f034793a3", "10"); | |
48 | + scoreMap.put("5769f0650cf2d37f034793a4", "15"); | |
49 | + scoreMap.put("5769f0650cf2d37f034793a5", "20"); | |
50 | + } | |
51 | + | |
43 | 52 | /** |
44 | 53 | * 页面初始化数据 |
45 | 54 | * |
... | ... | @@ -98,7 +107,10 @@ |
98 | 107 | List<HosptialHighRisk> hosptialHighRisks = hosptialHighRiskService.queryHosptialHighRisk(hosptialHighRiskQuery); |
99 | 108 | if (CollectionUtils.isNotEmpty(hosptialHighRisks)) { |
100 | 109 | for (HosptialHighRisk hr : hosptialHighRisks) { |
101 | - hr.setColor(colorMap.get(hr.getColor())); | |
110 | + hr.setColorName(colorMap.get(hr.getColor())); | |
111 | + if(scoreMap.containsKey(hr.getCode())){ | |
112 | + hr.setScore(Integer.parseInt(scoreMap.get(hr.getCode()))); | |
113 | + } | |
102 | 114 | } |
103 | 115 | baseResponse.setObject(hosptialHighRisks); |
104 | 116 | } |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/worker/AntexOtherHighRiskWorker.java
View file @
ba9db04
... | ... | @@ -7,7 +7,6 @@ |
7 | 7 | import com.lyms.platform.common.utils.JsonUtil; |
8 | 8 | import com.lyms.platform.common.utils.StringUtils; |
9 | 9 | import com.lyms.platform.operate.web.utils.CollectionUtils; |
10 | -import com.lyms.platform.operate.web.utils.FunvCommonUtil; | |
11 | 10 | import com.lyms.platform.pojo.AntenatalExaminationModel; |
12 | 11 | import com.lyms.platform.pojo.HosptialHighRisk; |
13 | 12 | import com.lyms.platform.query.AntExQuery; |
... | ... | @@ -83,8 +82,9 @@ |
83 | 82 | continue; |
84 | 83 | } |
85 | 84 | if (StringUtils.isNotEmpty(otherMap.get("fxpf"))) { |
86 | - String id = otherMap.get("fxpf").toString(); | |
87 | - pingfen = FunvCommonUtil.getBaseicConfigByid(id, basicConfigService); | |
85 | + // String id = otherMap.get("fxpf").toString(); | |
86 | + // pingfen = FunvCommonUtil.getBaseicConfigByid(id, basicConfigService); | |
87 | + pingfen = otherMap.get("fxpf").toString(); | |
88 | 88 | } else { |
89 | 89 | continue; |
90 | 90 | } |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/worker/AntexcOtherHighRiskWorker.java
View file @
ba9db04
... | ... | @@ -7,7 +7,6 @@ |
7 | 7 | import com.lyms.platform.common.utils.JsonUtil; |
8 | 8 | import com.lyms.platform.common.utils.StringUtils; |
9 | 9 | import com.lyms.platform.operate.web.utils.CollectionUtils; |
10 | -import com.lyms.platform.operate.web.utils.FunvCommonUtil; | |
11 | 10 | import com.lyms.platform.pojo.AntExChuModel; |
12 | 11 | import com.lyms.platform.pojo.HosptialHighRisk; |
13 | 12 | import com.lyms.platform.query.AntExChuQuery; |
... | ... | @@ -83,8 +82,9 @@ |
83 | 82 | continue; |
84 | 83 | } |
85 | 84 | if (StringUtils.isNotEmpty(otherMap.get("fxpf"))) { |
86 | - String id = otherMap.get("fxpf").toString(); | |
87 | - pingfen = FunvCommonUtil.getBaseicConfigByid(id, basicConfigService); | |
85 | + // String id = otherMap.get("fxpf").toString(); | |
86 | + // pingfen = FunvCommonUtil.getBaseicConfigByid(id, basicConfigService); | |
87 | + pingfen = otherMap.get("fxpf").toString(); | |
88 | 88 | } else { |
89 | 89 | continue; |
90 | 90 | } |