|
|
|
@@ -184,7 +184,7 @@ public class SysRoleServiceImpl implements ISysRoleService |
|
|
|
public void checkRoleAllowed(SysRole role) |
|
|
|
{ |
|
|
|
Set<String> roles = SecurityUtils.getLoginUser().getRoles(); |
|
|
|
if (StringUtils.isNotNull(role.getRoleId()) && role.isAdmin()) |
|
|
|
if (StringUtils.isNotNull(role.getRoleId()) && role.isAdmin() && !roles.contains("admin")) |
|
|
|
{ |
|
|
|
throw new ServiceException("不允许操作超级管理员角色"); |
|
|
|
} |
|
|
|
|