sth
This commit is contained in:
parent
e1cd94e678
commit
090890f7e2
|
|
@ -704,7 +704,7 @@ class Order extends Backend
|
|||
|
||||
$result = false;
|
||||
Db::startTrans();
|
||||
$order = model('order')->get($params['order_id'], ['dispatch']);
|
||||
$order = model('order')->get($params['order_id']);
|
||||
if (!$order) {
|
||||
$this->error('Not Find');
|
||||
}
|
||||
|
|
@ -717,9 +717,10 @@ class Order extends Backend
|
|||
|
||||
$result = $order->allowField(true)->save($params);
|
||||
|
||||
if (!empty($order->dispatch->id)) {
|
||||
$dispatch = OrderDispatch::where('order_id', $order->id)->where('status','>',0)->find();
|
||||
if (!empty($dispatch)) {
|
||||
$orderLogic = new OrderLogic();
|
||||
$orderLogic->cancelOrderDispatch($order->dispatch, $this->auth, '订单被取消', false);
|
||||
$orderLogic->cancelOrderDispatch($dispatch, $this->auth, '订单被取消', false);
|
||||
}
|
||||
//日志
|
||||
$hookparams['order'] = $order;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user