FarmMapsLib/projects/common-map/src/fm-map/common-map-routing.module.ts

30 lines
747 B
TypeScript
Raw Normal View History

2019-10-28 13:18:25 +00:00
import { NgModule } from '@angular/core';
import { RouterModule } from '@angular/router';
import { MapComponent } from './components/map/map.component';
import { AuthGuard } from '@farmmaps/common';
const routes = [
{
path: '', canActivateChild: [AuthGuard], children: [
{
path: '',
component: MapComponent
}
]
},
{
path: ':xCenter/:yCenter/:zoom/:rotation/:baseLayer/:queryState', canActivateChild: [AuthGuard], children: [
{
path: '',
component: MapComponent
}
]
}
];
@NgModule({
imports: [RouterModule.forChild(routes)],
exports: [RouterModule]
})
export class MapRoutingModule { }