Open Closed

Modify left menú in razor mvc .NetCore #200


User avatar
0
CesarSaenzTorrez created

How can I modify the side menu, to add an item like the administration one with submenus items, is in razors pages netcore mvc, thank you.

  • ABP Framework version: 2.8
  • UI type: MVC
  • Tiered (MVC) or Identity Server Seperated (Angular): no

3 Answer(s)
  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    You can manage the menus in the ConfigureMenuAsync method.

    https://github.com/abpframework/abp/blob/ace4b5526eb00d0ed6429834693fc618dc6c54b2/modules/identity/src/Volo.Abp.Identity.Web/Navigation/AbpIdentityWebMainMenuContributor.cs#L31

    public class MyMenuContributor : IMenuContributor
    {
    	public async Task ConfigureMenuAsync(MenuConfigurationContext context)
    	{
                
    	}
    }
    
  • User Avatar
    0
    CesarSaenzTorrez created

    I know thats the file, but I need create one item how ADMINISTRACION like this:

    • MenuPadre
      • Menu Hijo 1
      • Menu Hijo 2
      • Menu Hijo 3
    • Menu Padre 2
      • Menu Hijo 4
      • Menu Hijo 5

    I see the GetAdministration() but i not undertand how reply this in other submenúes, sorry for ask, im new in this framework.

  • User Avatar
    0
    CesarSaenzTorrez created

    Its Ok:

    `var CatalogoMenuItem = new ApplicationMenuItem( "BibliotecaWeb.Regioness", l["Menu:Regioness"], icon: "fa fa-id-card-o");

            context.Menu.AddItem(CatalogoMenuItem);`
            
    

    Later additem to CatalogoMenuItem, thanks so much, im confused.

Made with ❤️ on ABP v9.1.0-preview. Updated on November 11, 2024, 11:11