2017-09-22 12:26:08 +02:00
|
|
|
/**
|
|
|
|
* Created by stefania on 9/16/16.
|
|
|
|
*/
|
|
|
|
import { ModuleWithProviders } from '@angular/core';
|
|
|
|
import { Routes, RouterModule } from '@angular/router';
|
|
|
|
|
|
|
|
import { DashboardComponent } from "./dashboard.component";
|
2017-12-20 15:26:30 +01:00
|
|
|
import { CommunitiesComponent } from './pages/community/communities.component';
|
2018-01-04 15:32:31 +01:00
|
|
|
import { CommunityEditFormComponent } from "./pages/community/community-edit-form.component";
|
2018-02-06 15:10:07 +01:00
|
|
|
import { EntitiesComponent } from "./pages/entity/entities.component";
|
|
|
|
import { PagesComponent } from "./pages/page/pages.component";
|
2017-09-22 12:26:08 +02:00
|
|
|
import { PageHelpContentsComponent } from "./pages/helpcontent/page-help-contents.component";
|
|
|
|
import { NewPageHelpContentComponent } from "./pages/helpcontent/new-page-help-content.component";
|
|
|
|
import { EditPageHelpContentComponent } from "./pages/helpcontent/edit-page-help-content.component";
|
2018-02-06 12:06:43 +01:00
|
|
|
import { DivIdsComponent } from "./pages/divId/divIds.component";
|
|
|
|
import { DivHelpContentsComponent } from "./pages/divhelpcontent/div-help-contents.component";
|
|
|
|
import { NewDivHelpContentComponent } from "./pages/divhelpcontent/new-div-help-content.component";
|
|
|
|
import { EditDivHelpContentComponent } from "./pages/divhelpcontent/edit-div-help-content.component";
|
2018-01-04 15:32:31 +01:00
|
|
|
|
2018-02-06 12:35:16 +01:00
|
|
|
import {FreeGuard, AdminLoginGuard} from 'ng-openaire-library';
|
|
|
|
|
|
|
|
|
2017-09-22 12:26:08 +02:00
|
|
|
const appRoutes: Routes = [
|
|
|
|
{
|
|
|
|
path: '',
|
|
|
|
redirectTo: 'dashboard',
|
|
|
|
pathMatch: 'full'
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'dashboard',
|
|
|
|
component: DashboardComponent,
|
2018-02-06 12:35:16 +01:00
|
|
|
canActivate: [FreeGuard]
|
2017-09-22 12:26:08 +02:00
|
|
|
},
|
2018-02-06 12:35:16 +01:00
|
|
|
|
2017-12-13 12:15:19 +01:00
|
|
|
{
|
2017-12-20 15:26:30 +01:00
|
|
|
path: 'communities',
|
|
|
|
component: CommunitiesComponent,
|
2018-02-06 12:35:16 +01:00
|
|
|
canActivate: [FreeGuard]
|
2017-12-20 15:26:30 +01:00
|
|
|
},
|
2018-01-04 15:32:31 +01:00
|
|
|
{
|
|
|
|
path: 'community-edit-form',
|
|
|
|
component: CommunityEditFormComponent,
|
2018-02-06 12:35:16 +01:00
|
|
|
canActivate: [FreeGuard]
|
2018-01-04 15:32:31 +01:00
|
|
|
},
|
2017-12-20 15:26:30 +01:00
|
|
|
{
|
|
|
|
path: 'entities',
|
|
|
|
component: EntitiesComponent,
|
2018-02-06 12:35:16 +01:00
|
|
|
canActivate: [FreeGuard]
|
2017-12-13 12:15:19 +01:00
|
|
|
},
|
2018-02-06 12:06:43 +01:00
|
|
|
{
|
|
|
|
path: 'classes',
|
|
|
|
component: DivIdsComponent,
|
|
|
|
},
|
2017-09-22 12:26:08 +02:00
|
|
|
{
|
|
|
|
path: 'pages',
|
|
|
|
component: PagesComponent,
|
2018-02-06 12:35:16 +01:00
|
|
|
canActivate: [FreeGuard]
|
2017-09-22 12:26:08 +02:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'pageContents',
|
|
|
|
component: PageHelpContentsComponent,
|
2018-02-06 12:35:16 +01:00
|
|
|
canActivate: [FreeGuard]
|
2017-09-22 12:26:08 +02:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'pageContents/new',
|
|
|
|
component: NewPageHelpContentComponent,
|
2018-02-06 12:35:16 +01:00
|
|
|
canActivate: [FreeGuard]
|
2017-09-22 12:26:08 +02:00
|
|
|
},
|
|
|
|
{
|
2017-12-13 12:15:19 +01:00
|
|
|
//path: 'pageContents/edit/:id',
|
|
|
|
path: 'pageContents/edit',
|
2017-09-22 12:26:08 +02:00
|
|
|
component: EditPageHelpContentComponent,
|
2018-02-06 12:35:16 +01:00
|
|
|
canActivate: [FreeGuard]
|
2018-02-06 12:06:43 +01:00
|
|
|
},
|
2018-02-06 12:35:16 +01:00
|
|
|
|
2018-02-06 12:06:43 +01:00
|
|
|
{
|
|
|
|
path: 'classContents',
|
|
|
|
component: DivHelpContentsComponent,
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'classContents/new',
|
|
|
|
component: NewDivHelpContentComponent,
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'classContents/edit',
|
|
|
|
component: EditDivHelpContentComponent,
|
2018-02-06 12:35:16 +01:00
|
|
|
},
|
|
|
|
{ path: '**',pathMatch: 'full',component: DashboardComponent }
|
|
|
|
|
|
|
|
];
|
2017-09-22 12:26:08 +02:00
|
|
|
|
|
|
|
export const appRoutingProviders: any[] = [
|
|
|
|
];
|
|
|
|
|
2017-12-13 12:15:19 +01:00
|
|
|
export const routing: ModuleWithProviders = RouterModule.forRoot(appRoutes);
|