fix: 修改sercurity的UserDetailsService的实现类
这个提交包含在:
父节点
4fe4936dfd
当前提交
3a30a2a34c
@ -7,6 +7,7 @@ import com.cnbm.admin.dto.SysUserDTO;
|
||||
import com.cnbm.admin.entity.LoginUser;
|
||||
import com.cnbm.admin.entity.SysMenuEntity;
|
||||
import com.cnbm.admin.entity.SysUserEntity;
|
||||
import com.cnbm.admin.exception.LoginStatusException;
|
||||
import com.cnbm.admin.service.SysMenuService;
|
||||
import com.cnbm.common.utils.ConvertUtils;
|
||||
import lombok.extern.log4j.Log4j2;
|
||||
@ -48,7 +49,7 @@ public class UserDetailsServiceImpl implements UserDetailsService {
|
||||
throw new UsernameNotFoundException("用户名不存在");
|
||||
}
|
||||
if (sysUserEntity.getStatus() == 0) {
|
||||
throw new DisabledException("该账户已被禁用,请联系管理员");
|
||||
throw new LoginStatusException("该账户已被禁用,请联系管理员");
|
||||
}
|
||||
log.info("sysUserEntity的值是"+sysUserEntity.toString());
|
||||
log.info("sysUserEntity.getSuperAdmin()=="+sysUserEntity.getSuperAdmin());
|
||||
|
正在加载...
在新工单中引用
屏蔽一个用户