新增角色BUG修改

This commit is contained in:
秦鸿展
2026-06-27 19:00:43 +08:00
parent dc589fdf3f
commit 8be0813e21
@@ -384,6 +384,10 @@ public class TokenLoginApplicationService {
throw new ServiceException("用户不存在/密码错误");
}
}
// 验证码登录时 userInfo.getUserPo() 可能为null,加保护
if (userInfo == null || userInfo.getUserPo() == null || userInfo.getUserPo().getOrganizationId() == null) {
throw new ServiceException("登录用户组织信息不完整,请联系管理员");
}
R<OrganizationPo> organizationInfo = organizationServiceFeign.getInfoForIdList(userInfo.getUserPo().getOrganizationId());
if (ObjectUtil.isNull(organizationInfo) || ObjectUtil.isNull(organizationInfo.getData())) {
throw new ServiceException("登录用户组织不存在");