Преглед на файлове

任务管理:水量同步水量保留两位小数点

zhoujiangyuan преди 4 години
родител
ревизия
e672607f4b
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      smart-city-platform/src/main/java/com/bz/smart_city/service/impl/pay/AmountSynServiceImpl.java

+ 1 - 1
smart-city-platform/src/main/java/com/bz/smart_city/service/impl/pay/AmountSynServiceImpl.java

@@ -199,7 +199,7 @@ public class AmountSynServiceImpl implements AmountSynService,InitializingBean {
                                                 Duration duration1 = Duration.between(previousTime,replaceTime);
                                                 Duration duration2 = Duration.between(replaceTime,currTime);
                                                 if(duration1.toMillis() > 0  && duration2.toMinutes() > 0){
-                                                    BigDecimal replaceEndData = new BigDecimal(replaceMeterCountDto.getReplaceMeterDtoList().get(i).getOldEnd()).setScale(0,BigDecimal.ROUND_DOWN);//换表中的旧表止度
+                                                    BigDecimal replaceEndData = new BigDecimal(replaceMeterCountDto.getReplaceMeterDtoList().get(i).getOldEnd()).setScale(2,BigDecimal.ROUND_DOWN);//换表中的旧表止度
                                                     BigDecimal replaceData = BigDecimal.ZERO;
                                                     if(oldReplaceMeterDto == null)
                                                         replaceData = tempReading;