未登录首页异常
This commit is contained in:
parent
4f9eaf9aca
commit
df1fba7465
|
|
@ -108,6 +108,9 @@ public class AuthorizationInterceptor extends HandlerInterceptorAdapter {
|
|||
|
||||
// 设置 userId 到 request 里,后续根据 userId 获取用户信息
|
||||
UserEntity user = userService.selectUserById(userId);
|
||||
if(user == null) {
|
||||
throw new CzgException("会话失效,请重新登录");
|
||||
}
|
||||
if (user != null && user.getStatus().equals(0)) {
|
||||
throw new CzgException("异常行为用户: {}" + user.getUserId());
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue