Commit 6c9f47d1eb0dfefc970805e33f79e813f1956bad
1 parent
793e72bbd4
Exists in
master
and in
6 other branches
2
Showing 1 changed file with 9 additions and 7 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/ViewFacade.java
View file @
6c9f47d
... | ... | @@ -451,10 +451,11 @@ |
451 | 451 | } |
452 | 452 | } |
453 | 453 | heartRate += placenta.get("heartRate") == null ? "" : placenta.get("heartRate"); |
454 | + if(StringUtils.isNotEmpty(heartRate)) { | |
455 | + Integer a = (int) Double.parseDouble(heartRate); | |
456 | + heartRate = String.valueOf(a); | |
457 | + } | |
454 | 458 | |
455 | - Integer a = (int)Double.parseDouble(heartRate); | |
456 | - heartRate = String.valueOf(a); | |
457 | - | |
458 | 459 | fetalPresentation += placenta.get("fetalPresentation") == null ? "" : placenta.get("fetalPresentation"); |
459 | 460 | join = placenta.get("join"); |
460 | 461 | } |
... | ... | @@ -831,10 +832,11 @@ |
831 | 832 | fetalPresentation += placenta.getFetalPresentation() == null ? "" : placenta.getFetalPresentation(); |
832 | 833 | //胎心率 |
833 | 834 | heartRate += placenta.getHeartRate() == null ? "" : placenta.getHeartRate().toString(); |
834 | - //转换为整数 | |
835 | - Integer a = (int)Double.parseDouble(heartRate); | |
836 | - heartRate = String.valueOf(a); | |
837 | - | |
835 | + if(StringUtils.isNotEmpty(heartRate)){ | |
836 | + //转换为整数 | |
837 | + Integer a = (int)Double.parseDouble(heartRate); | |
838 | + heartRate = String.valueOf(a); | |
839 | + } | |
838 | 840 | } |
839 | 841 | |
840 | 842 | if ("java.util.LinkedHashMap".equals(obj.getClass().getName())) { |