feat: add Multi-level menu

This commit is contained in:
xiaoxian521
2021-05-21 12:55:23 +08:00
parent cd872bea83
commit 010ba1a9e1
21 changed files with 501 additions and 326 deletions

View File

@@ -0,0 +1,46 @@
import Layout from "/@/layout/index.vue";
const remainingRouter = [
{
path: "/login",
name: "login",
component: () => import("/@/views/login.vue"),
meta: {
title: "message.hslogin",
showLink: false,
},
},
{
path: "/register",
name: "register",
component: () => import("/@/views/register.vue"),
meta: {
title: "message.hsregister",
showLink: false,
},
},
{
// 找不到路由重定向到404页面
path: "/:pathMatch(.*)",
component: Layout,
redirect: "/error/404",
meta: {
icon: "el-icon-s-home",
title: "message.hshome",
showLink: false,
savedPosition: false,
},
},
{
path: "/redirect",
component: Layout,
children: [
{
path: "/redirect/:path(.*)",
component: () => import("/@/views/redirect.vue"),
},
],
},
];
export default remainingRouter;