Browse Source

重复请求问题

shish 11 months ago
parent
commit
379f7e9c1f
1 changed files with 12 additions and 0 deletions
  1. 12 0
      app-hd/controllers/IntraCityController.php

+ 12 - 0
app-hd/controllers/IntraCityController.php

@@ -43,6 +43,9 @@ class IntraCityController extends BaseController
             $sjName = $shop->merchantName ?? '';
             $name = $shopName == '首店' ? $sjName : $sjName . ' ' . $shopName;
 
+            $adminId = $this->adminId;
+            util::checkRepeatCommit($adminId, 4);
+
             $storeData = [
                 'out_store_id' => $this->mainId, //自定义门店编号 --  从 shopId 改为 dmainId
                 'store_name' => $name,
@@ -141,6 +144,9 @@ class IntraCityController extends BaseController
             util::fail('未创建门店,请先创建');
         }
 
+        $adminId = $this->adminId;
+        util::checkRepeatCommit($adminId, 4);
+
         $shop = $this->shop;
         $shopName = $shop->shopName ?? '';
         $sjName = $shop->merchantName ?? '';
@@ -324,6 +330,10 @@ class IntraCityController extends BaseController
     {
         try {
             $post = Yii::$app->request->post();
+
+            $adminId = $this->adminId;
+            util::checkRepeatCommit($adminId, 4);
+
             $orderId = $post['orderId'];
             $field = 'mainId, status, sendStatus, repeat, forward, orderSn, userId, actPrice, sendNum';
             $order = OrderClass::getById($orderId, false, $field);
@@ -567,6 +577,8 @@ class IntraCityController extends BaseController
         try {
             $post = Yii::$app->request->post();
 
+            $adminId = $this->adminId;
+            util::checkRepeatCommit($adminId, 4);
 
             //$shopExt = ShopExtClass::getByCondition(['shopId' => $shopId], false, false, 'id, wxStoreId');
             $shopExt = MainClass::getById($this->mainId, false, 'id, wxStoreId');