Merge branch 'feature/purchase_record' into dev

This commit is contained in:
luofei 2023-07-13 14:27:06 +08:00
commit 1a528707d1

View File

@ -71,7 +71,7 @@ class StoreGroupOrderRepository extends BaseRepository
}
$query->when(isset($where['paid']) && $where['paid'] !== '', function ($query) use ($where) {
if ($where['paid'] == 0) {
$query->whereRaw("StoreGroupOrder.paid=0 or (StoreGroupOrder.paid=1 and StoreGroupOrder.pay_type=8 and StoreOrder.status=2)");
$query->whereRaw("(StoreGroupOrder.paid=0 and status!=12) or (StoreGroupOrder.paid=1 and StoreGroupOrder.pay_type=8 and StoreOrder.status=2)");
} else {
$query->where('StoreGroupOrder.paid', $where['paid']);
}