From ef6d83015d60d300158e6ce6d37d6bb8c67d8ed6 Mon Sep 17 00:00:00 2001
From: xiaogang <905166056@qq.com>
Date: 星期二, 29 十二月 2020 17:55:29 +0800
Subject: [PATCH] 1.费用明细报表选择收费项下拉框去除系统默认收费项。 2.缴费明细报表新增大计和小计统计;新增查询所有费用应收、实收总金额SQL语句。 3.缴费清单报表分页显示行数和列数修改 4.缴费明细表时间修改,可以查询某天的缴费明细

---
 service-report/src/main/java/com/java110/report/bmo/reportFeeMonthStatistics/impl/GetReportFeeMonthStatisticsBMOImpl.java |   37 ++++++++++++++++++++++++++++++++++---
 1 files changed, 34 insertions(+), 3 deletions(-)

diff --git a/service-report/src/main/java/com/java110/report/bmo/reportFeeMonthStatistics/impl/GetReportFeeMonthStatisticsBMOImpl.java b/service-report/src/main/java/com/java110/report/bmo/reportFeeMonthStatistics/impl/GetReportFeeMonthStatisticsBMOImpl.java
index bd79c11..d5b320d 100644
--- a/service-report/src/main/java/com/java110/report/bmo/reportFeeMonthStatistics/impl/GetReportFeeMonthStatisticsBMOImpl.java
+++ b/service-report/src/main/java/com/java110/report/bmo/reportFeeMonthStatistics/impl/GetReportFeeMonthStatisticsBMOImpl.java
@@ -187,9 +187,28 @@
         int count = Integer.parseInt(countInfo.get("count").toString());
 
         List<ReportFeeMonthStatisticsDto> reportFeeMonthStatisticsDtos = null;
+        List<ReportFeeMonthStatisticsDto> reportList = new ArrayList<>();
+        //搴旀敹鎬婚噾棰�(澶ц)
+        Double allReceivableAmount = 0.0;
+        //瀹炴敹閲戦(澶ц)
+        Double allReceivedAmount = 0.0;
         if (count > 0) {
             reportFeeMonthStatisticsDtos = reportFeeMonthStatisticsInnerServiceSMOImpl.queryPayFeeDetail(reportFeeMonthStatisticsDto);
-
+            List<ReportFeeMonthStatisticsDto> reportFeeMonthStatisticsList = reportFeeMonthStatisticsInnerServiceSMOImpl.queryAllPayFeeDetail(reportFeeMonthStatisticsDto);
+            allReceivableAmount = Double.valueOf(reportFeeMonthStatisticsList.get(0).getAllReceivableAmount());
+            allReceivedAmount = Double.valueOf(reportFeeMonthStatisticsList.get(0).getAllReceivedAmount());
+            //搴旀敹鎬婚噾棰�(灏忚)
+            Double totalReceivableAmount = 0.0;
+            //瀹炴敹鎬婚噾棰�(灏忚)
+            Double totalReceivedAmount = 0.0;
+            for (ReportFeeMonthStatisticsDto reportFeeMonthStatistics : reportFeeMonthStatisticsDtos) {
+                //搴旀敹閲戦
+                Double receivableAmount = Double.valueOf(reportFeeMonthStatistics.getReceivableAmount());
+                //瀹炴敹閲戦
+                Double receivedAmount = Double.valueOf(reportFeeMonthStatistics.getReceivedAmount());
+                totalReceivableAmount = totalReceivableAmount + receivableAmount;
+                totalReceivedAmount = totalReceivedAmount + receivedAmount;
+            }
             for (ReportFeeMonthStatisticsDto tmpReportFeeMonthStatisticsDto : reportFeeMonthStatisticsDtos) {
                 if (FeeDto.PAYER_OBJ_TYPE_ROOM.equals(tmpReportFeeMonthStatisticsDto.getPayerObjType())) {
                     tmpReportFeeMonthStatisticsDto.setObjName(tmpReportFeeMonthStatisticsDto.getFloorNum()
@@ -202,13 +221,25 @@
                 if (!StringUtil.isEmpty(tmpReportFeeMonthStatisticsDto.getImportFeeName())) {
                     tmpReportFeeMonthStatisticsDto.setFeeName(tmpReportFeeMonthStatisticsDto.getImportFeeName());
                 }
+                //搴旀敹閲戦(灏忚)
+                tmpReportFeeMonthStatisticsDto.setTotalReceivableAmount(String.format("%.2f", totalReceivableAmount));
+                //瀹炴敹閲戦(灏忚)
+                tmpReportFeeMonthStatisticsDto.setTotalReceivedAmount(String.format("%.2f", totalReceivedAmount));
+                //搴旀敹閲戦(澶ц)
+                tmpReportFeeMonthStatisticsDto.setAllReceivableAmount(String.format("%.2f", allReceivableAmount));
+                //瀹炴敹閲戦(澶ц)
+                tmpReportFeeMonthStatisticsDto.setAllReceivedAmount(String.format("%.2f", allReceivedAmount));
+                reportList.add(tmpReportFeeMonthStatisticsDto);
             }
         } else {
             reportFeeMonthStatisticsDtos = new ArrayList<>();
+            reportList.addAll(reportFeeMonthStatisticsDtos);
         }
 
-        FeeDetailResultVo resultVo = new FeeDetailResultVo(countInfo.getDouble("totalReceivableAmount"), countInfo.getDouble("totalReceivedAmount"),
-                (int) Math.ceil((double) count / (double) reportFeeMonthStatisticsDto.getRow()), count, reportFeeMonthStatisticsDtos);
+        /*FeeDetailResultVo resultVo = new FeeDetailResultVo(countInfo.getDouble("totalReceivableAmount"), countInfo.getDouble("totalReceivedAmount"),
+                (int) Math.ceil((double) count / (double) reportFeeMonthStatisticsDto.getRow()), count, reportList);*/
+
+        ResultVo resultVo = new ResultVo((int) Math.ceil((double) count / (double) reportFeeMonthStatisticsDto.getRow()), count, reportList);
 
         ResponseEntity<String> responseEntity = new ResponseEntity<String>(resultVo.toString(), HttpStatus.OK);
 

--
Gitblit v1.8.0