mirror of
				https://github.com/YunaiV/ruoyi-vue-pro.git
				synced 2025-10-31 18:49:06 +08:00 
			
		
		
		
	!945 bugfix:修复获取登录用户的权限信息接口在没有授权角色时,没有菜单列表导致报错的问题
Merge pull request !945 from a472159403/bug_getMenuList
This commit is contained in:
		| @ -11,6 +11,7 @@ import cn.iocoder.yudao.module.system.enums.permission.MenuTypeEnum; | ||||
| import cn.iocoder.yudao.module.system.service.tenant.TenantService; | ||||
| import com.google.common.annotations.VisibleForTesting; | ||||
| import lombok.extern.slf4j.Slf4j; | ||||
| import org.apache.commons.compress.utils.Lists; | ||||
| import org.springframework.cache.annotation.CacheEvict; | ||||
| import org.springframework.cache.annotation.Cacheable; | ||||
| import org.springframework.context.annotation.Lazy; | ||||
| @ -130,6 +131,10 @@ public class MenuServiceImpl implements MenuService { | ||||
|  | ||||
|     @Override | ||||
|     public List<MenuDO> getMenuList(Collection<Long> ids) { | ||||
|         // 当ids为空时,返回一个空的实例对象 | ||||
|         if (CollUtil.isEmpty(ids)) { | ||||
|             return Lists.newArrayList(); | ||||
|         } | ||||
|         return menuMapper.selectBatchIds(ids); | ||||
|     } | ||||
|  | ||||
|  | ||||
		Reference in New Issue
	
	Block a user
	 芋道源码
					芋道源码