去掉固定
This commit is contained in:
@@ -88,7 +88,7 @@ const remainingRouter: AppRouteRecordRaw[] = [
|
||||
icon: 'ep:home-filled',
|
||||
noCache: false,
|
||||
hidden: true,
|
||||
affix: true
|
||||
affix: false
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -100,7 +100,7 @@ const remainingRouter: AppRouteRecordRaw[] = [
|
||||
icon: 'ep:home-filled',
|
||||
hidden: true,
|
||||
noCache: false,
|
||||
affix: true
|
||||
affix: false
|
||||
}
|
||||
}
|
||||
]
|
||||
|
||||
@@ -26,11 +26,13 @@ export const useTagsViewStore = defineStore('tagsView', {
|
||||
actions: {
|
||||
// 新增缓存和tag
|
||||
addView(view: RouteLocationNormalizedLoaded): void {
|
||||
debugger
|
||||
this.addVisitedView(view)
|
||||
this.addCachedView()
|
||||
},
|
||||
// 新增tag
|
||||
addVisitedView(view: RouteLocationNormalizedLoaded) {
|
||||
debugger
|
||||
if (this.visitedViews.some((v) => v.path === view.path)) return
|
||||
if (view.meta?.noTagsView) return
|
||||
this.visitedViews.push(
|
||||
@@ -41,6 +43,7 @@ export const useTagsViewStore = defineStore('tagsView', {
|
||||
},
|
||||
// 新增缓存
|
||||
addCachedView() {
|
||||
debugger
|
||||
const cacheMap: Set<string> = new Set()
|
||||
for (const v of this.visitedViews) {
|
||||
const item = getRawRoute(v)
|
||||
|
||||
Reference in New Issue
Block a user