qdt-admin-layout 1.1.21 → 1.1.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "qdt-admin-layout",
3
- "version": "1.1.21",
3
+ "version": "1.1.22",
4
4
  "description": "基于element-ui的后台管理layout的管家婆改版",
5
5
  "main": "src/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -76,7 +76,7 @@ export const mutations = {
76
76
 
77
77
  const key = getRouterKey(view)
78
78
 
79
- if (store.visitedViews.some(v => v.key === key)) {
79
+ if (store.visitedViews.some(v => v.key === key || v.key === view.meta.mainRoute)) {
80
80
  return
81
81
  }
82
82
 
@@ -93,7 +93,7 @@ export const mutations = {
93
93
  const { noCache } = view.meta
94
94
  const key = getRouterKey(view)
95
95
 
96
- if (noCache === true || store.cachedViews.includes(key)) {
96
+ if (noCache === true || store.cachedViews.includes(key) || store.cachedViews.includes(view.meta.mainRoute)) {
97
97
  return
98
98
  }
99
99
  store.cachedViews.push(key)