remove permission param of router.config.js

pull/9/head
ruibaby 2019-03-20 22:36:09 +08:00
parent 2f24ff9610
commit 7d7f75c972
1 changed files with 20 additions and 20 deletions

View File

@ -25,31 +25,31 @@ export const asyncRouterMap = [
name: 'posts',
redirect: '/posts/list',
component: RouteView,
meta: { title: '文章', icon: 'form', permission: [ 'form' ] },
meta: { title: '文章', icon: 'form' },
children: [
{
path: '/posts/list',
name: 'PostList',
component: () => import('@/views/post/PostList'),
meta: { title: '所有文章', hiddenHeaderContent: true, permission: [ 'form' ] }
meta: { title: '所有文章', hiddenHeaderContent: true }
},
{
path: '/posts/write',
name: 'PostEdit',
component: () => import('@/views/post/PostEdit'),
meta: { title: '写文章', hiddenHeaderContent: true, permission: [ 'form' ] }
meta: { title: '写文章', hiddenHeaderContent: true }
},
{
path: '/categories',
name: 'CategoryList',
component: () => import('@/views/post/CategoryList'),
meta: { title: '分类目录', hiddenHeaderContent: true, permission: [ 'form' ] }
meta: { title: '分类目录', hiddenHeaderContent: true }
},
{
path: '/tags',
name: 'TagList',
component: () => import('@/views/post/TagList'),
meta: { title: '标签', hiddenHeaderContent: true, permission: [ 'form' ] }
meta: { title: '标签', hiddenHeaderContent: true }
}
]
},
@ -60,19 +60,19 @@ export const asyncRouterMap = [
name: 'pages',
component: RouteView,
redirect: '/pages/list',
meta: { title: '页面', icon: 'read', permission: [ 'table' ] },
meta: { title: '页面', icon: 'read' },
children: [
{
path: '/pages/list',
name: 'PageList',
component: () => import('@/views/page/PageList'),
meta: { title: '所有页面', hiddenHeaderContent: true, permission: [ 'table' ] }
meta: { title: '所有页面', hiddenHeaderContent: true }
},
{
path: '/pages/write',
name: 'PageEdit',
component: () => import('@/views/page/PageEdit'),
meta: { title: '新建页面', hiddenHeaderContent: true, permission: [ 'table' ] }
meta: { title: '新建页面', hiddenHeaderContent: true }
}
]
},
@ -82,7 +82,7 @@ export const asyncRouterMap = [
path: '/attachments',
name: 'attachments',
component: () => import('@/views/attachment/AttachmentList'),
meta: { title: '附件', icon: 'picture', hiddenHeaderContent: true, permission: [ 'profile' ] }
meta: { title: '附件', icon: 'picture', hiddenHeaderContent: true }
},
// comments
@ -90,7 +90,7 @@ export const asyncRouterMap = [
path: '/comments',
name: 'comments',
component: () => import('@/views/comment/CommentList'),
meta: { title: '评论', icon: 'message', hiddenHeaderContent: true, permission: [ 'profile' ] }
meta: { title: '评论', icon: 'message', hiddenHeaderContent: true }
},
// interface
@ -99,25 +99,25 @@ export const asyncRouterMap = [
name: 'interface',
component: RouteView,
redirect: '/interface/themes',
meta: { title: '外观', icon: 'skin', permission: [ 'result' ] },
meta: { title: '外观', icon: 'skin' },
children: [
{
path: '/interface/themes',
name: 'ThemeList',
component: () => import('@/views/interface/ThemeList'),
meta: { title: '主题', hiddenHeaderContent: true, permission: [ 'result' ] }
meta: { title: '主题', hiddenHeaderContent: true }
},
{
path: '/interface/menus',
name: 'MenuList',
component: () => import('@/views/interface/MenuList'),
meta: { title: '菜单', hiddenHeaderContent: true, permission: [ 'result' ] }
meta: { title: '菜单', hiddenHeaderContent: true }
},
{
path: '/interface/themes/edit',
name: 'ThemeEdit',
component: () => import('@/views/interface/ThemeEdit'),
meta: { title: '主题编辑', hiddenHeaderContent: true, permission: [ 'result' ] }
meta: { title: '主题编辑', hiddenHeaderContent: true }
}
]
},
@ -128,13 +128,13 @@ export const asyncRouterMap = [
name: 'user',
component: RouteView,
redirect: '/user/profile',
meta: { title: '用户', icon: 'user', permission: [ 'exception' ] },
meta: { title: '用户', icon: 'user' },
children: [
{
path: '/user/profile',
name: 'Profile',
component: () => import('@/views/user/Profile'),
meta: { title: '个人资料', hiddenHeaderContent: true, permission: [ 'exception' ] }
meta: { title: '个人资料', hiddenHeaderContent: true }
}
]
},
@ -145,25 +145,25 @@ export const asyncRouterMap = [
name: 'options',
component: RouteView,
redirect: '/system/options',
meta: { title: '系统', icon: 'setting', permission: [ 'user' ] },
meta: { title: '系统', icon: 'setting' },
children: [
{
path: '/system/options',
name: 'OptionForm',
component: () => import('@/views/system/OptionForm'),
meta: { title: '博客设置', hiddenHeaderContent: true, permission: [ 'user' ] }
meta: { title: '博客设置', hiddenHeaderContent: true }
},
{
path: '/system/backup',
name: 'BackupList',
component: () => import('@/views/system/BackupList'),
meta: { title: '博客备份', hiddenHeaderContent: true, permission: [ 'user' ] }
meta: { title: '博客备份', hiddenHeaderContent: true }
},
{
path: '/system/tools',
name: 'ToolList',
component: () => import('@/views/system/ToolList'),
meta: { title: '小工具', hiddenHeaderContent: true, permission: [ 'user' ] }
meta: { title: '小工具', hiddenHeaderContent: true }
}
]
}