Ver código fonte

避免连续点击的重复请求

shish 7 meses atrás
pai
commit
e5e320272d

+ 4 - 0
app-ghs/controllers/DeliveryController.php

@@ -249,6 +249,10 @@ class DeliveryController extends BaseController
              util::fail('订单已经发过跑腿');
          }
 
+        //避免连续点击的重复提交 ssh
+        $adminId = $this->adminId;
+        util::checkRepeatCommit($adminId, 3);
+
         $ds = new DispatchService($this->mainId, $platform);
         $ret = $ds->createOrder($ghsOrder, 'xhGhsOrder', $this->shopId, $params);
 

+ 4 - 0
app-hd/controllers/DeliveryController.php

@@ -160,6 +160,10 @@ class DeliveryController extends BaseController
             util::fail('订单已经发过跑腿');
         }
 
+        //避免连续点击的重复提交 ssh
+        $adminId = $this->adminId;
+        util::checkRepeatCommit($adminId, 3);
+
         $ds = new DispatchService($this->mainId, $platform);
         $ret = $ds->createOrder($Order, 'xhOrder', $this->shopId, $params);