Просмотр исходного кода

1.新增查询优惠、减免、滞纳金、空置房打折、空置房减免总金额sql语句2、新添加优惠、减免、滞纳金、空置房打折、空置房减免金额以及对应的大计、小计

xiaogang лет назад: 5
Родитель
Сommit
086af9a242

+ 77 - 1
java110-bean/src/main/java/com/java110/dto/reportFeeMonthStatistics/ReportFeeMonthStatisticsDto.java

@@ -77,6 +77,27 @@ public class ReportFeeMonthStatisticsDto extends PageDto implements Serializable
     //费用类型
     private String feeTypeCd;
 
+    //打折金额(包括打折、减免、滞纳金、空置房打折、空置房减免金额等)
+    private String discountPrice;
+
+    //1:打折 2:减免 3:滞纳金 4:空置房打折 5:空置房减免
+    private String discountSmallType;
+
+    //优惠金额
+    private String preferentialAmount;
+
+    //减免金额
+    private String deductionAmount;
+
+    //滞纳金
+    private String lateFee;
+
+    //空置房打折金额
+    private String vacantHousingDiscount;
+
+    //空置房减免金额
+    private String vacantHousingReduction;
+
     public String getReceivableAmount() {
         return receivableAmount;
     }
@@ -205,7 +226,6 @@ public class ReportFeeMonthStatisticsDto extends PageDto implements Serializable
         this.objType = objType;
     }
 
-
     public Date getCreateTime() {
         return createTime;
     }
@@ -397,4 +417,60 @@ public class ReportFeeMonthStatisticsDto extends PageDto implements Serializable
     public void setFeeTypeCd(String feeTypeCd) {
         this.feeTypeCd = feeTypeCd;
     }
+
+    public String getPreferentialAmount() {
+        return preferentialAmount;
+    }
+
+    public void setPreferentialAmount(String preferentialAmount) {
+        this.preferentialAmount = preferentialAmount;
+    }
+
+    public String getDeductionAmount() {
+        return deductionAmount;
+    }
+
+    public void setDeductionAmount(String deductionAmount) {
+        this.deductionAmount = deductionAmount;
+    }
+
+    public String getLateFee() {
+        return lateFee;
+    }
+
+    public void setLateFee(String lateFee) {
+        this.lateFee = lateFee;
+    }
+
+    public String getDiscountSmallType() {
+        return discountSmallType;
+    }
+
+    public void setDiscountSmallType(String discountSmallType) {
+        this.discountSmallType = discountSmallType;
+    }
+
+    public String getDiscountPrice() {
+        return discountPrice;
+    }
+
+    public void setDiscountPrice(String discountPrice) {
+        this.discountPrice = discountPrice;
+    }
+
+    public String getVacantHousingDiscount() {
+        return vacantHousingDiscount;
+    }
+
+    public void setVacantHousingDiscount(String vacantHousingDiscount) {
+        this.vacantHousingDiscount = vacantHousingDiscount;
+    }
+
+    public String getVacantHousingReduction() {
+        return vacantHousingReduction;
+    }
+
+    public void setVacantHousingReduction(String vacantHousingReduction) {
+        this.vacantHousingReduction = vacantHousingReduction;
+    }
 }

+ 171 - 0
java110-bean/src/main/java/com/java110/dto/reportFeeMonthStatistics/ReportFeeMonthStatisticsTotalDto.java

@@ -0,0 +1,171 @@
+package com.java110.dto.reportFeeMonthStatistics;
+
+import com.java110.dto.PageDto;
+import com.java110.dto.fee.FeeConfigDto;
+
+import java.io.Serializable;
+import java.util.List;
+
+/**
+ * @ClassName ReportFeeMonthStatisticsTotalDto
+ * @Description 缴费明细报表大计、小计金额数据层封装
+ * @Author fqz
+ * @Date 2021/1/4 11:14
+ * @Version 1.0
+ * add by fqz 2021/1/4
+ **/
+public class ReportFeeMonthStatisticsTotalDto extends PageDto implements Serializable {
+    //应收总金额(小计)
+    private String totalReceivableAmount;
+
+    //实收总金额(小计)
+    private String totalReceivedAmount;
+
+    //应收总金额(大计)
+    private String allReceivableAmount;
+
+    //实收总金额(大计)
+    private String allReceivedAmount;
+
+    //优惠金额(小计)
+    private String totalPreferentialAmount;
+
+    //减免金额(小计)
+    private String totalDeductionAmount;
+
+    //滞纳金(小计)
+    private String totalLateFee;
+
+    //空置房打折金额(小计)
+    private String totalVacantHousingDiscount;
+
+    //空置房减免金额(小计)
+    private String totalVacantHousingReduction;
+
+    //优惠金额(大计)
+    private String allPreferentialAmount;
+
+    //减免金额(大计)
+    private String allDeductionAmount;
+
+    //滞纳金(大计)
+    private String allLateFee;
+
+    //空置房打折金额(大计)
+    private String allVacantHousingDiscount;
+
+    //空置房减免金额(大计)
+    private String allVacantHousingReduction;
+
+    public String getTotalReceivableAmount() {
+        return totalReceivableAmount;
+    }
+
+    public void setTotalReceivableAmount(String totalReceivableAmount) {
+        this.totalReceivableAmount = totalReceivableAmount;
+    }
+
+    public String getTotalReceivedAmount() {
+        return totalReceivedAmount;
+    }
+
+    public void setTotalReceivedAmount(String totalReceivedAmount) {
+        this.totalReceivedAmount = totalReceivedAmount;
+    }
+
+    public String getAllReceivableAmount() {
+        return allReceivableAmount;
+    }
+
+    public void setAllReceivableAmount(String allReceivableAmount) {
+        this.allReceivableAmount = allReceivableAmount;
+    }
+
+    public String getAllReceivedAmount() {
+        return allReceivedAmount;
+    }
+
+    public void setAllReceivedAmount(String allReceivedAmount) {
+        this.allReceivedAmount = allReceivedAmount;
+    }
+
+    public String getTotalPreferentialAmount() {
+        return totalPreferentialAmount;
+    }
+
+    public void setTotalPreferentialAmount(String totalPreferentialAmount) {
+        this.totalPreferentialAmount = totalPreferentialAmount;
+    }
+
+    public String getTotalDeductionAmount() {
+        return totalDeductionAmount;
+    }
+
+    public void setTotalDeductionAmount(String totalDeductionAmount) {
+        this.totalDeductionAmount = totalDeductionAmount;
+    }
+
+    public String getTotalLateFee() {
+        return totalLateFee;
+    }
+
+    public void setTotalLateFee(String totalLateFee) {
+        this.totalLateFee = totalLateFee;
+    }
+
+    public String getTotalVacantHousingDiscount() {
+        return totalVacantHousingDiscount;
+    }
+
+    public void setTotalVacantHousingDiscount(String totalVacantHousingDiscount) {
+        this.totalVacantHousingDiscount = totalVacantHousingDiscount;
+    }
+
+    public String getTotalVacantHousingReduction() {
+        return totalVacantHousingReduction;
+    }
+
+    public void setTotalVacantHousingReduction(String totalVacantHousingReduction) {
+        this.totalVacantHousingReduction = totalVacantHousingReduction;
+    }
+
+    public String getAllPreferentialAmount() {
+        return allPreferentialAmount;
+    }
+
+    public void setAllPreferentialAmount(String allPreferentialAmount) {
+        this.allPreferentialAmount = allPreferentialAmount;
+    }
+
+    public String getAllDeductionAmount() {
+        return allDeductionAmount;
+    }
+
+    public void setAllDeductionAmount(String allDeductionAmount) {
+        this.allDeductionAmount = allDeductionAmount;
+    }
+
+    public String getAllLateFee() {
+        return allLateFee;
+    }
+
+    public void setAllLateFee(String allLateFee) {
+        this.allLateFee = allLateFee;
+    }
+
+    public String getAllVacantHousingDiscount() {
+        return allVacantHousingDiscount;
+    }
+
+    public void setAllVacantHousingDiscount(String allVacantHousingDiscount) {
+        this.allVacantHousingDiscount = allVacantHousingDiscount;
+    }
+
+    public String getAllVacantHousingReduction() {
+        return allVacantHousingReduction;
+    }
+
+    public void setAllVacantHousingReduction(String allVacantHousingReduction) {
+        this.allVacantHousingReduction = allVacantHousingReduction;
+    }
+}

+ 38 - 1
java110-bean/src/main/java/com/java110/vo/ResultVo.java

@@ -52,7 +52,7 @@ public class ResultVo implements Serializable {
     // 总记录数
     private int total;
 
-    //状态
+    //状态
     private int code;
 
     //错误提示
@@ -61,6 +61,9 @@ public class ResultVo implements Serializable {
     //数据对象
     private Object data;
 
+    //用来存放大计、小计金额
+    private Object sumTotal;
+
     public ResultVo() {
     }
 
@@ -83,6 +86,15 @@ public class ResultVo implements Serializable {
         this.data = data;
     }
 
+    public ResultVo(int records, int total, Object data, Object sumTotal) {
+        this.code = CODE_OK;
+        this.msg = MSG_OK;
+        this.records = records;
+        this.total = total;
+        this.data = data;
+        this.sumTotal = sumTotal;
+    }
+
     public ResultVo(int code, String msg, Object data) {
         this.code = code;
         this.msg = msg;
@@ -153,6 +165,14 @@ public class ResultVo implements Serializable {
         this.data = data;
     }
 
+    public Object getSumTotal() {
+        return sumTotal;
+    }
+
+    public void setSumTotal(Object sumTotal) {
+        this.sumTotal = sumTotal;
+    }
+
     @Override
     public String toString() {
         return JSONObject.toJSONString(this, SerializerFeature.DisableCircularReferenceDetect, SerializerFeature.WriteDateUseDateFormat);
@@ -184,6 +204,7 @@ public class ResultVo implements Serializable {
 
     /**
      * 成功通用回复
+     *
      * @return
      */
     public static ResponseEntity<String> success() {
@@ -194,6 +215,7 @@ public class ResultVo implements Serializable {
 
     /**
      * 成功通用回复
+     *
      * @return
      */
     public static ResponseEntity<String> error(String msg) {
@@ -216,6 +238,21 @@ public class ResultVo implements Serializable {
         return responseEntity;
     }
 
+    /**
+     * 创建ResponseEntity对象
+     *
+     * @param records
+     * @param total
+     * @param data
+     * @param sumTotal
+     * @return
+     */
+    public static ResponseEntity<String> createResponseEntity(int records, int total, Object data, Object sumTotal) {
+        ResultVo resultVo = new ResultVo(records, total, data, sumTotal);
+        ResponseEntity<String> responseEntity = new ResponseEntity<String>(resultVo.toString(), HttpStatus.OK);
+        return responseEntity;
+    }
+
     /**
      * 页面跳转
      *

+ 83 - 5
java110-db/src/main/resources/mapper/report/ReportFeeMonthStatisticsServiceDaoImplMapper.xml

@@ -438,14 +438,16 @@
     <select id="queryFeeBreakdownCount" parameterType="Map" resultType="Map">
         select count(1) count
         from (
-        select t.fee_name feeName,td.name feeTypeCd,pfc.fee_type_cd,pfc.start_time feeCreateTime,t.create_time createTime,SUM(t.receivable_amount)
+        select t.fee_name feeName,td.name feeTypeCd,pfc.fee_type_cd,pfc.start_time feeCreateTime,t.create_time
+        createTime,SUM(t.receivable_amount)
         receivableAmount,SUM(t.received_amount) receivedAmount,SUM(t.owe_amount) oweAmount
         from report_fee_month_statistics t
         inner join pay_fee_config pfc on t.config_id = pfc.config_id and pfc.status_cd = '0'
         left join building_room br on t.obj_id = br.room_id and t.obj_type = '3333' and br.status_cd = '0'
         left join building_unit bu on br.unit_id = bu.unit_id and bu.status_cd = '0'
         left join f_floor f on bu.floor_id = f.floor_id and f.status_cd = '0'
-        left join t_dict td on pfc.fee_type_cd = td.status_cd and td.table_name="pay_fee_config" and td.table_columns="fee_type_cd"
+        left join t_dict td on pfc.fee_type_cd = td.status_cd and td.table_name="pay_fee_config" and
+        td.table_columns="fee_type_cd"
         where t.status_cd = '0'
         <if test="roomNum !=null and roomNum != ''">
             and br.room_num= #{roomNum}
@@ -495,14 +497,16 @@
 
     <!-- 查询费用月统计信息 add by wuxw 2018-07-03 -->
     <select id="queryFeeBreakdown" parameterType="Map" resultType="Map">
-        select t.fee_name feeName,td.name feeTypeCd,pfc.fee_type_cd,pfc.start_time feeCreateTime,t.create_time createTime,SUM(t.receivable_amount)
+        select t.fee_name feeName,td.name feeTypeCd,pfc.fee_type_cd,pfc.start_time feeCreateTime,t.create_time
+        createTime,SUM(t.receivable_amount)
         receivableAmount,SUM(t.received_amount) receivedAmount,SUM(t.owe_amount) oweAmount
         from report_fee_month_statistics t
         inner join pay_fee_config pfc on t.config_id = pfc.config_id and pfc.status_cd = '0'
         left join building_room br on t.obj_id = br.room_id and t.obj_type = '3333' and br.status_cd = '0'
         left join building_unit bu on br.unit_id = bu.unit_id and bu.status_cd = '0'
         left join f_floor f on bu.floor_id = f.floor_id and f.status_cd = '0'
-        left join t_dict td on pfc.fee_type_cd = td.status_cd and td.table_name="pay_fee_config" and td.table_columns="fee_type_cd"
+        left join t_dict td on pfc.fee_type_cd = td.status_cd and td.table_name="pay_fee_config" and
+        td.table_columns="fee_type_cd"
         where t.status_cd = '0'
         <if test="roomNum !=null and roomNum != ''">
             and br.room_num= #{roomNum}
@@ -835,6 +839,10 @@
         left join building_unit bu on br.unit_id = bu.unit_id and bu.status_cd = '0'
         left join f_floor f on bu.floor_id = f.floor_id and f.status_cd = '0'
         left join owner_car oc on pf.payer_obj_id = oc.car_id and oc.status_cd = '0'
+        left join pay_fee_attrs pfa on t.fee_id = pfa.fee_id and pfa.spec_cd = '390002'
+        left join pay_fee_detail_discount pfdd on t.detail_id = pfdd.detail_id and pfdd.status_cd = '0'
+        left join fee_discount fd on pfdd.discount_id = fd.discount_id and fd.status_cd = '0'
+        left join fee_discount_rule fdr on fd.rule_id = fdr.rule_id and fdr.status_cd = '0'
         left join t_dict d on t.prime_rate = d.status_cd and d.table_name="pay_fee_detail" and
         d.table_columns="prime_rate"
         where t.status_cd = '0'
@@ -888,7 +896,8 @@
         select pfc.fee_name feeName,f.floor_num floorNum,bu.unit_num unitNum,br.room_num roomNum,oc.car_num carNum,
         pf.payer_obj_type payerObjType,t.start_time startTime,t.end_time endTime,t.create_time createTime,
         t.receivable_amount receivableAmount,t.received_amount receivedAmount,pfa.`value`
-        importFeeName,t.prime_rate,d.name primeRate
+        importFeeName,t.prime_rate,d.name primeRate,fdr.discount_small_type discountSmallType,fdr.rule_name
+        ruleName,pfdd.discount_price discountPrice
         from pay_fee_detail t
         INNER JOIN pay_fee pf on t.fee_id = pf.fee_id and pf.status_cd = '0'
         inner join pay_fee_config pfc on pf.config_id = pfc.config_id and pfc.status_cd = '0'
@@ -897,6 +906,9 @@
         left join f_floor f on bu.floor_id = f.floor_id and f.status_cd = '0'
         left join owner_car oc on pf.payer_obj_id = oc.car_id and oc.status_cd = '0'
         left join pay_fee_attrs pfa on t.fee_id = pfa.fee_id and pfa.spec_cd = '390002'
+        left join pay_fee_detail_discount pfdd on t.detail_id = pfdd.detail_id and pfdd.status_cd = '0'
+        left join fee_discount fd on pfdd.discount_id = fd.discount_id and fd.status_cd = '0'
+        left join fee_discount_rule fdr on fd.rule_id = fdr.rule_id and fdr.status_cd = '0'
         left join t_dict d on t.prime_rate = d.status_cd and d.table_name="pay_fee_detail" and
         d.table_columns="prime_rate"
         where t.status_cd = '0'
@@ -1003,6 +1015,72 @@
         </if>
     </select>
 
+    <select id="queryPayFeeDetailSum" parameterType="Map" resultType="Map">
+        select pfc.fee_name feeName,f.floor_num floorNum,bu.unit_num unitNum,br.room_num roomNum,oc.car_num carNum,
+        pf.payer_obj_type payerObjType,t.start_time startTime,t.end_time endTime,t.create_time createTime,
+        t.receivable_amount receivableAmount,t.received_amount receivedAmount,pfa.`value`
+        importFeeName,t.prime_rate,d.name primeRate,fdr.discount_small_type discountSmallType,fdr.rule_name ruleName,pfdd.discount_price,
+        SUM(pfdd.discount_price) discountPrice
+        from pay_fee_detail t
+        INNER JOIN pay_fee pf on t.fee_id = pf.fee_id and pf.status_cd = '0'
+        inner join pay_fee_config pfc on pf.config_id = pfc.config_id and pfc.status_cd = '0'
+        left join building_room br on pf.payer_obj_id = br.room_id and pf.payer_obj_type = '3333' and br.status_cd = '0'
+        left join building_unit bu on br.unit_id = bu.unit_id and bu.status_cd = '0'
+        left join f_floor f on bu.floor_id = f.floor_id and f.status_cd = '0'
+        left join owner_car oc on pf.payer_obj_id = oc.car_id and oc.status_cd = '0'
+        left join pay_fee_attrs pfa on t.fee_id = pfa.fee_id and pfa.spec_cd = '390002'
+        left join pay_fee_detail_discount pfdd on t.detail_id = pfdd.detail_id and pfdd.status_cd = '0'
+        left join fee_discount fd on pfdd.discount_id = fd.discount_id and fd.status_cd = '0'
+        left join fee_discount_rule fdr on fd.rule_id = fdr.rule_id and fdr.status_cd = '0'
+        left join t_dict d on t.prime_rate = d.status_cd and d.table_name="pay_fee_detail" and
+        d.table_columns="prime_rate"
+        where t.status_cd = '0'
+        <if test="roomNum !=null and roomNum != ''">
+            and br.room_num= #{roomNum}
+        </if>
+        <if test="unitId !=null and unitId != ''">
+            and bu.unit_id= #{unitId}
+        </if>
+        <if test="floorId !=null and floorId != ''">
+            and f.floor_id = #{floorId}
+        </if>
+        <if test="objName !=null and objName != ''">
+            and t.obj_name= #{objName}
+        </if>
+        <if test="feeYear !=null and feeYear != ''">
+            and t.fee_year= #{feeYear}
+        </if>
+        <if test="feeMonth !=null and feeMonth != ''">
+            and t.fee_month= #{feeMonth}
+        </if>
+        <if test="feeId !=null and feeId != ''">
+            and t.fee_id= #{feeId}
+        </if>
+        <if test="configId !=null and configId != ''">
+            and pfc.config_id= #{configId}
+        </if>
+        <if test="objId !=null and objId != ''">
+            and t.obj_id= #{objId}
+        </if>
+        <if test="feeName !=null and feeName != ''">
+            and t.fee_name= #{feeName}
+        </if>
+        <if test="communityId !=null and communityId != ''">
+            and t.community_id= #{communityId}
+        </if>
+        <if test="primeRate != null and primeRate != ''">
+            and t.prime_rate = #{primeRate}
+        </if>
+        <if test="startTime !=null">
+            and t.create_time &gt;= #{startTime}
+        </if>
+        <if test="endTime !=null">
+            and t.create_time &lt;= #{endTime}
+        </if>
+        group by fdr.discount_small_type
+        order by t.create_time desc
+    </select>
+
     <select id="queryDeadlineFeeCount" parameterType="Map" resultType="Map">
         select count(1) count
         from (

+ 8 - 0
java110-interface/src/main/java/com/java110/intf/report/IReportFeeMonthStatisticsInnerServiceSMO.java

@@ -197,6 +197,14 @@ public interface IReportFeeMonthStatisticsInnerServiceSMO {
     @RequestMapping(value = "/queryAllPayFeeDetail", method = RequestMethod.POST)
     List<ReportFeeMonthStatisticsDto> queryAllPayFeeDetail(@RequestBody ReportFeeMonthStatisticsDto reportFeeMonthStatisticsDto);
 
+    /**
+     * 查询(优惠、减免、滞纳金、空置房打折、空置房减免等)总金额
+     * @param reportFeeMonthStatisticsDto
+     * @return
+     */
+    @RequestMapping(value = "/queryPayFeeDetailSum",method = RequestMethod.POST)
+    List<ReportFeeMonthStatisticsDto> queryPayFeeDetailSum(@RequestBody ReportFeeMonthStatisticsDto reportFeeMonthStatisticsDto);
+
     /**
      * 查询费用汇总表个数
      *

+ 10 - 68
service-front/src/main/java/com/java110/front/smo/assetExport/impl/ExportReportFeeSMOImpl.java

@@ -39,7 +39,6 @@ import java.io.IOException;
 @Service("exportReportFeeSMOImpl")
 public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportReportFeeSMO {
     private final static Logger logger = LoggerFactory.getLogger(ExportReportFeeSMOImpl.class);
-
     public static final String REPORT_FEE_SUMMARY = "reportFeeSummary";
     public static final String REPORT_FLOOR_UNIT_FEE_SUMMARY = "reportFloorUnitFeeSummary";
     public static final String REPORT_FEE_BREAKDOWN = "reportFeeBreakdown";
@@ -84,10 +83,7 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
             case REPORT_PAY_FEE_DETAIL:
                 reportPayFeeDetail(pd, result, workbook);
                 break;
-
         }
-
-
         ByteArrayOutputStream os = new ByteArrayOutputStream();
         MultiValueMap headers = new HttpHeaders();
         headers.add("content-type", "application/octet-stream;charset=UTF-8");
@@ -123,11 +119,13 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
         row.createCell(6).setCellValue("缴费时间");
         row.createCell(7).setCellValue("应收金额");
         row.createCell(8).setCellValue("实收金额");
-
-
+        row.createCell(9).setCellValue("优惠金额");
+        row.createCell(10).setCellValue("减免金额");
+        row.createCell(11).setCellValue("滞纳金");
+        row.createCell(12).setCellValue("空置房打折金额");
+        row.createCell(13).setCellValue("空置房减免金额");
         //查询楼栋信息
         JSONArray rooms = this.getReportPayFeeDetail(pd, result);
-
         if (rooms == null) {
             return;
         }
@@ -135,7 +133,6 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
         for (int roomIndex = 0; roomIndex < rooms.size(); roomIndex++) {
             row = sheet.createRow(roomIndex + 1);
             dataObj = rooms.getJSONObject(roomIndex);
-
             row.createCell(0).setCellValue(roomIndex + 1);
             row.createCell(1).setCellValue(dataObj.getString("objName"));
             row.createCell(2).setCellValue(dataObj.getString("feeName"));
@@ -145,7 +142,11 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
             row.createCell(6).setCellValue(dataObj.getString("createTime"));
             row.createCell(7).setCellValue(dataObj.getString("receivableAmount"));
             row.createCell(8).setCellValue(dataObj.getString("receivedAmount"));
-
+            row.createCell(9).setCellValue(dataObj.getString("preferentialAmount"));
+            row.createCell(10).setCellValue(dataObj.getString("deductionAmount"));
+            row.createCell(11).setCellValue(dataObj.getString("lateFee"));
+            row.createCell(12).setCellValue(dataObj.getString("vacantHousingDiscount"));
+            row.createCell(13).setCellValue(dataObj.getString("vacantHousingReduction"));
         }
     }
 
@@ -157,19 +158,13 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
         reqJson.put("row", 10000);
         apiUrl = ServiceConstant.SERVICE_API_URL + "/api/reportFeeMonthStatistics/queryPayFeeDetail" + mapToUrlParam(reqJson);
         responseEntity = this.callCenterService(restTemplate, pd, "", apiUrl, HttpMethod.GET);
-
         if (responseEntity.getStatusCode() != HttpStatus.OK) { //跳过 保存单元信息
             return null;
         }
-
         JSONObject savedRoomInfoResults = JSONObject.parseObject(responseEntity.getBody(), Feature.OrderedField);
-
-
         if (!savedRoomInfoResults.containsKey("data")) {
             return null;
         }
-
-
         return savedRoomInfoResults.getJSONArray("data");
     }
 
@@ -182,22 +177,18 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
         row.createCell(3).setCellValue("费用开始时间");
         row.createCell(4).setCellValue("欠费时长(天)");
         row.createCell(5).setCellValue("欠费金额");
-
-
         //查询楼栋信息
         JSONArray rooms = this.getReportOweFeeDetail(pd, result);
         JSONObject dataObj = null;
         for (int roomIndex = 0; roomIndex < rooms.size(); roomIndex++) {
             row = sheet.createRow(roomIndex + 1);
             dataObj = rooms.getJSONObject(roomIndex);
-
             row.createCell(0).setCellValue(roomIndex + 1);
             row.createCell(1).setCellValue(dataObj.getString("objName"));
             row.createCell(2).setCellValue(dataObj.getString("feeName"));
             row.createCell(3).setCellValue(dataObj.getString("feeCreateTime"));
             row.createCell(4).setCellValue(dataObj.getString("oweDay"));
             row.createCell(5).setCellValue(dataObj.getString("oweAmount"));
-
         }
     }
 
@@ -211,15 +202,12 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
         row.createCell(4).setCellValue("费用结束时间");
         row.createCell(5).setCellValue("应收金额");
         row.createCell(6).setCellValue("实收金额");
-
-
         //查询楼栋信息
         JSONArray rooms = this.getReportFeeDetail(pd, result);
         JSONObject dataObj = null;
         for (int roomIndex = 0; roomIndex < rooms.size(); roomIndex++) {
             row = sheet.createRow(roomIndex + 1);
             dataObj = rooms.getJSONObject(roomIndex);
-
             row.createCell(0).setCellValue(roomIndex + 1);
             row.createCell(1).setCellValue(dataObj.getString("objName"));
             row.createCell(2).setCellValue(dataObj.getString("feeName"));
@@ -227,7 +215,6 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
             row.createCell(4).setCellValue(dataObj.getString("deadlineTime"));
             row.createCell(5).setCellValue(dataObj.getString("receivableAmount"));
             row.createCell(6).setCellValue(dataObj.getString("receivedAmount"));
-
         }
     }
 
@@ -236,19 +223,13 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
         ResponseEntity<String> responseEntity = null;
         apiUrl = ServiceConstant.SERVICE_API_URL + "/api/reportFeeMonthStatistics/queryOweFeeDetail?communityId=" + result.getCommunityId() + "&page=1&row=10000";
         responseEntity = this.callCenterService(restTemplate, pd, "", apiUrl, HttpMethod.GET);
-
         if (responseEntity.getStatusCode() != HttpStatus.OK) { //跳过 保存单元信息
             return null;
         }
-
         JSONObject savedRoomInfoResults = JSONObject.parseObject(responseEntity.getBody(), Feature.OrderedField);
-
-
         if (!savedRoomInfoResults.containsKey("data")) {
             return null;
         }
-
-
         return savedRoomInfoResults.getJSONArray("data");
     }
 
@@ -257,19 +238,13 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
         ResponseEntity<String> responseEntity = null;
         apiUrl = ServiceConstant.SERVICE_API_URL + "/api/reportFeeMonthStatistics/queryFeeDetail?communityId=" + result.getCommunityId() + "&page=1&row=10000";
         responseEntity = this.callCenterService(restTemplate, pd, "", apiUrl, HttpMethod.GET);
-
         if (responseEntity.getStatusCode() != HttpStatus.OK) { //跳过 保存单元信息
             return null;
         }
-
         JSONObject savedRoomInfoResults = JSONObject.parseObject(responseEntity.getBody(), Feature.OrderedField);
-
-
         if (!savedRoomInfoResults.containsKey("data")) {
             return null;
         }
-
-
         return savedRoomInfoResults.getJSONArray("data");
     }
 
@@ -283,15 +258,12 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
         row.createCell(4).setCellValue("应收金额");
         row.createCell(5).setCellValue("实收金额");
         row.createCell(6).setCellValue("欠费金额");
-
-
         //查询楼栋信息
         JSONArray rooms = this.getReportFeeBreakdown(pd, result);
         JSONObject dataObj = null;
         for (int roomIndex = 0; roomIndex < rooms.size(); roomIndex++) {
             row = sheet.createRow(roomIndex + 1);
             dataObj = rooms.getJSONObject(roomIndex);
-
             row.createCell(0).setCellValue(roomIndex + 1);
             row.createCell(1).setCellValue(dataObj.getString("feeTypeCd"));
             row.createCell(2).setCellValue(dataObj.getString("feeName"));
@@ -299,29 +271,21 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
             row.createCell(4).setCellValue(dataObj.getString("receivableAmount"));
             row.createCell(5).setCellValue(dataObj.getString("receivedAmount"));
             row.createCell(6).setCellValue(dataObj.getString("oweAmount"));
-
         }
     }
 
     private JSONArray getReportFeeBreakdown(IPageData pd, ComponentValidateResult result) {
-
         String apiUrl = "";
         ResponseEntity<String> responseEntity = null;
         apiUrl = ServiceConstant.SERVICE_API_URL + "/api/reportFeeMonthStatistics/queryFeeBreakdown?communityId=" + result.getCommunityId() + "&page=1&row=10000";
         responseEntity = this.callCenterService(restTemplate, pd, "", apiUrl, HttpMethod.GET);
-
         if (responseEntity.getStatusCode() != HttpStatus.OK) { //跳过 保存单元信息
             return null;
         }
-
         JSONObject savedRoomInfoResults = JSONObject.parseObject(responseEntity.getBody(), Feature.OrderedField);
-
-
         if (!savedRoomInfoResults.containsKey("data")) {
             return null;
         }
-
-
         return savedRoomInfoResults.getJSONArray("data");
     }
 
@@ -334,8 +298,6 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
         row.createCell(3).setCellValue("应收金额");
         row.createCell(4).setCellValue("实收金额");
         row.createCell(5).setCellValue("欠费金额");
-
-
         //查询楼栋信息
         JSONArray rooms = this.getReportFloorUnitFeeSummary(pd, result);
         JSONObject dataObj = null;
@@ -348,7 +310,6 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
             row.createCell(3).setCellValue(dataObj.getString("receivableAmount"));
             row.createCell(4).setCellValue(dataObj.getString("receivedAmount"));
             row.createCell(5).setCellValue(dataObj.getString("oweAmount"));
-
         }
     }
 
@@ -357,24 +318,16 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
         ResponseEntity<String> responseEntity = null;
         apiUrl = ServiceConstant.SERVICE_API_URL + "/api/reportFeeMonthStatistics/queryFloorUnitFeeSummary?communityId=" + result.getCommunityId() + "&page=1&row=10000";
         responseEntity = this.callCenterService(restTemplate, pd, "", apiUrl, HttpMethod.GET);
-
         if (responseEntity.getStatusCode() != HttpStatus.OK) { //跳过 保存单元信息
             return null;
         }
-
         JSONObject savedRoomInfoResults = JSONObject.parseObject(responseEntity.getBody(), Feature.OrderedField);
-
-
         if (!savedRoomInfoResults.containsKey("data")) {
             return null;
         }
-
-
         return savedRoomInfoResults.getJSONArray("data");
-
     }
 
-
     /**
      * 查询存在的房屋信息
      * room.queryRooms
@@ -388,21 +341,14 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
         ResponseEntity<String> responseEntity = null;
         apiUrl = ServiceConstant.SERVICE_API_URL + "/api/reportFeeMonthStatistics/queryReportFeeSummary?communityId=" + result.getCommunityId() + "&page=1&row=10000";
         responseEntity = this.callCenterService(restTemplate, pd, "", apiUrl, HttpMethod.GET);
-
         if (responseEntity.getStatusCode() != HttpStatus.OK) { //跳过 保存单元信息
             return null;
         }
-
         JSONObject savedRoomInfoResults = JSONObject.parseObject(responseEntity.getBody(), Feature.OrderedField);
-
-
         if (!savedRoomInfoResults.containsKey("data")) {
             return null;
         }
-
-
         return savedRoomInfoResults.getJSONArray("data");
-
     }
 
     /**
@@ -418,20 +364,16 @@ public class ExportReportFeeSMOImpl extends BaseComponentSMO implements IExportR
         row.createCell(1).setCellValue("应收金额");
         row.createCell(2).setCellValue("实收金额");
         row.createCell(3).setCellValue("欠费金额");
-
-
         //查询楼栋信息
         JSONArray rooms = this.getReportFeeSummaryFee(pd, componentValidateResult);
         JSONObject dataObj = null;
         for (int roomIndex = 0; roomIndex < rooms.size(); roomIndex++) {
             row = sheet.createRow(roomIndex + 1);
             dataObj = rooms.getJSONObject(roomIndex);
-
             row.createCell(0).setCellValue(dataObj.getString("feeYear") + "年" + dataObj.getString("feeMonth") + "月");
             row.createCell(1).setCellValue(dataObj.getString("receivableAmount"));
             row.createCell(2).setCellValue(dataObj.getString("receivedAmount"));
             row.createCell(3).setCellValue(dataObj.getString("oweAmount"));
-
         }
     }
 

+ 131 - 21
service-report/src/main/java/com/java110/report/bmo/reportFeeMonthStatistics/impl/GetReportFeeMonthStatisticsBMOImpl.java

@@ -4,11 +4,11 @@ import com.alibaba.fastjson.JSONObject;
 import com.java110.dto.fee.FeeConfigDto;
 import com.java110.dto.fee.FeeDto;
 import com.java110.dto.reportFeeMonthStatistics.ReportFeeMonthStatisticsDto;
+import com.java110.dto.reportFeeMonthStatistics.ReportFeeMonthStatisticsTotalDto;
 import com.java110.intf.report.IReportFeeMonthStatisticsInnerServiceSMO;
 import com.java110.report.bmo.reportFeeMonthStatistics.IGetReportFeeMonthStatisticsBMO;
 import com.java110.utils.util.DateUtil;
 import com.java110.utils.util.StringUtil;
-import com.java110.vo.FeeDetailResultVo;
 import com.java110.vo.ResultVo;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -198,6 +198,7 @@ public class GetReportFeeMonthStatisticsBMOImpl implements IGetReportFeeMonthSta
         int count = Integer.parseInt(countInfo.get("count").toString());
 
         List<ReportFeeMonthStatisticsDto> reportFeeMonthStatisticsDtos = null;
+        ReportFeeMonthStatisticsTotalDto reportFeeMonthStatisticsTotalDto = new ReportFeeMonthStatisticsTotalDto();
         List<ReportFeeMonthStatisticsDto> reportList = new ArrayList<>();
         //查询该小区下的费用项目
         FeeConfigDto feeConfigDto = new FeeConfigDto();
@@ -207,15 +208,63 @@ public class GetReportFeeMonthStatisticsBMOImpl implements IGetReportFeeMonthSta
         Double allReceivableAmount = 0.0;
         //实收金额(大计)
         Double allReceivedAmount = 0.0;
+        //优惠金额(大计)
+        Double allPreferentialAmount = 0.0;
+        //减免金额(大计)
+        Double allDeductionAmount = 0.0;
+        //滞纳金(大计)
+        Double allLateFee = 0.0;
+        //空置房打折(大计)
+        Double allVacantHousingDiscount = 0.0;
+        //空置房减免(大计)
+        Double allVacantHousingReduction = 0.0;
         if (count > 0) {
+            //查询缴费明细
             reportFeeMonthStatisticsDtos = reportFeeMonthStatisticsInnerServiceSMOImpl.queryPayFeeDetail(reportFeeMonthStatisticsDto);
+            //查询应收、实收总金额(大计)
             List<ReportFeeMonthStatisticsDto> reportFeeMonthStatisticsList = reportFeeMonthStatisticsInnerServiceSMOImpl.queryAllPayFeeDetail(reportFeeMonthStatisticsDto);
+            //查询(优惠、减免、滞纳金、空置房打折、空置房减免金额等)大计总金额
+            List<ReportFeeMonthStatisticsDto> reportFeeMonthStatisticsSum = reportFeeMonthStatisticsInnerServiceSMOImpl.queryPayFeeDetailSum(reportFeeMonthStatisticsDto);
             allReceivableAmount = Double.valueOf(reportFeeMonthStatisticsList.get(0).getAllReceivableAmount());
             allReceivedAmount = Double.valueOf(reportFeeMonthStatisticsList.get(0).getAllReceivedAmount());
+            for (ReportFeeMonthStatisticsDto reportFeeMonthStatistics : reportFeeMonthStatisticsSum) {
+                //这里是查询出的金额总和
+                String discountPrice = reportFeeMonthStatistics.getDiscountPrice();
+                //优惠金额(大计)
+                if (!StringUtil.isEmpty(reportFeeMonthStatistics.getDiscountSmallType()) && reportFeeMonthStatistics.getDiscountSmallType().equals("1")) {
+                    allPreferentialAmount = Double.valueOf(discountPrice);
+                }
+                //减免金额(大计)
+                if (!StringUtil.isEmpty(reportFeeMonthStatistics.getDiscountSmallType()) && reportFeeMonthStatistics.getDiscountSmallType().equals("2")) {
+                    allDeductionAmount = Double.valueOf(discountPrice);
+                }
+                //滞纳金(大计)
+                if (!StringUtil.isEmpty(reportFeeMonthStatistics.getDiscountSmallType()) && reportFeeMonthStatistics.getDiscountSmallType().equals("3")) {
+                    allLateFee = Double.valueOf(discountPrice);
+                }
+                //空置房打折金额(大计)
+                if (!StringUtil.isEmpty(reportFeeMonthStatistics.getDiscountSmallType()) && reportFeeMonthStatistics.getDiscountSmallType().equals("4")) {
+                    allVacantHousingDiscount = Double.valueOf(discountPrice);
+                }
+                //空置房减免金额(大计)
+                if (!StringUtil.isEmpty(reportFeeMonthStatistics.getDiscountSmallType()) && reportFeeMonthStatistics.getDiscountSmallType().equals("5")) {
+                    allVacantHousingReduction = Double.valueOf(discountPrice);
+                }
+            }
             //应收总金额(小计)
             Double totalReceivableAmount = 0.0;
             //实收总金额(小计)
             Double totalReceivedAmount = 0.0;
+            //优惠金额(小计)
+            Double totalPreferentialAmount = 0.0;
+            //减免金额(小计)
+            Double totalDeductionAmount = 0.0;
+            //空置房打折金额(小计)
+            Double totalVacantHousingDiscount = 0.0;
+            //空置房减免金额(小计)
+            Double totalVacantHousingReduction = 0.0;
+            //滞纳金(小计)
+            Double totalLateFee = 0.0;
             for (ReportFeeMonthStatisticsDto reportFeeMonthStatistics : reportFeeMonthStatisticsDtos) {
                 //应收金额
                 Double receivableAmount = Double.valueOf(reportFeeMonthStatistics.getReceivableAmount());
@@ -223,40 +272,101 @@ public class GetReportFeeMonthStatisticsBMOImpl implements IGetReportFeeMonthSta
                 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()
-                            + "栋" + tmpReportFeeMonthStatisticsDto.getUnitNum()
-                            + "单元" + tmpReportFeeMonthStatisticsDto.getRoomNum() + "室");
+                //优惠金额
+                if (!StringUtil.isEmpty(reportFeeMonthStatistics.getDiscountSmallType()) && reportFeeMonthStatistics.getDiscountSmallType().equals("1")) {
+                    //获取优惠金额
+                    Double discountPrice = Double.valueOf(reportFeeMonthStatistics.getDiscountPrice());
+                    totalPreferentialAmount = totalPreferentialAmount + discountPrice;
+                    //优惠金额
+                    reportFeeMonthStatistics.setPreferentialAmount(reportFeeMonthStatistics.getDiscountPrice());
+                }
+                //减免金额
+                if (!StringUtil.isEmpty(reportFeeMonthStatistics.getDiscountSmallType()) && reportFeeMonthStatistics.getDiscountSmallType().equals("2")) {
+                    //获取减免金额
+                    Double discountPrice = Double.valueOf(reportFeeMonthStatistics.getDiscountPrice());
+                    totalDeductionAmount = totalDeductionAmount + discountPrice;
+                    //减免金额
+                    reportFeeMonthStatistics.setDeductionAmount(reportFeeMonthStatistics.getDiscountPrice());
+                }
+                //滞纳金
+                if (!StringUtil.isEmpty(reportFeeMonthStatistics.getDiscountSmallType()) && reportFeeMonthStatistics.getDiscountSmallType().equals("3")) {
+                    //获取滞纳金金额
+                    Double discountPrice = Double.valueOf(reportFeeMonthStatistics.getDiscountPrice());
+                    totalLateFee = totalLateFee + discountPrice;
+                    //滞纳金
+                    reportFeeMonthStatistics.setLateFee(reportFeeMonthStatistics.getDiscountPrice());
+                }
+                //空置房打折
+                if (!StringUtil.isEmpty(reportFeeMonthStatistics.getDiscountSmallType()) && reportFeeMonthStatistics.getDiscountSmallType().equals("4")) {
+                    //空置房打折金额
+                    Double discountPrice = Double.valueOf(reportFeeMonthStatistics.getDiscountPrice());
+                    totalVacantHousingDiscount = totalVacantHousingDiscount + discountPrice;
+                    //空置房打折
+                    reportFeeMonthStatistics.setVacantHousingDiscount(reportFeeMonthStatistics.getDiscountPrice());
+                }
+                //空置房减免
+                if (!StringUtil.isEmpty(reportFeeMonthStatistics.getDiscountSmallType()) && reportFeeMonthStatistics.getDiscountSmallType().equals("5")) {
+                    //空置房减免金额
+                    Double discountPrice = Double.valueOf(reportFeeMonthStatistics.getDiscountPrice());
+                    totalVacantHousingReduction = totalVacantHousingReduction + discountPrice;
+                    //空置房减免
+                    reportFeeMonthStatistics.setVacantHousingReduction(reportFeeMonthStatistics.getDiscountPrice());
+                }
+
+                if (FeeDto.PAYER_OBJ_TYPE_ROOM.equals(reportFeeMonthStatistics.getPayerObjType())) {
+                    reportFeeMonthStatistics.setObjName(reportFeeMonthStatistics.getFloorNum()
+                            + "栋" + reportFeeMonthStatistics.getUnitNum()
+                            + "单元" + reportFeeMonthStatistics.getRoomNum() + "室");
                 } else {
-                    tmpReportFeeMonthStatisticsDto.setObjName(tmpReportFeeMonthStatisticsDto.getCarNum());
+                    reportFeeMonthStatistics.setObjName(reportFeeMonthStatistics.getCarNum());
                 }
 
-                if (!StringUtil.isEmpty(tmpReportFeeMonthStatisticsDto.getImportFeeName())) {
-                    tmpReportFeeMonthStatisticsDto.setFeeName(tmpReportFeeMonthStatisticsDto.getImportFeeName());
+                if (!StringUtil.isEmpty(reportFeeMonthStatistics.getImportFeeName())) {
+                    reportFeeMonthStatistics.setFeeName(reportFeeMonthStatistics.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));
+
                 //费用项目
-                tmpReportFeeMonthStatisticsDto.setFeeConfigDtos(feeConfigDtos);
-                reportList.add(tmpReportFeeMonthStatisticsDto);
+                reportFeeMonthStatistics.setFeeConfigDtos(feeConfigDtos);
+                reportList.add(reportFeeMonthStatistics);
             }
+            //应收总金额(小计)
+            reportFeeMonthStatisticsTotalDto.setTotalReceivableAmount(String.format("%.2f", totalReceivableAmount));
+            //实收金额(小计)
+            reportFeeMonthStatisticsTotalDto.setTotalReceivedAmount(String.format("%.2f", totalReceivedAmount));
+            //优惠金额(小计)
+            reportFeeMonthStatisticsTotalDto.setTotalPreferentialAmount(String.valueOf(totalPreferentialAmount));
+            //减免金额(小计)
+            reportFeeMonthStatisticsTotalDto.setTotalDeductionAmount(String.valueOf(totalDeductionAmount));
+            //滞纳金(小计)
+            reportFeeMonthStatisticsTotalDto.setTotalLateFee(String.valueOf(totalLateFee));
+            //空置房打折(小计)
+            reportFeeMonthStatisticsTotalDto.setTotalVacantHousingDiscount(String.valueOf(totalVacantHousingDiscount));
+            //空置房减免(小计)
+            reportFeeMonthStatisticsTotalDto.setTotalVacantHousingReduction(String.valueOf(totalVacantHousingReduction));
+            //应收金额(大计)
+            reportFeeMonthStatisticsTotalDto.setAllReceivableAmount(String.format("%.2f", allReceivableAmount));
+            //实收金额(大计)
+            reportFeeMonthStatisticsTotalDto.setAllReceivedAmount(String.format("%.2f", allReceivedAmount));
+            //优惠金额(大计)
+            reportFeeMonthStatisticsTotalDto.setAllPreferentialAmount(String.valueOf(allPreferentialAmount));
+            //减免金额(大计)
+            reportFeeMonthStatisticsTotalDto.setAllDeductionAmount(String.valueOf(allDeductionAmount));
+            //滞纳金(大计)
+            reportFeeMonthStatisticsTotalDto.setAllLateFee(String.valueOf(allLateFee));
+            //空置房打折金额(大计)
+            reportFeeMonthStatisticsTotalDto.setAllVacantHousingDiscount(String.valueOf(allVacantHousingDiscount));
+            //空置房减免金额(大计)
+            reportFeeMonthStatisticsTotalDto.setAllVacantHousingReduction(String.valueOf(allVacantHousingReduction));
         } else {
             reportFeeMonthStatisticsDtos = new ArrayList<>();
             reportList.addAll(reportFeeMonthStatisticsDtos);
+            reportFeeMonthStatisticsTotalDto = new ReportFeeMonthStatisticsTotalDto();
         }
 
         /*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);
+        ResultVo resultVo = new ResultVo((int) Math.ceil((double) count / (double) reportFeeMonthStatisticsDto.getRow()), count, reportList, reportFeeMonthStatisticsTotalDto);
 
         ResponseEntity<String> responseEntity = new ResponseEntity<String>(resultVo.toString(), HttpStatus.OK);
 

+ 8 - 0
service-report/src/main/java/com/java110/report/dao/IReportFeeMonthStatisticsServiceDao.java

@@ -232,6 +232,14 @@ public interface IReportFeeMonthStatisticsServiceDao {
      */
     List<Map> queryAllFeeDetail(Map beanCovertMap);
 
+    /**
+     * 查询(优惠、减免、滞纳金、空置房打折、空置房减免等)总金额
+     *
+     * @param beanCovertMap
+     * @return
+     */
+    List<Map> queryPayFeeDetailSum(Map beanCovertMap);
+
     /**
      * 查询费用配置信息(instance过程)
      * 根据bId 查询费用配置信息

+ 6 - 0
service-report/src/main/java/com/java110/report/dao/impl/ReportFeeMonthStatisticsServiceDaoImpl.java

@@ -337,6 +337,12 @@ public class ReportFeeMonthStatisticsServiceDaoImpl extends BaseServiceDao imple
         return businessReportFeeMonthStatisticsInfos;
     }
 
+    @Override
+    public List<Map> queryPayFeeDetailSum(Map info) {
+        List<Map> businessReportFeeMonthStatisticsInfos = sqlSessionTemplate.selectList("reportFeeMonthStatisticsServiceDaoImpl.queryPayFeeDetailSum", info);
+        return businessReportFeeMonthStatisticsInfos;
+    }
+
     /**
      * 查询费用配置信息(instance)
      *

+ 6 - 0
service-report/src/main/java/com/java110/report/smo/impl/ReportFeeMonthStatisticsInnerServiceSMOImpl.java

@@ -231,6 +231,12 @@ public class ReportFeeMonthStatisticsInnerServiceSMOImpl extends BaseServiceSMO
         return reportFeeMonthStatisticss;
     }
 
+    @Override
+    public List<ReportFeeMonthStatisticsDto> queryPayFeeDetailSum(@RequestBody ReportFeeMonthStatisticsDto reportFeeMonthStatisticsDto) {
+        List<ReportFeeMonthStatisticsDto> reportFeeMonthStatisticss = BeanConvertUtil.covertBeanList(reportFeeMonthStatisticsServiceDaoImpl.queryPayFeeDetailSum(BeanConvertUtil.beanCovertMap(reportFeeMonthStatisticsDto)), ReportFeeMonthStatisticsDto.class);
+        return reportFeeMonthStatisticss;
+    }
+
     @Override
     public int queryDeadlineFeeCount(@RequestBody ReportFeeMonthStatisticsDto reportFeeMonthStatisticsDto) {
         return reportFeeMonthStatisticsServiceDaoImpl.queryDeadlineFeeCount(BeanConvertUtil.beanCovertMap(reportFeeMonthStatisticsDto));