Commit 91d446820eadc61bb9537deedb4e7ba223d8a3c7
1 parent
b38398ffed
Exists in
master
and in
1 other branch
1
Showing 2 changed files with 21 additions and 13 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/TestController.java
View file @
91d4468
| ... | ... | @@ -15,6 +15,7 @@ |
| 15 | 15 | import com.lyms.platform.common.utils.JsonUtil; |
| 16 | 16 | import com.lyms.platform.operate.web.facade.AntenatalExaminationFacade; |
| 17 | 17 | import com.lyms.platform.operate.web.facade.BabyCheckFacade; |
| 18 | +import com.lyms.platform.operate.web.facade.HosptialHighRiskFacade; | |
| 18 | 19 | import com.lyms.platform.operate.web.facade.SieveFacade; |
| 19 | 20 | import com.lyms.platform.operate.web.result.HighScoreResult; |
| 20 | 21 | import com.lyms.platform.operate.web.service.IBloodPressureService; |
| ... | ... | @@ -1614,15 +1615,7 @@ |
| 1614 | 1615 | if (applyOrderService.queryCount(applyOrderQuery) > 0) { |
| 1615 | 1616 | ReferralApplyOrderModel referralApplyOrderModel = new ReferralApplyOrderModel(); |
| 1616 | 1617 | referralApplyOrderModel.setrRisk(Arrays.asList(commonService.resloveFactor(loa.getRiskFactorId()).split(","))); |
| 1617 | - List lsit = new ArrayList(); | |
| 1618 | - List<Map> list = commonService.findRiskLevel(loa.getRiskLevelId()); | |
| 1619 | - for (Map<String, String> map : list) { | |
| 1620 | - String name = map.get("name"); | |
| 1621 | - if (!lsit.contains(name)) { | |
| 1622 | - lsit.add(name); | |
| 1623 | - } | |
| 1624 | - } | |
| 1625 | - referralApplyOrderModel.setrLevel(lsit); | |
| 1618 | + referralApplyOrderModel.setrLevel(StringUtils.isNotEmpty(loa.getRiskLevelId())&&!"[]".equals(loa.getRiskLevelId())?JsonUtil.jkstr2Obj(loa.getRiskLevelId(), List.class):Collections.emptyList()); | |
| 1626 | 1619 | applyOrderService.updateByParentId(applyOrderQuery, referralApplyOrderModel); |
| 1627 | 1620 | } |
| 1628 | 1621 | } |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/ApplyOrderFacade.java
View file @
91d4468
| ... | ... | @@ -7,9 +7,7 @@ |
| 7 | 7 | import com.lyms.platform.common.result.BaseListResponse; |
| 8 | 8 | import com.lyms.platform.common.result.BaseObjectResponse; |
| 9 | 9 | import com.lyms.platform.common.result.BaseResponse; |
| 10 | -import com.lyms.platform.common.utils.DateUtil; | |
| 11 | -import com.lyms.platform.common.utils.ExcelUtil; | |
| 12 | -import com.lyms.platform.common.utils.SystemConfig; | |
| 10 | +import com.lyms.platform.common.utils.*; | |
| 13 | 11 | import com.lyms.platform.operate.web.request.ApplyOrderQueryRequest; |
| 14 | 12 | import com.lyms.platform.operate.web.request.BabyApplyOrderQueryRequest; |
| 15 | 13 | import com.lyms.platform.operate.web.request.ReferralApplyOrderAddRequest; |
| ... | ... | @@ -818,7 +816,7 @@ |
| 818 | 816 | applyOrderResult.setScore(orderModel.getScore()); |
| 819 | 817 | |
| 820 | 818 | |
| 821 | - List rLevel = new ArrayList(); | |
| 819 | + /* | |
| 822 | 820 | if (CollectionUtils.isNotEmpty(orderModel.getrLevel())) { |
| 823 | 821 | for (String str : orderModel.getrLevel()) { |
| 824 | 822 | Map map1 = new HashMap(); |
| ... | ... | @@ -830,6 +828,23 @@ |
| 830 | 828 | map1.put("color", "risk_" + RiskDefaultTypeEnum.getColor(str)); |
| 831 | 829 | rLevel.add(map1); |
| 832 | 830 | } |
| 831 | + }*/ | |
| 832 | + List rLevel = new ArrayList(); | |
| 833 | + if (CollectionUtils.isNotEmpty(orderModel.getrLevel())) { | |
| 834 | + try { | |
| 835 | + List<String> list = orderModel.getrLevel(); | |
| 836 | + for (String str : list) { | |
| 837 | + BasicConfig basicConfig = basicConfigService.getOneBasicConfigById(str); | |
| 838 | + if (null != basicConfig) { | |
| 839 | + Map map = new HashMap(); | |
| 840 | + basicConfig.replenRisk(map); | |
| 841 | + rLevel.add(map); | |
| 842 | + } | |
| 843 | + } | |
| 844 | + } catch (Exception e) { | |
| 845 | + ExceptionUtils.catchException(e, "patients.getRiskLevelId error."); | |
| 846 | + } | |
| 847 | + applyOrderResult.setrLevel(HighScoreResult.filter(rLevel)); | |
| 833 | 848 | } |
| 834 | 849 | applyOrderResult.setrLevel(rLevel); |
| 835 | 850 | Patients patients = patientsService.findOnePatientById(orderModel.getParentId()); |