shish 2 ani în urmă
părinte
comite
35c2883e01
1 a modificat fișierele cu 10 adăugiri și 0 ștergeri
  1. 10 0
      biz-ghs/stat/classes/StatSaleClass.php

+ 10 - 0
biz-ghs/stat/classes/StatSaleClass.php

@@ -727,6 +727,10 @@ class StatSaleClass extends BaseClass
                 $localCharge = $cgItem['localCharge'] ?? 0;
                 $cgStaffId = $cgItem['cgStaffId'] ?? 0;
                 $cgStaffName = $cgItem['cgStaffName'] ?? '';
+                $actPrice = $cgItem['actPrice'] ?? 0;
+                if ($actPrice <= 0) {
+                    continue;
+                }
                 $packFreight = bcadd($packFreight, $packingCharge, 2);
                 $packFreight = bcadd($packFreight, $shortCharge, 2);
                 $packFreight = bcadd($packFreight, $longCharge, 2);
@@ -816,6 +820,9 @@ class StatSaleClass extends BaseClass
                 $shopAdminName = $ghsOrder['shopAdminName'] ?? '';
                 $orderSn = $ghsOrder['orderSn'] ?? '';
                 $actPrice = $ghsOrder['actPrice'] ?? 0;
+                if ($actPrice <= 0) {
+                    continue;
+                }
                 $tkPrice = $ghsOrder['tkPrice'] ?? 0;
                 $pfIncome = bcadd($pfIncome, $actPrice, 2);
                 $labourCost = $ghsOrder['labourCost'] ?? 0;
@@ -887,6 +894,9 @@ class StatSaleClass extends BaseClass
         $hdOrderList = HdOrderClass::getAllByCondition($hdWhere, null, '*');
         foreach ($hdOrderList as $hdKey => $hdOrder) {
             $actPrice = $hdOrder['mainPay'] ?? 0;
+            if ($actPrice <= 0) {
+                continue;
+            }
             $cash = $hdOrder['cash'] ?? 0;
             $lsIncome = bcadd($actPrice, $lsIncome, 2);
             $lsIncome = bcadd($lsIncome, $cash, 2);