From 46145ff636b531da01eeeb2c4434e885b685f8ec Mon Sep 17 00:00:00 2001 From: sindir Date: Tue, 20 Jan 2026 16:19:54 +0800 Subject: [PATCH] =?UTF-8?q?=E6=AD=A3=E7=A1=AE=E8=BD=AC=E5=88=B0=E5=AD=97?= =?UTF-8?q?=E5=85=B8=E7=B1=BB=E5=9E=8B=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- openhis-ui-vue3/src/router/index.js | 26 +++ .../src/views/system/dict/index.vue | 160 ++++-------------- 2 files changed, 58 insertions(+), 128 deletions(-) diff --git a/openhis-ui-vue3/src/router/index.js b/openhis-ui-vue3/src/router/index.js index dada00a9..6092f6d2 100644 --- a/openhis-ui-vue3/src/router/index.js +++ b/openhis-ui-vue3/src/router/index.js @@ -96,6 +96,32 @@ export const dynamicRoutes = [ }, ], }, + // 字典类型路由(直接复制这段) + { + path: '/system/dict', + component: Layout, + alwaysShow: true, + name: 'DictType', + meta: { + title: '字典类型管理', + icon: 'list' // 图标随便选一个,比如list、dict,不影响跳转 + }, + children: [ + { + path: '', + component: () => import('@/views/system/dict/index.vue'), + name: 'DictTypeList', + meta: {title: '字典类型', noCache: false} + }, + { + path: 'data/:dictId?', // 带字典ID参数,?表示可选 + component: () => import('@/views/system/dict/data.vue'), // 你的data.vue路径 + name: 'DictData', + hidden: true, // 不在侧边栏显示(子页面) + meta: {title: '字典数据', activeMenu: '/system/dict'} // 保持侧边栏高亮 + } + ] + }, ]; // 合并常量路由和动态路由,确保所有路由都能被访问 diff --git a/openhis-ui-vue3/src/views/system/dict/index.vue b/openhis-ui-vue3/src/views/system/dict/index.vue index c02555f8..a6db2ff1 100644 --- a/openhis-ui-vue3/src/views/system/dict/index.vue +++ b/openhis-ui-vue3/src/views/system/dict/index.vue @@ -1,55 +1,23 @@ - +
- +
@@ -194,7 +98,7 @@ {{ dict.label - }} + }} @@ -213,7 +117,7 @@