orders-routing.module.ts 647 B

1234567891011121314151617181920212223
  1. import { NgModule } from '@angular/core';
  2. import { RouterModule, Routes } from '@angular/router';
  3. import { OrdersComponent } from './orders.component';
  4. import { OrderListComponent } from './order-list/order-list.component';
  5. import { OrderDetailsComponent } from './order-details/order-details.component';
  6. const routes: Routes = [
  7. {
  8. path: '',
  9. component: OrdersComponent,
  10. children: [
  11. { path: '', component: OrderListComponent },
  12. { path: 'details', component: OrderDetailsComponent },
  13. ],
  14. },
  15. ];
  16. @NgModule({
  17. imports: [RouterModule.forChild(routes)],
  18. exports: [RouterModule],
  19. })
  20. export class OrdersRoutingModule {}