diff --git a/src/main/java/com/biutag/supervision/controller/datav/DataVAuditController.java b/src/main/java/com/biutag/supervision/controller/datav/DataVAuditController.java index c54f406..cea9eab 100644 --- a/src/main/java/com/biutag/supervision/controller/datav/DataVAuditController.java +++ b/src/main/java/com/biutag/supervision/controller/datav/DataVAuditController.java @@ -30,6 +30,7 @@ import org.springframework.format.annotation.DateTimeFormat; import org.springframework.web.bind.annotation.*; import java.math.BigDecimal; +import java.math.RoundingMode; import java.util.Date; import java.util.List; import java.util.Map; @@ -77,8 +78,8 @@ public class DataVAuditController { projectLambdaQueryWrapper.eq(ReportProject::getNode, ReportProjectNodeEnum.END); projectLambdaQueryWrapper.eq(ReportProject::getDeleteFlag, DeleteStatusEnum.NO.getCode()); List reportProjects = reportProjectMapper.selectList(projectLambdaQueryWrapper); - BigDecimal totalReportMoney = reportProjects.stream().map(ReportProject::getReportMoney).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add); - BigDecimal totalArchivingReduceMoney = reportProjects.stream().map(ReportProject::getArchivingReduceMoney).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add); + BigDecimal totalReportMoney = reportProjects.stream().map(ReportProject::getReportMoney).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add).divide(new BigDecimal("10000"), 2, RoundingMode.HALF_UP); ; + BigDecimal totalArchivingReduceMoney = reportProjects.stream().map(ReportProject::getArchivingReduceMoney).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add).divide(new BigDecimal("10000"), 2, RoundingMode.HALF_UP); AuditOverview overview = new AuditOverview(); overview.setNegativeNumber(negatives.size()); overview.setAccountableNumber(accountableNumber);