From 8808d415c48b12baacf98442b48d125d62bd2a45 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BB=B2=E4=B9=88=E4=BA=86?= Date: Tue, 23 Jan 2024 14:14:26 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AE=BE=E5=A4=87=E5=9F=BA=E7=A1=80=E7=AE=A1?= =?UTF-8?q?=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/layouts/admin/index.vue | 80 +---- src/views/govern/manage/basic/dictionary.vue | 50 +-- .../govern/manage/basic/popupDictionary.vue | 304 +++++++++--------- .../govern/manage/basic/popupVersion.vue | 113 ++++--- src/views/govern/manage/basic/template.vue | 48 +-- src/views/govern/manage/basic/version.vue | 35 +- 6 files changed, 290 insertions(+), 340 deletions(-) diff --git a/src/layouts/admin/index.vue b/src/layouts/admin/index.vue index 1e52423..4982b30 100644 --- a/src/layouts/admin/index.vue +++ b/src/layouts/admin/index.vue @@ -58,84 +58,6 @@ const init = async () => { * 后台初始化请求,获取站点配置,动态路由等信息 */ getRouteMenu().then((res: any) => { - const arr = [ - { - id: 2, - pid: 0, - type: 'menu_dir', - title: '权限管理', - name: 'auth', - path: 'auth', - icon: 'fa-solid fa-layer-group', - menu_type: null, - url: '', - component: '', - keepalive: 0, - extend: 'none', - children: [ - { - id: 3, - pid: 2, - type: 'menu', - title: '审核管理', - name: 'auth/audit', - path: 'auth/audit', - icon: 'el-icon-Avatar', - menu_type: 'tab', - url: '', - component: '/src/views/auth/audit/index.vue', - keepalive: 'auth/audit', - extend: 'none', - children: [] - }, - { - id: 3, - pid: 2, - type: 'menu', - title: '用户管理', - name: 'auth/userList', - path: 'auth/userList', - icon: 'el-icon-Avatar', - menu_type: 'tab', - url: '', - component: '/src/views/auth/userList/index.vue', - keepalive: 'auth/userList', - extend: 'none', - children: [] - }, - { - id: 3, - pid: 2, - type: 'menu', - title: '角色管理', - name: 'auth/role', - path: 'auth/role', - icon: 'el-icon-Avatar', - menu_type: 'tab', - url: '', - component: '/src/views/auth/role/index.vue', - keepalive: 'auth/role', - extend: 'none', - children: [] - }, - { - id: 13, - pid: 2, - type: 'menu', - title: '菜单规则管理', - name: 'auth/menu', - path: 'auth/menu', - icon: 'el-icon-Menu', - menu_type: 'tab', - url: '', - component: '/src/views/auth/menu/index.vue', - keepalive: 'auth/menu', - extend: 'none', - children: [] - } - ] - } - ] const handlerMenu = (data: any) => { data.forEach((item: any) => { item.routePath = item.routePath[0] == '/' ? item.routePath.substring(1, item.routePath.length) : item.routePath @@ -151,7 +73,7 @@ const init = async () => { }) } handlerMenu(res.data) - handleAdminRoute([...res.data, ...arr]) + handleAdminRoute(res.data) // 预跳转到上次路径 if (route.params.to) { const lastRoute = JSON.parse(route.params.to as string) diff --git a/src/views/govern/manage/basic/dictionary.vue b/src/views/govern/manage/basic/dictionary.vue index f54e0a0..7bc6a44 100644 --- a/src/views/govern/manage/basic/dictionary.vue +++ b/src/views/govern/manage/basic/dictionary.vue @@ -1,55 +1,58 @@ -