2018-07-23 16:42:17 +02:00
|
|
|
import { NgModule } from '@angular/core';
|
|
|
|
import { Routes, RouterModule } from '@angular/router';
|
2018-09-18 18:27:14 +02:00
|
|
|
import { UserListComponent } from './components/user-list/user-list.component';
|
|
|
|
import { UserDetailComponent } from './components/user-detail/user-detail.component';
|
2018-07-23 16:42:17 +02:00
|
|
|
|
2018-09-18 18:27:14 +02:00
|
|
|
const routes: Routes = [
|
|
|
|
{
|
|
|
|
path: '',
|
|
|
|
component: UserListComponent
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'new',
|
|
|
|
component: UserDetailComponent
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: ':id',
|
|
|
|
component: UserDetailComponent
|
|
|
|
}
|
|
|
|
];
|
2018-07-23 16:42:17 +02:00
|
|
|
|
|
|
|
@NgModule({
|
|
|
|
imports: [RouterModule.forChild(routes)],
|
|
|
|
exports: [RouterModule]
|
|
|
|
})
|
|
|
|
export class UsersRoutingModule {}
|