Browse Source

账户扣款信息bug修复

eganwu 1 year ago
parent
commit
1251546f3d

+ 4 - 2
src/custom/restcontroller/webmanage/sale/order/OrderItemsHelper.java

@@ -34,8 +34,10 @@ public class OrderItemsHelper extends BaseClass {
 
     public long getAccountClassId(String type) throws YosException {
 
-        if ((type.equals("标准订单") || type.equals("特殊订单"))) {
-            return content.getLong("sa_accountclassid");
+        Long sa_accountclassid = content.getLong("sa_accountclassid");
+
+        if ((type.equals("标准订单") || type.equals("特殊订单")) && sa_accountclassid > 0) {
+            return sa_accountclassid;
         }
         if (type.equals("促销订单")) {
             Rows accountclassRows = dbConnect.runSqlQuery("select sa_accountclassid from sa_promotion where siteid='" + controller.siteid + "' and sa_promotionid=" + content.getLongValue("sa_promotionid"));