From 4289eebb57c08389a0b7fbef74c6fae555f6ee63 Mon Sep 17 00:00:00 2001 From: root Date: Mon, 1 Dec 2025 15:35:49 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B8=A6=E6=81=AF=E5=80=BA=E5=8A=A1=E7=BB=9F?= =?UTF-8?q?=E8=AE=A1=E6=8A=A5=E8=A1=A8=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../report/InterestBearingRptListPlugin.java | 38 ++++++++++--------- 1 file changed, 20 insertions(+), 18 deletions(-) diff --git a/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/plugin/report/InterestBearingRptListPlugin.java b/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/plugin/report/InterestBearingRptListPlugin.java index 0bff395..f927e96 100644 --- a/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/plugin/report/InterestBearingRptListPlugin.java +++ b/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/plugin/report/InterestBearingRptListPlugin.java @@ -382,7 +382,7 @@ public class InterestBearingRptListPlugin extends AbstractReportListDataPlugin { "INNER JOIN t_cfm_loanbill_e s2 ON s1.fid = s2.FID \n" + "WHERE (s2.floantype = 'loan' OR s2.floantype = 'sl' OR s2.floantype = 'bond') \n" + "AND (s1.fdrawtype = 'drawed' OR s1.fdrawtype = 'partpayment') \n" + -// "AND t1.FBILLNO = s1.FBILLNO \n" + + "AND t1.FBILLNO = s1.FBILLNO \n" + "GROUP BY to_char(s2.fstartintdate,'yyyy') having to_char(s2.fstartintdate,'yyyy') < '"+year+"')"; //年度新增金额 String selYearAddAmt = "(SELECT sum(isnull(s1.fdrawamount,0))\n" + @@ -390,7 +390,7 @@ public class InterestBearingRptListPlugin extends AbstractReportListDataPlugin { "INNER JOIN t_cfm_loanbill_e s2 ON s1.fid = s2.FID \n" + "WHERE (s2.floantype = 'loan' OR s2.floantype = 'sl' OR s2.floantype = 'bond') \n" + "AND (s1.fdrawtype = 'drawed' OR s1.fdrawtype = 'partpayment') \n" + -// "AND t1.FBILLNO = s1.FBILLNO \n" + + "AND t1.FBILLNO = s1.FBILLNO \n" + "GROUP BY to_char(s2.fstartintdate,'yyyy')having to_char(s2.fstartintdate,'yyyy') = '"+year+"')"; //年度已还金额 String selYearYhkAmt = "(SELECT sum(isnull(s5.frepayamount,0)) sumamt\n" + @@ -400,7 +400,7 @@ public class InterestBearingRptListPlugin extends AbstractReportListDataPlugin { "inner JOIN t_cfm_repaymentbill s6 ON s5.fid = s6.fid\n" + "WHERE (s2.floantype = 'loan' OR s2.floantype = 'sl' OR s2.floantype = 'bond') \n" + "AND (s1.fdrawtype = 'drawed' OR s1.fdrawtype = 'partpayment') \n" + -// "AND t1.FBILLNO = s1.FBILLNO \n" + + "AND t1.FBILLNO = s1.FBILLNO \n" + "GROUP BY to_char(s6.fbizdate,'yyyy') having to_char(s6.fbizdate,'yyyy') = '"+year+"')"; //年末未还金额 String selYearNmAmt = "(SELECT sum(sum(isnull(s1.fnotrepayamount,0)))\n" + @@ -408,7 +408,7 @@ public class InterestBearingRptListPlugin extends AbstractReportListDataPlugin { "INNER JOIN t_cfm_loanbill_e s2 ON s1.fid = s2.FID \n" + "WHERE (s2.floantype = 'loan' OR s2.floantype = 'sl' OR s2.floantype = 'bond') \n" + "AND (s1.fdrawtype = 'drawed' OR s1.fdrawtype = 'partpayment') \n" + -// "AND t1.FBILLNO = s1.FBILLNO \n" + + "AND t1.FBILLNO = s1.FBILLNO \n" + "GROUP BY to_char(s2.fstartintdate,'yyyy') having to_char(s2.fstartintdate,'yyyy') > '"+year+"')"; DataSet selData = null; //业务单元数据集 @@ -848,13 +848,14 @@ public class InterestBearingRptListPlugin extends AbstractReportListDataPlugin { * @return */ public String selBjAmt(String wheYear) { - String sql = "(SELECT sum(isnull(t3.fexdrawamount,0))\n" + - "FROM t_cfm_loanbill t1 \n" + - "INNER JOIN t_cfm_loanbill_e t2 ON t1.fid = t2.FID \n" + - "LEFT JOIN t_cfm_loanbill_rp_entry t3 ON t1.fid = t3.fid\n" + - "WHERE (t2.floantype = 'loan' OR t2.floantype = 'sl' OR t2.floantype = 'bond') \n" + - "AND (t1.fdrawtype = 'drawed' OR t1.fdrawtype = 'partpayment') \n" + - "and to_char(t3.fexrepaymentdate,'yyyy') "+wheYear+")"; + String sql = "(SELECT sum(isnull(s3.fexdrawamount,0))\n" + + "FROM t_cfm_loanbill s1 \n" + + "INNER JOIN t_cfm_loanbill_e s2 ON s1.fid = s2.FID \n" + + "LEFT JOIN t_cfm_loanbill_rp_entry s3 ON s1.fid = s3.fid\n" + + "WHERE (s2.floantype = 'loan' OR s2.floantype = 'sl' OR s2.floantype = 'bond') \n" + + "AND (s1.fdrawtype = 'drawed' OR s1.fdrawtype = 'partpayment') \n" + + "AND t1.FBILLNO = s1.FBILLNO \n" + + "and to_char(s3.fexrepaymentdate,'yyyy') "+wheYear+")"; return sql; } @@ -863,13 +864,14 @@ public class InterestBearingRptListPlugin extends AbstractReportListDataPlugin { * @return */ public String selLxAmt(String wheYear) { - String sql = "(SELECT sum(isnull(t3.finterestcalamount,0))\n" + - "FROM t_cfm_loanbill t1 \n" + - "INNER JOIN t_cfm_loanbill_e t2 ON t1.fid = t2.FID \n" + - "LEFT JOIN t_cfm_loanbill_ic_entry t3 ON t1.fid = t3.fid\n" + - "WHERE (t2.floantype = 'loan' OR t2.floantype = 'sl' OR t2.floantype = 'bond') \n" + - "AND (t1.fdrawtype = 'drawed' OR t1.fdrawtype = 'partpayment') \n" + - "and to_char(t3.finteresdate,'yyyy') "+wheYear+")"; + String sql = "(SELECT sum(isnull(s3.finterestcalamount,0))\n" + + "FROM t_cfm_loanbill s1 \n" + + "INNER JOIN t_cfm_loanbill_e s2 ON s1.fid = s2.FID \n" + + "LEFT JOIN t_cfm_loanbill_ic_entry s3 ON s1.fid = s3.fid\n" + + "WHERE (s2.floantype = 'loan' OR s2.floantype = 'sl' OR s2.floantype = 'bond') \n" + + "AND (s1.fdrawtype = 'drawed' OR s1.fdrawtype = 'partpayment') \n" + + "AND t1.FBILLNO = s1.FBILLNO \n" + + "and to_char(s3.finteresdate,'yyyy') "+wheYear+")"; return sql; }