| | |
| | | import com.gkhy.exam.common.constant.UserConstant; |
| | | import com.gkhy.exam.common.domain.entity.SysRole; |
| | | import com.gkhy.exam.common.domain.entity.SysUser; |
| | | import com.gkhy.exam.common.utils.SecurityUtils; |
| | | import com.gkhy.exam.common.utils.StringUtils; |
| | | import com.gkhy.exam.system.service.ISysMenuService; |
| | | import com.gkhy.exam.system.service.ISysRoleService; |
| | |
| | | { |
| | | Set<String> roles = new HashSet<String>(); |
| | | // 管理员拥有所有权限 |
| | | if (user.isAdmin()) |
| | | if (SecurityUtils.isAdmin(user.getId())) |
| | | { |
| | | roles.add("admin"); |
| | | } |
| | |
| | | { |
| | | Set<String> perms = new HashSet<String>(); |
| | | // 管理员拥有所有权限 |
| | | if (user.isAdmin()) |
| | | if (SecurityUtils.isAdmin(user.getId())) |
| | | { |
| | | perms.add("*:*:*"); |
| | | } |