调整领取奖品查询sql
parent
df8fe0991f
commit
7d3aa6881f
|
|
@ -412,7 +412,9 @@ class OrderService
|
|||
if ($_giftsRule['times'] == 0 && OrderProduct::where([
|
||||
'activity_id' => $partActivity->activity_id,
|
||||
'user_id' => $order->user_id,
|
||||
])->exists()) {
|
||||
])->whereHas('order', function ($query) {//除取消外的订单
|
||||
return $query->where('status', '<>', Order::STATUS_CANCELLED);
|
||||
})->exists()) {
|
||||
continue;//提前结束本次循环
|
||||
}
|
||||
//判断是否满足门槛
|
||||
|
|
|
|||
Loading…
Reference in New Issue