Commit 6198abfd69de804c543e715ecc966a8fdfbb115f
1 parent
ec4f17ebcd
Exists in
master
and in
1 other branch
修改高分评分默认为String
Showing 2 changed files with 7 additions and 6 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/PredictedStatisticsFacade.java
View file @
6198abf
| ... | ... | @@ -7,7 +7,6 @@ |
| 7 | 7 | import com.lyms.platform.common.enums.YnEnums; |
| 8 | 8 | import com.lyms.platform.common.utils.BeanUtils; |
| 9 | 9 | import com.lyms.platform.common.utils.DateUtil; |
| 10 | -import com.lyms.platform.common.utils.StringUtils; | |
| 11 | 10 | import com.lyms.platform.operate.web.request.PredictedStatisticsRequest; |
| 12 | 11 | import com.lyms.platform.operate.web.request.PredictedStatisticsSumRequest; |
| 13 | 12 | import com.lyms.platform.operate.web.result.PredictedStatisticsQueryModel; |
| ... | ... | @@ -21,6 +20,7 @@ |
| 21 | 20 | import net.sf.json.JSONArray; |
| 22 | 21 | import org.springframework.beans.factory.annotation.Autowired; |
| 23 | 22 | import org.springframework.stereotype.Component; |
| 23 | +import org.springframework.util.StringUtils; | |
| 24 | 24 | |
| 25 | 25 | import java.text.SimpleDateFormat; |
| 26 | 26 | import java.util.ArrayList; |
| ... | ... | @@ -94,6 +94,7 @@ |
| 94 | 94 | predictedStatisticsQueryModel.setRiskFactor(getRiskFactor(patients.getRiskFactorId())); |
| 95 | 95 | predictedStatisticsQueryModel.setLastCheckEmployee(getLastCheckEmployee(patients.getLastCheckEmployeeId())); |
| 96 | 96 | predictedStatisticsQueryModel.setGestationalWeeks(getGestationalWeeks(patients.getLastMenses(), patients.getType(), patients.getDueStatus())); |
| 97 | + predictedStatisticsQueryModel.setRiskScore(StringUtils.isEmpty(patients.getRiskScore()) ? null : patients.getRiskScore().toString()); | |
| 97 | 98 | predictedStatisticsQueryModelList.add(predictedStatisticsQueryModel); |
| 98 | 99 | } |
| 99 | 100 | } |
| 100 | 101 | |
| ... | ... | @@ -151,9 +152,9 @@ |
| 151 | 152 | |
| 152 | 153 | private static String getGestationalWeeks(Date date, int type, Integer dueStatus) { |
| 153 | 154 | if (type == 3) { |
| 154 | - if (dueStatus!=null&&dueStatus == 0 ) { | |
| 155 | + if (dueStatus != null && dueStatus == 0) { | |
| 155 | 156 | return "已分娩"; |
| 156 | - } else if (dueStatus!=null&&dueStatus == 1) { | |
| 157 | + } else if (dueStatus != null && dueStatus == 1) { | |
| 157 | 158 | return "终止妊娠"; |
| 158 | 159 | } else { |
| 159 | 160 | return "已分娩"; |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/result/PredictedStatisticsQueryModel.java
View file @
6198abf
| ... | ... | @@ -33,7 +33,7 @@ |
| 33 | 33 | * @createTime 2016年11月29日 17时05分 |
| 34 | 34 | * @discription 高危评分 |
| 35 | 35 | */ |
| 36 | - private Integer riskScore; | |
| 36 | + private String riskScore; | |
| 37 | 37 | /** |
| 38 | 38 | * @auther HuJiaqi |
| 39 | 39 | * @createTime 2016年11月29日 17时06分 |
| 40 | 40 | |
| ... | ... | @@ -106,11 +106,11 @@ |
| 106 | 106 | this.dueDate = dueDate; |
| 107 | 107 | } |
| 108 | 108 | |
| 109 | - public Integer getRiskScore() { | |
| 109 | + public String getRiskScore() { | |
| 110 | 110 | return riskScore; |
| 111 | 111 | } |
| 112 | 112 | |
| 113 | - public void setRiskScore(Integer riskScore) { | |
| 113 | + public void setRiskScore(String riskScore) { | |
| 114 | 114 | this.riskScore = riskScore; |
| 115 | 115 | } |
| 116 | 116 |