Merge pull request 'fix(api): 修复演示逻辑中产品查询' (#502) from dev into main

Reviewed-on: #502
This commit is contained in:
mkm 2025-02-03 15:42:57 +08:00
commit 40732d55cc

View File

@ -121,7 +121,7 @@ class DemoLogic extends BaseLogic
$cartInfo = BeforehandOrderCartInfo::where('bhoid', $params['id'])->select()->toArray();
$productIds = array_column($cartInfo, 'product_id');
$products = StoreProduct::whereIn('id', $productIds)->select()->toArray();
$products = StoreProduct::whereIn('id', $productIds)->withTrashed()->select()->toArray();
$products = reset_index($products, 'id');
$update = [];
foreach ($cartInfo as $v) {