From 41767478ad2502f0113da0621c04b295685627cc Mon Sep 17 00:00:00 2001 From: Shigma Date: Mon, 1 Jan 2024 16:20:16 +0800 Subject: [PATCH] feat(admin): use colon separated permissions --- plugins/admin/client/group.vue | 8 ++++---- plugins/admin/client/name.vue | 4 ++-- plugins/admin/src/index.ts | 17 ++++++++--------- 3 files changed, 14 insertions(+), 15 deletions(-) diff --git a/plugins/admin/client/group.vue b/plugins/admin/client/group.vue index 39e8ce24..fe88b371 100644 --- a/plugins/admin/client/group.vue +++ b/plugins/admin/client/group.vue @@ -65,7 +65,7 @@ @@ -232,11 +232,11 @@ async function removeUser() { } function getLink(name: string) { - if (name.startsWith('group.')) { + if (name.startsWith('group:')) { return `/admin/group/${name.slice(6)}` - } else if (name.startsWith('track.')) { + } else if (name.startsWith('track:')) { return `/admin/track/${name.slice(6)}` - } else if (name.startsWith('command.')) { + } else if (name.startsWith('command:')) { return `/commands/${name.slice(8).replace(/\./g, '/')}` } } diff --git a/plugins/admin/client/name.vue b/plugins/admin/client/name.vue index 52776277..0d0b4315 100644 --- a/plugins/admin/client/name.vue +++ b/plugins/admin/client/name.vue @@ -1,8 +1,8 @@