diff --git a/Application/Sdk/Controller/UserController.class.php b/Application/Sdk/Controller/UserController.class.php index de0a92a8..1736a933 100644 --- a/Application/Sdk/Controller/UserController.class.php +++ b/Application/Sdk/Controller/UserController.class.php @@ -28,6 +28,14 @@ class UserController extends BaseController $this -> set_message(1001, "fail", "登录数据不能为空"); } + + $ip = get_client_ip(); + $device_bans_ip = M('device_bans','tab_')->where(['tag' => $ip,'type' => 2])->find(); + $device_bans_num = M('device_bans','tab_')->where(['tag' => $user['device_number'],'type' => 1])->find(); + if(!empty($device_bans_ip) || !empty($device_bans_num)){ + $this->set_message(1004, "fail", "用户已被禁用"); + } + /*是否开启Ucenter*/ if (C('UC_OPEN') == 1) { $userApi = new MemberApi();