Bladeren bron

去除重复的 ProductClass::handleLimitBuy()

shizhongqi 2 maanden geleden
bovenliggende
commit
402c7a220d
1 gewijzigde bestanden met toevoegingen van 13 en 13 verwijderingen
  1. 13 13
      app-hd/controllers/PurchaseController.php

+ 13 - 13
app-hd/controllers/PurchaseController.php

@@ -471,19 +471,19 @@ class PurchaseController extends BaseController
                         }
                     }
                 }
-
-                foreach ($productList as $itemData) {
-                    $productId = $itemData['productId'] ?? 0;
-                    $product = $productInfoList[$productId] ?? [];
-                    if (empty($product)) {
-                        util::fail('有商品信息没有找到');
-                    }
-                    $bigNum = $itemData['bigNum'] ?? 0;
-                    if (($product['limitBuy'] ?? 0) > 0) {
-                        $product['productId'] = $productId;
-                        ProductClass::handleLimitBuy($product, $customId, floatval($bigNum));
-                    }
-                }
+// 已经有了 -- 在 replaceItem()
+//                foreach ($productList as $itemData) {
+//                    $productId = $itemData['productId'] ?? 0;
+//                    $product = $productInfoList[$productId] ?? [];
+//                    if (empty($product)) {
+//                        util::fail('有商品信息没有找到');
+//                    }
+//                    $bigNum = $itemData['bigNum'] ?? 0;
+//                    if (($product['limitBuy'] ?? 0) > 0) {
+//                        $product['productId'] = $productId;
+//                        ProductClass::handleLimitBuy($product, $customId, floatval($bigNum));
+//                    }
+//                }
 
             } else {
                 util::fail('花材不存在');