优化数据权限代码

pull/502/MERGE
RuoYi 2024-06-13 14:58:04 +08:00
parent 4f5bf990bf
commit 116bed00a5
1 changed files with 2 additions and 2 deletions

View File

@ -158,9 +158,9 @@ public class SysLoginService
public void setRolePermission(SysUser user)
{
List<SysRole> roles = user.getRoles();
if (!roles.isEmpty() && roles.size() > 1)
if (!roles.isEmpty())
{
// 多角色设置permissions属性以便数据权限匹配权限
// 设置permissions属性以便数据权限匹配权限
for (SysRole role : roles)
{
Set<String> rolePerms = menuService.selectPermsByRoleId(role.getRoleId());