You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
monitor-dashboard/src/app/monitor/monitor-routing.module.ts

58 lines
1.7 KiB
TypeScript

import {NgModule} from '@angular/core';
import {RouterModule} from '@angular/router';
import {PreviousRouteRecorder} from '../openaireLibrary/utils/piwik/previousRouteRecorder.guard';
import {MonitorComponent} from "./monitor.component";
@NgModule({
imports: [
RouterModule.forChild([
{path: '', redirectTo: '/admin', pathMatch: 'full'},
{
path: ':stakeholder',
component: MonitorComponent,
canDeactivate: [PreviousRouteRecorder]
},
{
path: ':stakeholder/develop',
loadChildren: () => import('../develop/develop.module').then(m => m.DevelopModule),
canDeactivate: [PreviousRouteRecorder],
data: {
hasSidebar: false,
isDashboard: false
}
},
{
path: ':stakeholder/methodology',
loadChildren: () => import('../methodology/methodology.module').then(m => m.MethodologyModule),
canDeactivate: [PreviousRouteRecorder],
data: {
hasSidebar: false,
isDashboard: false
}
},
{
path: ':stakeholder/search',
loadChildren: () => import('../search/search.module').then(m => m.SearchModule),
canDeactivate: [PreviousRouteRecorder]
},
{
path: ':stakeholder/:topic',
component: MonitorComponent,
canDeactivate: [PreviousRouteRecorder]
},
{
path: ':stakeholder/:topic/:category',
component: MonitorComponent,
canDeactivate: [PreviousRouteRecorder]
},
{
path: ':stakeholder/:topic/:category/:subCategory',
component: MonitorComponent,
canDeactivate: [PreviousRouteRecorder]
}
])
]
})
export class MonitorRoutingModule {
}