增加账号被禁用拦截
This commit is contained in:
parent
41c7a26577
commit
67657a4af9
|
@ -40,6 +40,10 @@ class UserController
|
||||||
// 根据手机号查询用户
|
// 根据手机号查询用户
|
||||||
$user = User::where('username', '=', $username)->first();
|
$user = User::where('username', '=', $username)->first();
|
||||||
|
|
||||||
|
if($user->status==0){
|
||||||
|
return ApiResponseApp::error('账号被禁用');
|
||||||
|
}
|
||||||
|
|
||||||
// // 如果未找到用户,返回错误
|
// // 如果未找到用户,返回错误
|
||||||
if (!$user) {
|
if (!$user) {
|
||||||
return ApiResponseApp::error('账号或密码错误');
|
return ApiResponseApp::error('账号或密码错误');
|
||||||
|
|
Loading…
Reference in New Issue