鞭策牛马
This commit is contained in:
parent
cc3ff1e900
commit
57c0c44c3d
|
|
@ -8,6 +8,7 @@ use app\admin\model\Message;
|
||||||
use app\admin\model\Order;
|
use app\admin\model\Order;
|
||||||
use app\admin\model\OrderDispatch;
|
use app\admin\model\OrderDispatch;
|
||||||
use app\common\Logic\OrderLogic;
|
use app\common\Logic\OrderLogic;
|
||||||
|
use Carbon\Carbon;
|
||||||
use think\console\Command;
|
use think\console\Command;
|
||||||
use think\console\Input;
|
use think\console\Input;
|
||||||
use think\console\Output;
|
use think\console\Output;
|
||||||
|
|
@ -32,7 +33,7 @@ class CheckOrderDispatchCommand extends Command
|
||||||
->join('order_dispatch_notify n', 'o.id = n.order_id','left')
|
->join('order_dispatch_notify n', 'o.id = n.order_id','left')
|
||||||
->where('o.status', Order::STATUS_DISPATCHING)
|
->where('o.status', Order::STATUS_DISPATCHING)
|
||||||
->whereNull('n.id') // 没有记录就表示还没通知
|
->whereNull('n.id') // 没有记录就表示还没通知
|
||||||
->where('o.create_time', '<=', now()->format('Y-m-d H:i:s'))
|
->where('o.create_time', '<=', (new Carbon())->subMinutes(20)->format('Y-m-d H:i:s'))
|
||||||
->field(['o.id','o.area_id','o.order_no'])
|
->field(['o.id','o.area_id','o.order_no'])
|
||||||
->select();
|
->select();
|
||||||
$log_insert = [];
|
$log_insert = [];
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user