import {NgModule} from '@angular/core'; import {RouterModule} from '@angular/router'; import {EnvironmentSpecificResolver} from "../openaireLibrary/utils/properties/environmentSpecificResolver"; import {AdminLoginGuard} from "../openaireLibrary/login/adminLoginGuard.guard"; import {AdminDashboardGuard} from "../utils/adminDashboard.guard"; @NgModule({ imports: [ RouterModule.forChild([ {path: '', redirectTo: '/admin', pathMatch: 'full'}, { path: 'portals', loadChildren: '../openaireLibrary/dashboard/portal/portals.module#PortalsModule', canActivate:[AdminLoginGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: 'entities', loadChildren: '../openaireLibrary/dashboard/entity/entities.module#EntitiesModule', canActivate:[AdminLoginGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: 'classes', loadChildren: '../openaireLibrary/dashboard/divId/divIds.module#DivIdsModule', canActivate:[AdminLoginGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: 'classContents', loadChildren: '../openaireLibrary/dashboard/divhelpcontent/div-help-contents.module#DivHelpContentsModule', canActivate:[AdminLoginGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: 'classContents/new', loadChildren: '../openaireLibrary/dashboard/divhelpcontent/new-div-help-content.module#NewDivHelpContentModule', canActivate:[AdminLoginGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: 'classContents/edit', loadChildren: '../openaireLibrary/dashboard/divhelpcontent/edit-div-help-content.module#EditDivHelpContentModule', canActivate:[AdminLoginGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: 'helptexts', loadChildren: '../openaireLibrary/dashboard/helpTexts/page-help-contents.module#PageHelpContentsModule', canActivate:[AdminLoginGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: 'helptexts/new', loadChildren: '../openaireLibrary/dashboard/helpTexts/new-page-help-content.module#NewPageHelpContentModule', canActivate:[AdminLoginGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: 'helptexts/edit', loadChildren: '../openaireLibrary/dashboard/helpTexts/edit-page-help-content.module#EditPageHelpContentModule', canActivate:[AdminLoginGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: 'pages', loadChildren: '../openaireLibrary/dashboard/page/pages.module#PagesModule', canActivate:[AdminLoginGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: 'pageContents', loadChildren: '../openaireLibrary/dashboard/helpTexts/page-help-contents.module#PageHelpContentsModule', canActivate:[AdminLoginGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: 'pageContents/new', loadChildren: '../openaireLibrary/dashboard/helpTexts/new-page-help-content.module#NewPageHelpContentModule', canActivate:[AdminLoginGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: 'pageContents/edit', loadChildren: '../openaireLibrary/dashboard/helpTexts/edit-page-help-content.module#EditPageHelpContentModule', canActivate:[AdminLoginGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, // stakeholder: { path: ':stakeholder/entities', loadChildren: '../openaireLibrary/dashboard/entity/entities.module#EntitiesModule', canActivate:[AdminDashboardGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: ':stakeholder/classContents', loadChildren: '../openaireLibrary/dashboard/divhelpcontent/div-help-contents.module#DivHelpContentsModule', canActivate:[AdminDashboardGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: ':stakeholder/classContents/new', loadChildren: '../openaireLibrary/dashboard/divhelpcontent/new-div-help-content.module#NewDivHelpContentModule', canActivate:[AdminDashboardGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: ':stakeholder/classContents/edit', loadChildren: '../openaireLibrary/dashboard/divhelpcontent/edit-div-help-content.module#EditDivHelpContentModule', canActivate:[AdminDashboardGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: ':stakeholder/helptexts', loadChildren: '../openaireLibrary/dashboard/helpTexts/page-help-contents.module#PageHelpContentsModule', canActivate:[AdminDashboardGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: ':stakeholder/helptexts/new', loadChildren: '../openaireLibrary/dashboard/helpTexts/new-page-help-content.module#NewPageHelpContentModule', canActivate:[AdminDashboardGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: ':stakeholder/helptexts/edit', loadChildren: '../openaireLibrary/dashboard/helpTexts/edit-page-help-content.module#EditPageHelpContentModule', canActivate:[AdminDashboardGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: ':stakeholder/pages', loadChildren: '../openaireLibrary/dashboard/page/pages.module#PagesModule', canActivate:[AdminDashboardGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: ':stakeholder/pageContents', loadChildren: '../openaireLibrary/dashboard/helpTexts/page-help-contents.module#PageHelpContentsModule', canActivate:[AdminDashboardGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: ':stakeholder/pageContents/new', loadChildren: '../openaireLibrary/dashboard/helpTexts/new-page-help-content.module#NewPageHelpContentModule', canActivate:[AdminDashboardGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} }, { path: ':stakeholder/pageContents/edit', loadChildren: '../openaireLibrary/dashboard/helpTexts/edit-page-help-content.module#EditPageHelpContentModule', canActivate:[AdminDashboardGuard], resolve: { envSpecific: EnvironmentSpecificResolver }, data: {hasAdminMenu: true} } ]) ] }) export class AdminToolRoutingModule { }