From a9f5e08889ddd124d03057d06b506c08c8f692a8 Mon Sep 17 00:00:00 2001 From: chengqian Date: Mon, 3 Aug 2026 17:00:49 +0800 Subject: [PATCH] =?UTF-8?q?feat(playground):=E5=9C=A8=E7=BA=BF=E4=BD=93?= =?UTF-8?q?=E9=AA=8C=E5=8A=9F=E8=83=BD=E6=96=B0=E5=A2=9E=E5=9B=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- web/tenant/src/router/tenant.ts | 3 ++- web/tenant/src/views/Layout.vue | 11 +++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/web/tenant/src/router/tenant.ts b/web/tenant/src/router/tenant.ts index 32ee79e..b4ac0f5 100644 --- a/web/tenant/src/router/tenant.ts +++ b/web/tenant/src/router/tenant.ts @@ -11,6 +11,7 @@ declare module 'vue-router' { viewportTable?: boolean description?: string keywords?: string + badge?: string // 菜单项右侧徽章文本 } } @@ -171,7 +172,7 @@ const tenantRoutes: RouteRecordRaw[] = [ path: 'playground', name: 'TenantPlayground', component: () => import('@/views/service/PlaygroundPage.vue'), - meta: { title: '在线体验', icon: 'terminal', sort: 50, roles: ['owner', 'admin', 'member'] }, + meta: { title: '在线体验', icon: 'terminal', sort: 50, roles: ['owner', 'admin', 'member'], badge: '⚡' }, }, { path: 'tickets', diff --git a/web/tenant/src/views/Layout.vue b/web/tenant/src/views/Layout.vue index 21e3ccb..5fb5e0d 100644 --- a/web/tenant/src/views/Layout.vue +++ b/web/tenant/src/views/Layout.vue @@ -55,6 +55,7 @@ interface NavItem { label: string path: string icon: string + badge?: string } const navItems = computed(() => { @@ -71,6 +72,7 @@ const navItems = computed(() => { label: r.meta.title as string, path: r.path, icon: r.meta.icon as string, + badge: r.meta.badge as string | undefined, })) }) @@ -281,6 +283,15 @@ onBeforeUnmount(() => { {{ item.label }} + + + {{ item.badge }} + +