fix trigger bug 2
This commit is contained in:
@@ -205,10 +205,12 @@ class ConditionalOrderService
|
||||
|
||||
public function expirePendingPastDue(): int
|
||||
{
|
||||
$now = now()->timezone(config('app.timezone'))->format('Y-m-d H:i:s');
|
||||
|
||||
return ConditionalOrder::query()
|
||||
->where('status', ConditionalOrder::STATUS_PENDING)
|
||||
->whereNotNull('expires_at')
|
||||
->where('expires_at', '<', now())
|
||||
->where('expires_at', '<', $now)
|
||||
->update([
|
||||
'status' => ConditionalOrder::STATUS_EXPIRED,
|
||||
'is_active' => false,
|
||||
|
||||
Reference in New Issue
Block a user