opt-cc/static/src/app/statistic/stats.routing.ts

41 lines
1.2 KiB
TypeScript
Raw Normal View History

2017-09-02 23:27:15 +02:00
import {RouterModule, Routes} from "@angular/router";
import {StatisticComponent} from "./stats.component";
import {WarDetailComponent} from "./war-detail/war-detail.component";
import {WarSubmitComponent} from "./war-submit/war-submit.component";
import {WarListComponent} from "./war-list/war-list.component";
import {StatisticOverviewComponent} from "./overview/stats-overview.component";
import {WarItemComponent} from "./war-list/war-item.component";
2017-09-02 23:27:15 +02:00
import {ModuleWithProviders} from "@angular/core";
export const statsRoutes: Routes = [{
path: '', component: StatisticComponent,
children: [
{
path: '',
component: WarListComponent
}
]
},
{
2017-08-12 21:37:31 +02:00
path: 'overview/:id',
component: StatisticOverviewComponent,
outlet: 'right'
},
{
path: 'new',
component: WarSubmitComponent,
outlet: 'right'
},
{
path: 'war/:id',
component: WarDetailComponent,
outlet: 'right'
}];
2017-09-02 23:27:15 +02:00
export const statsRouterModule: ModuleWithProviders = RouterModule.forChild(statsRoutes);
export const statsRoutingComponents = [StatisticComponent, StatisticOverviewComponent, WarListComponent,
WarSubmitComponent, WarDetailComponent, WarItemComponent];