cqpCow 1 year ago
parent
commit
98ad4cf95f
1 changed files with 5 additions and 1 deletions
  1. 5 1
      app/Service/CustomerService.php

+ 5 - 1
app/Service/CustomerService.php

@@ -637,7 +637,11 @@ class CustomerService extends Service
     public function customerGrabbing($data, $user){
         $key = Customer::$limitKey . $data['customer_id'];
         list($status,$msg) = $this->customerGrabbingRule($data,$key);
-        if(! $status) return [false,$msg];
+        if(! $status) {
+            //释放锁
+            $this->dellimitingSendRequestBackg($key);
+            return [false,$msg];
+        }
 
         try {
             DB::beginTransaction();