Browse Source

Merge branch 'master' of http://192.168.1.41:3000/maixinrong/Calculation

TonyKang 5 years ago
parent
commit
53cfa1b920
1 changed files with 4 additions and 2 deletions
  1. 4 2
      app/lib/rpt_data_analysis.js

+ 4 - 2
app/lib/rpt_data_analysis.js

@@ -741,7 +741,7 @@ const gatherStagePay = {
                 for (const [i, f] of fData.entries()) {
                     f.order = cData.order;
                     f.subOrder = i;
-                    result.push(fData);
+                    result.push(f);
                 }
             } else {
                 if (!cData.order_calc && cData.empty !== 1) {
@@ -751,12 +751,14 @@ const gatherStagePay = {
             }
         }
         rdaUtils.orderCalc(ctx, result, calcFields);
+
         data[options.table] = result.filter(function (x) {
             return x.visible === undefined || x.visible;
         });
+        
         data[options.table].sort(function (a, b) {
             return a.order === b.order ? a.subOrder - b.subOrder : a.order - b.order;
-        })
+        });
     },
 };
 const union = {