wuxw лет назад: 2
Родитель
Сommit
26c671981c

+ 8 - 9
java110-db/src/main/resources/mapper/report/ReportFeeStatisticsServiceDaoImplMapper.xml

@@ -912,15 +912,14 @@
 
     <!-- 滞纳金费用-->
     <select id="getLateFee" parameterType="Map" resultType="Map">
-        select ifnull(SUM(t.discount_amount),0.0) lateFee
-        from pay_fee_detail_month t
-        where 1=1
-        and t.status_cd = '0'
-        and t.detail_id != '-1'
-        and t.discount_amount &lt; 0
-        and t.community_id= #{communityId}
-        and t.cur_month_time &gt; #{startDate}
-        and t.cur_month_time &lt; #{endDate}
+        select ifnull(SUM(t.discount_price),0.0) lateFee
+        from pay_fee_detail_discount t
+        inner join fee_discount fd on t.discount_id = fd.discount_id
+        where t.status_cd = '0'
+        and fd.discount_type = '2002'
+        and t.community_id =  #{communityId}
+        and t.create_time &gt; #{startDate}
+        and t.create_time &lt; #{endDate}
     </select>
 
     <!-- 查询预存账户-->