局长信箱-互联网端管理-前端
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

49 lines
1.1 KiB

import { createRouter, createWebHashHistory } from 'vue-router'
import Home from '@/views/Home.vue'
import Layout from '@/layout/Index.vue'
import NotFound from '@/views/error/404.vue'
const constantRoutes = [
{
path: '/layout',
component: Layout,
redirect: to => {
return '/'
},
children: [
{
path: '/',
component: Home
},
{
path: '/mailbox',
component: () => import('@/components/ManageMail.vue'),
},
{
path: '/mailbox/detail/:id',
component: () => import('@/components/MailDetail.vue')
},
{
path: '/holiday',
component: () => import('@/components/HolidayList.vue')
}
]
},
{
path: '/:catchAll(.*)',
component: NotFound,
meta: {
title: '404'
}
}
];
const router = createRouter({
history: createWebHashHistory(),
routes: constantRoutes
});
export default router;