Starts in:
2 DAYS
1 HR
57 MIN
50 SEC
Starts in:
2 D
1 H
57 M
50 S
Open Closed

Add new menu item in Saas menu in sidebar menu #4068


User avatar
0
tommy.reynolds@pentair.com created

Hi ABP Support

Can you help me the way I have to add a new menu item in Saas menu in the sidebar, please? So I can edit or add a new menu item in it, please!

If you're creating a bug/problem report, please include followings:

  • ABP Framework version: 6
  • UI type: Angular
  • DB provider: EF Core

1 Answer(s)
  • User Avatar
    0
    muhammedaltug created

    Hello,

    Can you add the following lines to your route.provider.ts file?

    import { eLayoutType, RoutesService } from '@abp/ng.core';
    import { APP_INITIALIZER } from '@angular/core';
    import { eSaasRouteNames } from '@volo/abp.ng.saas/config';
    
    export const APP_ROUTE_PROVIDER = [
      { provide: APP_INITIALIZER, useFactory: configureRoutes, deps: [RoutesService], multi: true },
    ];
    
    function configureRoutes(routes: RoutesService) {
      return () => {
        routes.add([
          // other routes
          {
            path: '/my-path',
            name: 'MenuName',
            iconClass: 'fas fa-chart-line',
            order: 2,
            layout: eLayoutType.application,
            parentName: eSaasRouteNames.Saas,
          },
        ]);
      };
    }
    
    

    You can read the documentation about Modifying-the-Menu

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