From 943be5651163f9840f362f5f3ff88333c435dc6b Mon Sep 17 00:00:00 2001 From: RuoYi Date: Sun, 22 Mar 2026 21:17:08 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=8C=81=E4=B9=85=E5=8C=96?= =?UTF-8?q?=E6=A0=87=E7=AD=BE=E9=A1=B5=E5=BC=80=E5=85=B3=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/layout/components/Settings/index.vue | 20 ++ .../layout/components/TagsView/ScrollPane.vue | 79 +++++- .../src/layout/components/TagsView/index.vue | 233 +++++++++++++++--- ruoyi-ui/src/settings.js | 7 +- ruoyi-ui/src/store/modules/settings.js | 3 +- ruoyi-ui/src/store/modules/tagsView.js | 47 ++++ 6 files changed, 342 insertions(+), 47 deletions(-) diff --git a/ruoyi-ui/src/layout/components/Settings/index.vue b/ruoyi-ui/src/layout/components/Settings/index.vue index 1b21cb519..ff83c46ae 100644 --- a/ruoyi-ui/src/layout/components/Settings/index.vue +++ b/ruoyi-ui/src/layout/components/Settings/index.vue @@ -65,6 +65,11 @@ +
+ 持久化标签页 + +
+
显示页签图标 @@ -125,6 +130,20 @@ export default { }) } }, + tagsViewPersist: { + get() { + return this.$store.state.settings.tagsViewPersist + }, + set(val) { + this.$store.dispatch('settings/changeSetting', { + key: 'tagsViewPersist', + value: val + }) + if (!val) { + this.$cache.local.remove('tags-view-visited') + } + } + }, tagsView: { get() { return this.$store.state.settings.tagsView @@ -237,6 +256,7 @@ export default { "navType":${this.navType}, "tagsView":${this.tagsView}, "tagsIcon":${this.tagsIcon}, + "tagsViewPersist":${this.tagsViewPersist}, "fixedHeader":${this.fixedHeader}, "sidebarLogo":${this.sidebarLogo}, "dynamicTitle":${this.dynamicTitle}, diff --git a/ruoyi-ui/src/layout/components/TagsView/ScrollPane.vue b/ruoyi-ui/src/layout/components/TagsView/ScrollPane.vue index c110bf123..3dbd9aed0 100644 --- a/ruoyi-ui/src/layout/components/TagsView/ScrollPane.vue +++ b/ruoyi-ui/src/layout/components/TagsView/ScrollPane.vue @@ -5,7 +5,7 @@