diff --git a/application/admin/controller/orders/Dispatch2.php b/application/admin/controller/orders/Dispatch2.php index 324610e..94eb748 100644 --- a/application/admin/controller/orders/Dispatch2.php +++ b/application/admin/controller/orders/Dispatch2.php @@ -288,6 +288,7 @@ class Dispatch2 extends Backend $validate = is_bool($this->modelValidate) ? ($this->modelSceneValidate ? $name . '.edit' : $name) : $this->modelValidate; $row->validateFailException()->validate($validate); } + $params['status'] = OrderDispatch::STATUS_FINISH; $params['finish_time'] = date('Y-m-d H:i:s'); $result = $row->allowField(true)->save($params); @@ -376,7 +377,7 @@ class Dispatch2 extends Backend * @throws DataNotFoundException * @throws ModelNotFoundException */ - public function del() + public function del($ids=null) { if (false === $this->request->isPost()) { $this->error(__("Invalid parameters")); diff --git a/application/admin/view/orders/auditorder/edit.html b/application/admin/view/orders/auditorder/edit.html index 2d42163..5392f79 100644 --- a/application/admin/view/orders/auditorder/edit.html +++ b/application/admin/view/orders/auditorder/edit.html @@ -161,9 +161,7 @@
- +
diff --git a/application/admin/view/orders/dispatch2/edit.html b/application/admin/view/orders/dispatch2/edit.html index 027b5f9..b3a0080 100644 --- a/application/admin/view/orders/dispatch2/edit.html +++ b/application/admin/view/orders/dispatch2/edit.html @@ -15,35 +15,35 @@
- +
- +
- +
- +
- +
@@ -51,14 +51,14 @@
- +
- +
@@ -66,7 +66,7 @@
- +
@@ -74,7 +74,7 @@
- +
@@ -121,12 +121,19 @@ +
+ +
+ +
+
+ @@ -178,7 +185,7 @@ - {notempty} + {/notempty} diff --git a/application/common/Logic/OrderLogic.php b/application/common/Logic/OrderLogic.php index bafe7d7..92a1b77 100644 --- a/application/common/Logic/OrderLogic.php +++ b/application/common/Logic/OrderLogic.php @@ -36,7 +36,7 @@ class OrderLogic { $order = $this->OrderModel->where('id',$orderDispatch->order_id)->find(); - if(!$order->status != Order::STATUS_DISPATCHED){ + if($order->status != Order::STATUS_DISPATCHED){ throw new Exception('订单状态不允许当前操作'); }