From 154acc53add962d6a25daf2e9b50bb17b292d75c Mon Sep 17 00:00:00 2001 From: "liang.chao" Date: Mon, 29 Jan 2024 14:51:37 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8D=97=E7=BD=91oss=E7=99=BB=E5=BD=95?= =?UTF-8?q?=E6=8E=A5=E5=8F=A3=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../sgzb/auth/service/SysLoginService.java | 32 ------------------- 1 file changed, 32 deletions(-) diff --git a/sgzb-auth/src/main/java/com/bonus/sgzb/auth/service/SysLoginService.java b/sgzb-auth/src/main/java/com/bonus/sgzb/auth/service/SysLoginService.java index 26596815..b4feb35f 100644 --- a/sgzb-auth/src/main/java/com/bonus/sgzb/auth/service/SysLoginService.java +++ b/sgzb-auth/src/main/java/com/bonus/sgzb/auth/service/SysLoginService.java @@ -89,38 +89,6 @@ public class SysLoginService { return userInfo; } - public LoginUser loginApprove(String username, String password) { - - // IP黑名单校验 - isBlackIp(username); - // 查询用户信息 - R userResult = remoteUserService.getUserInfo(username, SecurityConstants.INNER); - - if (StringUtils.isNull(userResult) || StringUtils.isNull(userResult.getData())) { - recordLogService.recordLogininfor(username, Constants.LOGIN_FAIL, "登录用户不存在"); - throw new ServiceException("登录用户:" + username + " 不存在"); - } - - if (R.FAIL == userResult.getCode()) { - throw new ServiceException(userResult.getMsg()); - } - - LoginUser userInfo = userResult.getData(); - SysUser user = userResult.getData().getSysUser(); - if (UserStatus.DELETED.getCode().equals(user.getDelFlag())) { - recordLogService.recordLogininfor(username, Constants.LOGIN_FAIL, "对不起,您的账号已被删除"); - throw new ServiceException("对不起,您的账号:" + username + " 已被删除"); - } - if (UserStatus.DISABLE.getCode().equals(user.getStatus())) { - recordLogService.recordLogininfor(username, Constants.LOGIN_FAIL, "用户已停用,请联系管理员"); - throw new ServiceException("对不起,您的账号:" + username + " 已停用"); - } - passwordService.validate(user, password); - recordLogService.recordLogininfor(username, Constants.LOGIN_SUCCESS, "登录成功"); - return userInfo; - } - - /** * 手机号验证码登录 */