diff --git a/src/main/java/com/interplug/qcast/biz/estimate/EstimateService.java b/src/main/java/com/interplug/qcast/biz/estimate/EstimateService.java index 01e65cba..61df3e23 100644 --- a/src/main/java/com/interplug/qcast/biz/estimate/EstimateService.java +++ b/src/main/java/com/interplug/qcast/biz/estimate/EstimateService.java @@ -1412,9 +1412,9 @@ public class EstimateService { String classTypeName = ""; if ("0".equals(roofVol.getClassType())) { - classTypeName = roofVol.getSlope() + "寸"; + classTypeName = String.format("%.2f", Double.parseDouble(StringUtils.defaultString(roofVol.getSlope(), "0"))) + "寸"; } else { - classTypeName = roofVol.getAngle() + "º"; + classTypeName = String.format("%.2f", Double.parseDouble(StringUtils.defaultString(roofVol.getAngle(), "0"))) + "º"; } roofVol.setClassTypeName(classTypeName); @@ -1427,9 +1427,9 @@ public class EstimateService { for (RoofResponse roof : roofList) { String roofClassTypeName = ""; if ("0".equals(roof.getClassType())) { - roofClassTypeName = roof.getSlope() + "寸"; + roofClassTypeName = String.format("%.2f", Double.parseDouble(StringUtils.defaultString(roof.getSlope(), "0"))) + "寸"; } else { - roofClassTypeName = roof.getAngle() + "º"; + roofClassTypeName = String.format("%.2f", Double.parseDouble(StringUtils.defaultString(roof.getAngle(), "0"))) + "º"; } roof.setClassTypeName(roofClassTypeName); }