From efe8b7c6ce61ef937e0959ec06ba9cdb7f3f706d Mon Sep 17 00:00:00 2001 From: yaooo <272523191@qq.com> Date: Fri, 8 Sep 2023 16:50:18 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E5=A7=94=E6=89=98=E5=95=86?= =?UTF-8?q?=E5=93=81=E6=94=B6=E8=B4=A7=E6=96=B9=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../order/StoreOrderCreateRepository.php | 20 +------------------ 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/app/common/repositories/store/order/StoreOrderCreateRepository.php b/app/common/repositories/store/order/StoreOrderCreateRepository.php index 2dcbee92..433c12f1 100644 --- a/app/common/repositories/store/order/StoreOrderCreateRepository.php +++ b/app/common/repositories/store/order/StoreOrderCreateRepository.php @@ -119,24 +119,6 @@ class StoreOrderCreateRepository extends StoreOrderRepository } } } - if ($order_type == 99) { - $sourceIdArray = []; - foreach($merchantCart['list'] as $prod){ - if ($prod['source_id'] > 0) { - $sourceIdArray[] = $prod['source_id']; - } - } - if (count($sourceIdArray)) { - if (count(array_unique($sourceIdArray)) > 1) { - throw new ValidateException('委托商品数据异常'); - } - $community = Db::name('Community')->where('community_id', $sourceIdArray[0] ?? 0)->field('community_id, title, image')->fetchSql(false)->find(); - if ($community) { - $deliverMethod = Db::name('entrust')->where('community_id', $sourceIdArray[0] ?? 0)->value('deliver_method'); - $deliverMethodArray = explode(',', $deliverMethod); - } - } - } unset($merchantCart, $cart); $order_price = 0; $total_true_price = 0; @@ -158,7 +140,7 @@ class StoreOrderCreateRepository extends StoreOrderRepository $order_svip_discount = 0; // 循环计算每个店铺的订单数据 委托商品是否设置收货方式 ? foreach ($merchantCartList as &$merchantCart) { - if (($order_type == 98 || $order_type == 99) && !empty($deliverMethodArray)) { + if ($order_type == 98 && !empty($deliverMethodArray)) { $merchantCart['delivery_way'] = $deliverMethodArray; } $postageRule = [];