import { createRouter, createWebHashHistory } from "vue-router";

const router = createRouter({
  history: createWebHashHistory(),
  routes: [
    {
      path: "/",
      redirect: "/home",
    },
    {
      path: "/home",
      name: "home",
      title: "首页",
      component: () => import("~/pages/_home/index.vue"),
    },
    {
      path: "/zcdl",
      name: "zcdl",
      component: () => import("~/pages/_home/zcdl.vue"),
    },
    {
      path:'/xszc',
      name:'xszc',
      component: () => import("~/pages/_home/xszc.vue"),
    },
    {
      path:'/my_children',
      name:'my_children',
      component: () => import("~/pages/myChildren/index.vue"),
    },
    {
      path:'/recruit',
      name:'recruit',
      component: () => import("~/pages/recruit/index.vue"),
    },
    {
      path: "/chat",
      title: "消息",
      meta: { loginRequest: "true" },
      children: [
        {
          path: "",
          name: "chat",
          component: () => import("~/pages/_chat/index.vue"),
        },
        {
          name: "chat_detail",
          path: "/chat/:id",
          component: () => import("~/pages/_chat/detail/index.vue"),
        },
      ],
    },
    {
      path: "/user",
      name: "user",
      meta: { loginRequest: "true" },
      component: () => import("~/pages/_user/index.vue"),
    },
    {
      path: "/user/bzrgz",
      name: "bzrgz",
      meta: { loginRequest: "true" },
      component: () => import("~/pages/_user/bzrgz.vue"),
    },
    {
      path: "/user/stkzqk",
      name: "stkzqk",
      meta: { loginRequest: "true" },
      component: () => import("~/pages/_user/stkzqk.vue"),
    },
    {
      path: "/stxk",
      children: [
        {
          path: "jz",
          children: [
            {
              path: "",
              meta: { loginRequest: "true" },
              component: () => import("~/pages/stxk/jz/index.vue"),
            },
            {
              path: "kcxq/:id",
              component: () => import("~/pages/stxk/jz/kcxq.vue"),
              props: true,
            },
            {
              path: "wd",
              children: [
                {
                  path: "",
                  component: () => import("~/pages/stxk/jz/wd/index.vue"),
                },
                {
                  path: "kcxq/:id",
                  component: () => import("~/pages/stxk/jz/wd/kcxq.vue"),
                  props: true,
                },
                {
                  path: "kcapxq/:id",
                  component: () => import("~/pages/stxk/jz/wd/kcapxq.vue"),
                  props: true,
                },
              ],
            },
          ],
        },
      ],
    },
    {
      path: "/qzzx",

      children: [
        {
          path: "",
          name: "qzzx",
          component: () => import("~/pages/qzzx/index.vue"),
        },
        {
          // name: 'chat_detail',
          path: "qzzxxq/:id",
          component: () => import("~/pages/qzzx/xwxq.vue"),
          props: true,
        },
      ],
    },
    {
      path: "/djzl",

      children: [
        {
          path: "",
          name: "djzl",
          component: () => import("~/pages/djzl/index.vue"),
        },
        {
          // name: 'chat_detail',
          path: "djzlxq/:id",
          component: () => import("~/pages/djzl/xwxq.vue"),
          props: true,
        },
      ],
    },
    // {
    //   path: "/qzzx/qzzxxq/:id",
    //   name: "qzzx_qzzxxq",
    //   component: () => import("~/pages/qzzx/qzzxxq/index.vue"),
    // },
    {
      path: "/stxk_teacher",
      name: 'stxk_teacher',
      meta: { loginRequest: "true" },
      component: () => import("~/pages/stxkjs/index.vue"),
    },
    {
      path: "/stxk_teacher_class/:kkbk_id",
      name: "stxk_teacher_class",
      component: () => import("~/pages/stxkjs/stxk_js_classdetail/index.vue"),
    },
    {
      path: "/jscz",
      meta: { loginRequest: "true" },
      component: () => import("~/pages/jscz/index.vue"),
    },
    {
      path: "/jsyx/:yjkc_id",
      name: "jsyx",
      component: () => import("~/pages/jscz/jsyx/index.vue"),
    },
    {
      path: "/stxkbzr",
      meta: { loginRequest: "true" },
      component: () => import("~/pages/stxkbzr/index.vue"),
    },
    {
      path: "/stxkjsd",
      name: "stxkjsd",
      meta: { loginRequest: "true" },
      component: () => import("~/pages/stxkjsd/index.vue"),
    },
    {
      path: "/stxkjsd/ckxq/:id",
      name: "stxkjsd_ckxq",
      component: () => import("~/pages/stxkjsd/ckxq/index.vue"),
    },
    {
      path: "/yshd/wjdc",
      component: () => import("~/pages/yshd/wjdc/index.vue"),
    },
    {
      path: "/xzxx",
      component: () => import("~/pages/xzxx/index.vue"),
    },
    {
      path: "/yshd/tpsj",
      component: () => import("~/pages/yshd/tpsj/index.vue"),
    },
  ],
});

export default router

