shish 2 years ago
parent
commit
5a1adb2e18
1 changed files with 5 additions and 2 deletions
  1. 5 2
      app-ghs/controllers/OrderController.php

+ 5 - 2
app-ghs/controllers/OrderController.php

@@ -1631,11 +1631,14 @@ class OrderController extends BaseController
     {
         $post = Yii::$app->request->post();
         $id = $post['id'] ?? 0;
-        $remark = $post['remakr'] ?? '';
+        $remark = $post['remark'] ?? '';
         $order = OrderClass::getById($id, true);
         if (empty($order)) {
             util::fail('没有找到订单');
         }
+        if ($order->mainI != $this->mainId) {
+            util::fail('不是你的订单');
+        }
         $cgId = $order->purchaseId ?? 0;
         $cg = PurchaseClass::getById($cgId, true);
         if (empty($cg)) {
@@ -1648,4 +1651,4 @@ class OrderController extends BaseController
         util::complete('修改成功');
     }
 
-}
+}