@@ -56,6 +56,9 @@
const module = computed(() => {
return store.module
})
+ const isMobile = computed(() => {
+ return store.isMobile
+ })
// 监听目录是否折叠
watch(moduleUnfoldOpen, (newValue) => {
nextTick(() => {
diff --git a/snowy-admin-web/src/layout/components/tags.vue b/snowy-admin-web/src/layout/components/tags.vue
index 3ef7333e..9c9790f5 100644
--- a/snowy-admin-web/src/layout/components/tags.vue
+++ b/snowy-admin-web/src/layout/components/tags.vue
@@ -190,7 +190,7 @@
},
// 高亮tag
isActive(route) {
- return route.fullPath === this.$route.fullPath
+ return route.path === this.$route.path
},
// 关闭tag
closeSelectedTag(tag, autoPushLatestView = true) {
diff --git a/snowy-admin-web/src/layout/index.vue b/snowy-admin-web/src/layout/index.vue
index b2554faa..4e2d690b 100644
--- a/snowy-admin-web/src/layout/index.vue
+++ b/snowy-admin-web/src/layout/index.vue
@@ -272,7 +272,7 @@
// 展开的
nextTick(() => {
// 取得默认路由地址并设置展开
- const active = route.meta.active || route.fullPath
+ const active = route.meta.active || route.path
selectedKeys.value = new Array(active)
const pidKey = getParentKeys(pMenu.value.children, active)
const nextTickMenu = pMenu.value.children
@@ -316,6 +316,8 @@
showThis()
onMounted(() => {
+ onLayoutResize()
+ window.addEventListener('resize', onLayoutResize)
switchoverTopHeaderThemeColor()
})
watch(route, (newValue) => {
diff --git a/snowy-admin-web/src/store/viewTags.js b/snowy-admin-web/src/store/viewTags.js
index 2fcf58be..de86937c 100644
--- a/snowy-admin-web/src/store/viewTags.js
+++ b/snowy-admin-web/src/store/viewTags.js
@@ -18,11 +18,18 @@ export const viewTagsStore = defineStore({
getters: {},
actions: {
pushViewTags(route) {
- const target = this.viewTags.find((item) => item.fullPath === route.fullPath)
+ const target = this.viewTags.find((item) => item.path === route.path)
const isName = route.name
if (!target && isName) {
this.viewTags.push(route)
}
+ if (target) {
+ this.viewTags.forEach((item) => {
+ if (item.path === route.path) {
+ Object.assign(item, route)
+ }
+ })
+ }
},
removeViewTags(route) {
this.viewTags.forEach((item, index) => {
diff --git a/snowy-admin-web/src/views/exm/nestRoutor/index.vue b/snowy-admin-web/src/views/exm/nestRoutor/index.vue
index 2a13b5f0..61da89e7 100644
--- a/snowy-admin-web/src/views/exm/nestRoutor/index.vue
+++ b/snowy-admin-web/src/views/exm/nestRoutor/index.vue
@@ -7,7 +7,6 @@
diff --git a/snowy-admin-web/src/views/sys/user/index.vue b/snowy-admin-web/src/views/sys/user/index.vue
index 3a25044c..36d862f2 100644
--- a/snowy-admin-web/src/views/sys/user/index.vue
+++ b/snowy-admin-web/src/views/sys/user/index.vue
@@ -1,7 +1,7 @@
-
-
+
+
-
+
diff --git a/snowy-admin-web/src/views/sys/user/userCenter.vue b/snowy-admin-web/src/views/sys/user/userCenter.vue
index 5e0db9d8..c859a371 100644
--- a/snowy-admin-web/src/views/sys/user/userCenter.vue
+++ b/snowy-admin-web/src/views/sys/user/userCenter.vue
@@ -1,6 +1,6 @@
-
-
+
+