import { NgModule } from "@angular/core";
import { RouterModule, Routes } from "@angular/router";
import { PageUserComponent } from "../nav-admin/page-user/page-user.component";
import { UserEditComponent } from "../nav-admin/user-edit/user-edit.component";
import { PageProcessComponent } from "./page-process/page-process.component";
import { ProcessListComponent } from "./page-process/process-list/process-list.component";
import { PageRoleComponent } from "./page-role/page-role.component";
import { PageTextbookComponent } from "./page-textbook/page-textbook.component";
import { SubmittedComponent } from "./submitted/submitted.component";
// import { PageTextbookComponent } from "./page-textbook/page-textbook.component";
const routes: Routes = [
  {
    path: '',
    redirectTo:'manage/textbook',
    pathMatch: "full",
  },
  {
    path: 'manage',
    children:[
      {
        path: 'process', //流程申报
        component: ProcessListComponent,
      },
      {
        path: 'process/page', //流程详情
        component: PageProcessComponent,
      },
      {
        path: 'textbook', //全部教材
        component: PageTextbookComponent,
      },
      {
        path: 'user', //用户列表
        component: PageUserComponent,
      },
      {
        path: 'user/edit', //用户管理&编辑
        component: UserEditComponent,
      },
      {
        path: 'role', //组织列表
        component: PageRoleComponent,
      },
      {
        path: 'submitted/:id', //组织列表
        component: SubmittedComponent,
      },
    ]
  }
];
@NgModule({
  imports: [RouterModule.forChild(routes)],
  exports: [RouterModule],
})
export class NavProContactRoutingModule {}
