优化菜单在不同权限配置下的显示
This commit is contained in:
parent
56fe4bcae4
commit
04dc3848a7
@ -81,6 +81,7 @@ export default class extends Vue {
|
|||||||
@Prop({ default: '' }) private basePath!: string
|
@Prop({ default: '' }) private basePath!: string
|
||||||
|
|
||||||
get alwaysShowRootMenu() {
|
get alwaysShowRootMenu() {
|
||||||
|
console.log('alwaysShowRootMenu', this.item)
|
||||||
if (this.item.meta && this.item.meta.alwaysShow) {
|
if (this.item.meta && this.item.meta.alwaysShow) {
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,8 @@ const gameRoutes: RouteConfig = {
|
|||||||
meta: {
|
meta: {
|
||||||
title: 'game',
|
title: 'game',
|
||||||
icon: 'game',
|
icon: 'game',
|
||||||
alwaysShow: true
|
alwaysShow: true,
|
||||||
|
permissions: ['sysgame:*']
|
||||||
},
|
},
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
|
@ -7,7 +7,8 @@ const marketingRoutes: RouteConfig = {
|
|||||||
meta: {
|
meta: {
|
||||||
title: 'marketing',
|
title: 'marketing',
|
||||||
icon: 'sell',
|
icon: 'sell',
|
||||||
alwaysShow: true
|
alwaysShow: true,
|
||||||
|
permissions: ['coupon:*']
|
||||||
},
|
},
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
|
@ -7,6 +7,7 @@ const questionRoutes: RouteConfig = {
|
|||||||
meta: {
|
meta: {
|
||||||
title: 'question',
|
title: 'question',
|
||||||
icon: 'question_list',
|
icon: 'question_list',
|
||||||
|
permissions: ['question:*', 'shop:tiku_setting'],
|
||||||
alwaysShow: true
|
alwaysShow: true
|
||||||
},
|
},
|
||||||
children: [
|
children: [
|
||||||
|
@ -7,7 +7,8 @@ const shopRoutes: RouteConfig = {
|
|||||||
meta: {
|
meta: {
|
||||||
title: 'shop',
|
title: 'shop',
|
||||||
icon: 'shop',
|
icon: 'shop',
|
||||||
alwaysShow: true
|
alwaysShow: true,
|
||||||
|
permissions: ['shopadmin:*', 'shop:game_setting', 'activity:*']
|
||||||
},
|
},
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
|
@ -8,6 +8,7 @@ const systemRoutes: RouteConfig = {
|
|||||||
meta: {
|
meta: {
|
||||||
title: 'system',
|
title: 'system',
|
||||||
icon: 'component',
|
icon: 'component',
|
||||||
|
permissions: ['shopman:*', 'permission:*', 'admin:*', 'role:*'],
|
||||||
alwaysShow: true
|
alwaysShow: true
|
||||||
},
|
},
|
||||||
children: [
|
children: [
|
||||||
|
Loading…
x
Reference in New Issue
Block a user