From 91b63727f8394c13e71b62e784fb418d2630bf49 Mon Sep 17 00:00:00 2001 From: xman <1946321327@qq.com> Date: Wed, 16 Apr 2025 10:34:26 +0800 Subject: [PATCH] sth --- application/common/command/CheckOrdeRecordCommand.php | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/application/common/command/CheckOrdeRecordCommand.php b/application/common/command/CheckOrdeRecordCommand.php index 13d83b1..750c35a 100644 --- a/application/common/command/CheckOrdeRecordCommand.php +++ b/application/common/command/CheckOrdeRecordCommand.php @@ -22,17 +22,19 @@ class CheckOrdeRecordCommand extends Command $Model = new OrderDispatchRecord(); $now = date('Y-m-d H:i:s'); //创建三十分名以上未接的任务 - $Model->where('need_notice',1) - ->where('notice_time','<=',$now) + //$Model->where('need_notice',1) + $Model->where('notice_time','<=',$now) ->where('status',0) ->chunk(100, function ($list) { $ids = []; $dispatchIds = []; foreach ($list as $item) { - //todo...通知逻辑 $ids[] = $item->id; - $dispatchIds = $item->dispatch_id; + $dispatchIds[] = $item->dispatch_id; //修改状态 + if($item->need_notice == 1){ //需要通知 + + } } OrderDispatchRecord::whereIn('id',$ids)->update(['status'=>1]); OrderDispatch::where('id',$dispatchIds)->where('follow',1)->update(['follow'=>0]);