|
@@ -780,7 +780,7 @@ public class ProduceReportServiceImpl extends BaseServiceImpl<ProduceReportMappe
|
|
|
yearReport.setDate(date);
|
|
|
yearReport.setYear(date.getYear());
|
|
|
yearReport = super.getModelListByModel(yearReport).get(0);
|
|
|
- yearReport.setValue(new BigDecimal(yearVO.getTotalValue()).setScale(2).toString());
|
|
|
+ yearReport.setValue(new BigDecimal(yearVO.getTotalValue()).setScale(2, RoundingMode.HALF_UP).toString());
|
|
|
yearReport.setUpdateTime(LocalDateTime.now());
|
|
|
yearReport.setUpdateUserId(SecurityUtils.getUserInfo().getUserId());
|
|
|
mapper.updateByPrimaryKey(yearReport);
|
|
@@ -797,7 +797,7 @@ public class ProduceReportServiceImpl extends BaseServiceImpl<ProduceReportMappe
|
|
|
monthReport.setYear(date.getYear());
|
|
|
monthReport.setMonth(date.getMonthValue());
|
|
|
monthReport = super.getModelListByModel(monthReport).get(0);
|
|
|
- monthReport.setValue(new BigDecimal(monthVO.getTotalValue()).setScale(2).toString());
|
|
|
+ monthReport.setValue(new BigDecimal(monthVO.getTotalValue()).setScale(2, RoundingMode.HALF_UP).toString());
|
|
|
monthReport.setUpdateTime(LocalDateTime.now());
|
|
|
monthReport.setUpdateUserId(SecurityUtils.getUserInfo().getUserId());
|
|
|
mapper.updateByPrimaryKey(monthReport);
|