Browse Source

打款凭证审核bug修复

郭齐峰 2 years ago
parent
commit
dfbe25d058
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/custom/restcontroller/webmanage/sale/paybill/Paybill.java

+ 2 - 2
src/custom/restcontroller/webmanage/sale/paybill/Paybill.java

@@ -262,16 +262,16 @@ public class Paybill extends Controller {
         long sys_enterpriseid = rows.get(0).getLong("sys_enterpriseid");
         String billno = rows.get(0).getString("billno");
         String remarks = rows.get(0).getString("remarks");
+        dbConnect.runSqlUpdate(sqlList);
         for (Row row : accountclassRows) {
             BigDecimal amount = row.getBigDecimal("amount");
             CashbillEntity cashbillEntity = new CashbillEntity(amount, remarks, "打款凭证", billno, "sa_paybill", sa_paybillid, "货款", "");
-            sqlList.addAll(Accountbalance.createCashbillIncome(this, sys_enterpriseid, row.getLong("sa_accountclassid"), cashbillEntity, false));
+            sqlList = Accountbalance.createCashbillIncome(this, sys_enterpriseid, row.getLong("sa_accountclassid"), cashbillEntity, false);
             dbConnect.runSqlUpdate(sqlList);
 
             String message = "您的打款凭证已审核通过,【"+row.getString("accountname")+"】账户已成功充值【"+amount+"】元";
             sendMsg(message, sa_paybillid, sys_enterpriseid);
         }
-        dbConnect.runSqlUpdate(sqlList);
         return getSucReturnObject().toString();
     }