Beispiel #1
0
        protected async override Task OnInitializedAsync()
        {
            await base.OnInitializedAsync();

            if (MenuDataList != null)
            {
                TopMenu = MenuDataList.Where(menu => menu.ParentId == 0 || menu.ParentId == null).ToList();
            }
        }
Beispiel #2
0
 protected override void OnAfterRender(bool firstRender)
 {
     if (firstRender)
     {
         if (MenuDataList != null)
         {
             TopMenu = MenuDataList.Where(menu => menu.ParentId == 0 || menu.ParentId == null).ToList();
         }
     }
 }