fix(admin): 修复预售订单未设置商品数量的查询逻辑

- 在查询未设置商品数量时,增加了对当前订单的筛选条件
- 确保只统计当前订单下的未设置商品,提高了数据准确性
This commit is contained in:
mkm 2024-11-14 15:41:32 +08:00
parent 0cfe453652
commit 9267218da0

View File

@ -83,7 +83,7 @@ class BeforehandOrderLists extends BaseAdminDataLists implements ListsSearchInte
}
}
if($item->msg==''){
$count=BeforehandOrderCartInfo::where('is_buyer',0)->count('id');
$count=BeforehandOrderCartInfo::where('is_buyer',0)->where('bhoid',$item['id'])->count('id');
if($count>0){
$item->msg='有'.$count.'个商品未设置';
}