解决时段水位报错

master
wany 2024-10-30 10:26:23 +08:00
parent 20372c8fed
commit 4c09e9770b
1 changed files with 3 additions and 1 deletions

View File

@ -192,7 +192,9 @@ public class StatisticsService {
count++;
}
}
vo.setRzAvg(rzD.divide(new BigDecimal(count), 2, RoundingMode.HALF_UP));
if(count > 0){
vo.setRzAvg(rzD.divide(new BigDecimal(count), 2, RoundingMode.HALF_UP));
}
}
}