Explorar el Código

师傅入驻审核状态更新

whitefang hace 2 años
padre
commit
9e260a4adb
Se han modificado 1 ficheros con 10 adiciones y 1 borrados
  1. 10 1
      app/workerapi/logic/LoginLogic.php

+ 10 - 1
app/workerapi/logic/LoginLogic.php

@@ -53,7 +53,16 @@ class LoginLogic extends BaseLogic
     {
         try {
             $master = MasterWorkerRegister::where('mobile',$params['mobile'])->findOrEmpty();
-            if(!$master->isEmpty()){
+
+            if(!$master->isEmpty() and $master->status==1){
+                throw new \Exception('该手机号已入驻');
+            }
+
+            if(!$master->isEmpty() and $master->status==0){
+                throw new \Exception('该手机号后台审核中');
+            }
+
+            if(!$master->isEmpty() and $master->status==2){
                 $master->save([
                     'maintain_exp_type' => $params['maintain_exp_type'],
                     'other_exp_type' => $params['other_exp_type'],