...
|
...
|
@@ -479,6 +479,14 @@ class Order extends Api |
|
|
*/
|
|
|
public function dealAction($order){
|
|
|
$grab = OrderGrab::where('order_id',$order['id'])->find();
|
|
|
// 给用户发送抢单成功通知
|
|
|
(new Message)->save([
|
|
|
'user_id' => $grab['user_id'],
|
|
|
'order_id' => $grab['order_id'],
|
|
|
'order_grab_id' => $grab['id'],
|
|
|
'type' => '1',
|
|
|
'grab_status' => '1',
|
|
|
]);
|
|
|
$grab->save(['status'=>'2','receive_time'=>time()]);
|
|
|
// 发单状态改为进行中
|
|
|
$order->save(['status'=>'2','order_grab_id'=>$grab['id']]);
|
...
|
...
|
|