aa
jiangping
2024-08-02 7dc29ed74ebaa8a0e66f68264d9a13f95dc3af21
server/service/src/main/java/com/doumee/config/Jwt/WebMvcConfig.java
@@ -102,13 +102,13 @@
                throw new BusinessException(ResponseStatus.DATA_EMPTY);
            }
            if(Objects.isNull(member.getOpenid())){
                throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"用户已注销,请重新登录");
                throw new BusinessException(ResponseStatus.USER_DISABLE_TIME.getCode(),"用户已注销,请重新登录");
            }
            if(Constants.equalsInteger(member.getIsdeleted(),Constants.ONE)){
                throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"用户已删除,请联系管理员");
                throw new BusinessException(ResponseStatus.USER_DISABLE_TIME.getCode(),"用户已删除,请联系管理员");
            }
            if(!Constants.equalsInteger(member.getStatus(),Constants.ZERO)){
                throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"用户已禁用,请联系管理员");
                throw new BusinessException(ResponseStatus.USER_DISABLE_TIME.getCode(),"用户已禁用,请联系管理员");
            }
            request.setAttribute(JwtTokenUtil.UserId_Name, memberId);
            request.setAttribute(JwtTokenUtil.UserType, ZTConstants.CUSTOMER);
@@ -132,10 +132,10 @@
                throw new BusinessException(ResponseStatus.DATA_EMPTY);
            }
            if(Constants.equalsInteger(users.getIsdeleted(),Constants.ONE)){
                throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"用户已删除,请联系管理员");
                throw new BusinessException(ResponseStatus.USER_DISABLE_TIME.getCode(),"用户已删除,请联系管理员");
            }
            if(!StringUtils.equals(users.getStatus(),Constants.ONE+"")){
                throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"用户已禁用,请联系管理员");
                throw new BusinessException(ResponseStatus.USER_DISABLE_TIME.getCode(),"用户状态异常,请重新登录");
            }
            request.setAttribute(JwtTokenUtil.UserId_Name, userId);
            request.setAttribute(JwtTokenUtil.UserType, ZTConstants.BUSINESS);