Jelajahi Sumber

清单汇总规则调整

MaiXinRong 5 tahun lalu
induk
melakukan
9c67714bdf
1 mengubah file dengan 2 tambahan dan 1 penghapusan
  1. 2 1
      app/public/js/gcl_gather.js

+ 2 - 1
app/public/js/gcl_gather.js

@@ -296,6 +296,7 @@ const gclGatherModel = (function () {
         for (const node of nodes) {
             if (node.b_code) {
                 if (node.children.length > 0) {
+                    const gcl = getGclNode(node);
                     recursiveGatherGclData(node.children, leafXmj);
                 } else {
                     loadGatherGclNode(node, leafXmj);
@@ -310,8 +311,8 @@ const gclGatherModel = (function () {
         if (deal && deal.length > 0) {
             for (const node of deal) {
                 node.b_code = node.code;
-                if (!node.quantity || !node.unit_price) continue;
                 const gcl = getGclNode(node);
+                if (!node.quantity || !node.unit_price) continue;
                 gcl.deal_bills_qty = node.quantity;
                 gcl.deal_bills_tp = node.total_price;
             }