Răsfoiți Sursa

门店管理员不能登录系统端

moonsflyer 4 luni în urmă
părinte
comite
629ff3e11f
2 a modificat fișierele cu 4 adăugiri și 1 ștergeri
  1. 1 1
      app/lang/zh-cn/model.php
  2. 3 0
      app/model/system/User.php

+ 1 - 1
app/lang/zh-cn/model.php

@@ -78,7 +78,7 @@ return [
     'USER_GROUP_NOT_ALL_DELETE' => '用户组不能批量删除' ,
     'USER_GROUP_USED' => '存在使用当前用户组的用户,不可删除!' ,
     'USER_LOGIN_ERROR' => '账号或密码错误' ,
-
+    'USER_IS_SHOP_GROUP' => '门店管理员不能登录系统端' ,
     'CAPTCHA_FAILURE' => '验证码已失效' ,
     'CAPTCHA_ERROR' => '验证码不正确' ,
     //上传

+ 3 - 0
app/model/system/User.php

@@ -561,6 +561,9 @@ class User extends BaseModel
         if ($user_info[ 'status' ] !== 1) {
             return $this->error([], 'USER_IS_LOCKED');
         }
+        if ($user_info['group_id'] == 2){
+            return $this->error([], 'USER_IS_SHOP_GROUP');
+        }
         $this->initLogin($user_info);
         return $this->success();
     }