更新修复转售商品配送方式异常

This commit is contained in:
yaooo 2023-08-26 15:11:38 +08:00
parent eb2c6aeb5c
commit bcd0fa539a

View File

@ -112,9 +112,9 @@ class StoreOrderCreateRepository extends StoreOrderRepository
if (count(array_unique($sourceIdArray)) > 1) { if (count(array_unique($sourceIdArray)) > 1) {
throw new ValidateException('转售商品数据异常'); throw new ValidateException('转售商品数据异常');
} }
$community = Db::name('Community')->where('community_id', $communityIdArray[0] ?? 0)->field('community_id, title, image')->fetchSql(false)->find(); $community = Db::name('Community')->where('community_id', $sourceIdArray[0] ?? 0)->field('community_id, title, image')->fetchSql(false)->find();
if ($community) { if ($community) {
$deliverMethod = Db::name('resale')->where('community_id', $communityIdArray[0] ?? 0)->value('deliver_method'); $deliverMethod = Db::name('resale')->where('community_id', $sourceIdArray[0] ?? 0)->value('deliver_method');
$deliverMethodArray = explode(',', $deliverMethod); $deliverMethodArray = explode(',', $deliverMethod);
} }
} }