add 折线图列表增加总计
This commit is contained in:
@@ -68,6 +68,18 @@ public class IndexService {
|
|||||||
allProjectStatisticsSearch.setPaymentYear(year);
|
allProjectStatisticsSearch.setPaymentYear(year);
|
||||||
List<AllProjectStatistics> list = payWorkingGroupService.queryListAllProjectMoney(allProjectStatisticsSearch, null);
|
List<AllProjectStatistics> list = payWorkingGroupService.queryListAllProjectMoney(allProjectStatisticsSearch, null);
|
||||||
List<LineChartListVO> lineChartListVOList = convertLineChartListVO(list);
|
List<LineChartListVO> lineChartListVOList = convertLineChartListVO(list);
|
||||||
|
//总数
|
||||||
|
LineChartListVO lineChartListVO = new LineChartListVO();
|
||||||
|
BigDecimal reduce = lineChartListVOList.stream().map(i -> new BigDecimal(i.getAllMoney())).reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||||
|
lineChartListVO.setAllMoney(reduce.toString());
|
||||||
|
BigDecimal reduce1 = lineChartListVOList.stream().map(i -> new BigDecimal(i.getConfirmAmount())).reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||||
|
lineChartListVO.setConfirmAmount(reduce1.toString());
|
||||||
|
BigDecimal reduce2 = lineChartListVOList.stream().map(i -> new BigDecimal(i.getBillMoney())).reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||||
|
lineChartListVO.setBillMoney(reduce2.toString());
|
||||||
|
BigDecimal reduce3 = lineChartListVOList.stream().map(i -> new BigDecimal(i.getComeAllMoney())).reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||||
|
lineChartListVO.setComeAllMoney(reduce3.toString());
|
||||||
|
lineChartListVO.setPaymentDate("总数");
|
||||||
|
lineChartListVOList.add(lineChartListVO);
|
||||||
return lineChartListVOList;
|
return lineChartListVOList;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user