12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788 |
- using Dto;
- using Model;
- using Vo;
- namespace Services
- {
- public interface ISysMenuService : IBaseService<SysMenu>
- {
- //List<SysMenu> SelectMenuList(long userId);
- List<SysMenu> SelectMenuList(MenuQueryDto menu, long userId);
- List<TreeSelectVo> SelectTreeMenuList(MenuQueryDto menu, long userId);
- SysMenu GetMenuByMenuId(int menuId);
- List<SysMenu> GetMenusByMenuId(int menuId, long userId);
- long AddMenu(SysMenu menu);
- long EditMenu(SysMenu menu);
- int DeleteMenuById(int menuId);
- string CheckMenuNameUnique(SysMenu menu);
- int ChangeSortMenu(MenuDto menuDto);
- bool HasChildByMenuId(long menuId);
- List<SysMenu> SelectMenuTreeByUserId(long userId);
- //List<SysMenu> SelectMenuPermsListByUserId(long userId);
- List<string> SelectMenuPermsByUserId(long userId);
- //bool CheckMenuExistRole(long menuId);
- List<RouterVo> BuildMenus(List<SysMenu> menus);
- List<TreeSelectVo> BuildMenuTreeSelect(List<SysMenu> menus);
- List<LeftMenuVo> BuildLeftMenuTreeSelect(List<SysMenu> menus);
- List<SysMenu> SelectTreeMenuListByRoles(MenuQueryDto menu, List<long> roles);
- List<RoleMenuExportDto> SelectRoleMenuListByRole(MenuQueryDto menu, int roleId);
- }
- /// <summary>
- /// 角色菜单
- /// </summary>
- public interface ISysRoleMenuService : IBaseService<SysRoleMenu>
- {
- bool CheckMenuExistRole(long menuId);
- /// <summary>
- /// 根据角色获取菜单id
- /// </summary>
- /// <param name="roleId"></param>
- /// <returns></returns>
- List<SysRoleMenu> SelectRoleMenuByRoleId(long roleId);
- /// <summary>
- /// 根据用户所有角色获取菜单
- /// </summary>
- /// <param name="roleIds"></param>
- /// <returns></returns>
- List<SysRoleMenu> SelectRoleMenuByRoleIds(long[] roleIds);
- /// <summary>
- /// 批量插入用户菜单
- /// </summary>
- /// <param name="sysRoleMenus"></param>
- /// <returns></returns>
- int AddRoleMenu(List<SysRoleMenu> sysRoleMenus);
- /// <summary>
- /// 删除角色与菜单关联
- /// </summary>
- /// <param name="roleId"></param>
- /// <returns></returns>
- int DeleteRoleMenuByRoleId(long roleId);
- /// <summary>
- /// 删除角色指定菜单
- /// </summary>
- /// <param name="roleId"></param>
- /// <param name="menuIds"></param>
- /// <returns></returns>
- bool DeleteRoleMenuByRoleIdMenuIds(long roleId, long[] menuIds);
- }
- }
|