public IActionResult Index()
        {
            //var a = JsonSerializer.Serialize(_ISysUserServices.GetList());
            ViewBag.UserName = UserName;
            List <SysMenu> menus = _ISysMenuServices.Nesting(_ISysMenuServices.GetListByUserId(Current.Id, Current.Name, Current.UserType));

            if (menus == null || menus.Count == 0)
            {
                ViewBag.MenuList = new List <SysMenu>();
            }
            else
            {
                ViewBag.MenuList = menus[0].Children;
            }
            return(View());
        }
예제 #2
0
 public List <SysMenu> GetMenuList()
 {
     return(_ISysMenuServices.Nesting(_ISysMenuServices.GetList(true)));
 }