AdaKing88
2023-08-23 9cad48db6c56c3e2796a9d6da881817ef13b6eca
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
import {
  createRouter,
  createWebHashHistory,
  createWebHistory,
} from "vue-router";
export const routes = [
  // 根路由
  {
    path: "/",
    redirect: "Login",
    hidden: true,
  },
  // 登录
  {
    path: "/login",
    name: "Login",
    hidden: true,
 
    component: () => import("../views/account/Login.vue"),
  },
  // 路由中转
  {
    path: "/history",
    name: "history",
    meta: {
      title: "数据管理",
    },
    component: () => import("../layout/Index.vue"),
    children: [
      {
        path: "/history",
        name: "history",
        meta: {
          title: "数据管理",
        },
        component: () => import("../views/history/Index.vue"),
      },
    ],
  },
];
 
const router = createRouter({
  history: createWebHashHistory(),
  routes,
});
 
export default router;