From b2e33ca05f0c8d715bac12986091f2af370166e3 Mon Sep 17 00:00:00 2001 From: hooray <304327508@qq.com> Date: Sat, 19 Nov 2022 01:35:07 +0800 Subject: [PATCH] =?UTF-8?q?refactor!:=20=E6=8E=A7=E5=88=B6=E5=8F=B0?= =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=B8=BA=E4=B8=BB=E9=A1=B5=EF=BC=8C=E8=B7=AF?= =?UTF-8?q?=E7=94=B1=E8=B0=83=E6=95=B4=E4=B8=BA=E6=A0=B9=E8=B7=AF=E7=94=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 从原有 /dashboard 路由调整为 / 根路由 --- src/global.d.ts | 12 ++--- src/layouts/components/AppSetting/index.vue | 10 ++-- src/layouts/components/Logo/index.vue | 6 +-- src/layouts/components/Tools/index.vue | 10 ++-- src/layouts/components/Topbar/index.vue | 6 +-- src/router/index.ts | 12 ++--- src/router/routes.ts | 54 +++++---------------- src/settings.default.ts | 4 +- src/views/index.vue | 4 +- 9 files changed, 45 insertions(+), 73 deletions(-) diff --git a/src/global.d.ts b/src/global.d.ts index e99fad98..ab0b37b5 100644 --- a/src/global.d.ts +++ b/src/global.d.ts @@ -52,15 +52,15 @@ declare namespace Settings { */ routeBaseOn?: 'frontend' | 'backend' | 'filesystem' } - interface dashboard { + interface home { /** - * 是否开启控制台页面 + * 是否开启主页页面 * @默认值 `true` */ enable?: boolean /** - * 控制台名称 - * @默认值 `'控制台'` + * 主页名称 + * @默认值 `'主页'` */ title?: string } @@ -189,8 +189,8 @@ declare namespace Settings { interface all { /** 应用设置 */ app?: app - /** 控制台设置 */ - dashboard?: dashboard + /** 主页设置 */ + home?: home /** 布局设置 */ layout?: layout /** 导航栏设置 */ diff --git a/src/layouts/components/AppSetting/index.vue b/src/layouts/components/AppSetting/index.vue index 7e5ba0e9..33bd8553 100644 --- a/src/layouts/components/AppSetting/index.vue +++ b/src/layouts/components/AppSetting/index.vue @@ -226,23 +226,23 @@ function handleCopy() { - 控制台 + 主页
是否开启 - +
- +
- 控制台名称 + 主页名称
- +
其它
diff --git a/src/layouts/components/Logo/index.vue b/src/layouts/components/Logo/index.vue index bdcd2283..4089f685 100644 --- a/src/layouts/components/Logo/index.vue +++ b/src/layouts/components/Logo/index.vue @@ -22,15 +22,15 @@ const to = computed(() => { const rtn: { name?: string } = {} - if (settingsStore.dashboard.enable) { - rtn.name = 'dashboard' + if (settingsStore.home.enable) { + rtn.name = 'home' } return rtn })