登录叶细胞
This commit is contained in:
@@ -34,6 +34,14 @@ export const adminBaseRoute = {
|
||||
*/
|
||||
const staticRoutes: Array<RouteRecordRaw> = [
|
||||
adminBaseRoute,
|
||||
{
|
||||
path: '/',
|
||||
redirect: (to) => {
|
||||
return {
|
||||
name: 'adminMainLoading'
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
// 管理员登录页 - 不放在 adminBaseRoute.children 因为登录页不需要使用后台的布局
|
||||
path: '/login',
|
||||
@@ -43,7 +51,6 @@ const staticRoutes: Array<RouteRecordRaw> = [
|
||||
title: pageTitle('login')
|
||||
}
|
||||
},
|
||||
|
||||
{
|
||||
path: '/:path(.*)*',
|
||||
redirect: '/404'
|
||||
@@ -56,6 +63,21 @@ const staticRoutes: Array<RouteRecordRaw> = [
|
||||
meta: {
|
||||
title: pageTitle('notFound') // 页面不存在
|
||||
}
|
||||
},
|
||||
{
|
||||
// 后台找不到页面了-可能是路由未加载上
|
||||
path: adminBaseRoutePath + ':path(.*)*',
|
||||
redirect: (to) => {
|
||||
return {
|
||||
name: 'adminMainLoading',
|
||||
params: {
|
||||
to: JSON.stringify({
|
||||
path: to.path,
|
||||
query: to.query
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user