modules.routes.ts 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. import { NgModule } from '@angular/core';
  2. import { RouterModule, Routes } from '@angular/router';
  3. import { PageTextbookComponent } from './components/page-textbook/page-textbook.component';
  4. import { ApplyComponent } from './apply/apply.component';
  5. // import { ProfileComponent } from '../user/profile/profile.component';
  6. import { SpaceComponent } from './space/space.component'
  7. import { TextbookDetailsComponent } from './textbook-details/textbook-details.component'
  8. import { RecycleComponent } from './recycle/recycle.component'
  9. const routes: Routes = [
  10. {
  11. path: '',
  12. redirectTo:'manage/space',
  13. pathMatch: "full",
  14. },
  15. {
  16. path: 'manage',
  17. children: [
  18. {
  19. path: 'space',//创建教材
  20. component: SpaceComponent,
  21. },
  22. {
  23. path: 'apply',//创建教材
  24. component: ApplyComponent,
  25. },
  26. {
  27. path: 'dateils',//创建教材
  28. component: TextbookDetailsComponent,
  29. },
  30. // {
  31. // path: 'textbook',//列表
  32. // component: PageTextbookComponent,
  33. // },
  34. {
  35. path: 'recycle',//回收站
  36. component: RecycleComponent,
  37. },
  38. ],
  39. },
  40. ];
  41. @NgModule({
  42. imports: [RouterModule.forChild(routes)],
  43. exports: [RouterModule],
  44. })
  45. export class NavAuthorRoutingModule {}