mirror of
https://github.com/m-xlsea/ruoyi-plus-soybean.git
synced 2025-09-24 07:49:47 +08:00
fix(projects): 修复页面缓存,添加多页签删除
This commit is contained in:
@ -11,7 +11,10 @@
|
||||
:key="item.path"
|
||||
:type="app.multiTab.activeRoute === item.fullPath ? 'primary' : 'default'"
|
||||
class="cursor-pointer"
|
||||
:closable="item.name !== ROUTE_HOME.name"
|
||||
size="large"
|
||||
@click="handleClickTab(item.fullPath)"
|
||||
@close="removeMultiTab(item.fullPath)"
|
||||
>
|
||||
{{ item.meta?.title }}
|
||||
</n-tag>
|
||||
@ -28,6 +31,7 @@ import { useRoute } from 'vue-router';
|
||||
import { NSpace, NTag } from 'naive-ui';
|
||||
import { useThemeStore, useAppStore } from '@/store';
|
||||
import { useRouterChange } from '@/hooks';
|
||||
import { ROUTE_HOME } from '@/router';
|
||||
|
||||
defineProps({
|
||||
zIndex: {
|
||||
@ -39,7 +43,7 @@ defineProps({
|
||||
const route = useRoute();
|
||||
const theme = useThemeStore();
|
||||
const app = useAppStore();
|
||||
const { initMultiTab, addMultiTab, setActiveMultiTab, handleClickTab } = useAppStore();
|
||||
const { initMultiTab, addMultiTab, removeMultiTab, setActiveMultiTab, handleClickTab } = useAppStore();
|
||||
const { toReload } = useRouterChange();
|
||||
|
||||
const fixedHeaderAndTab = computed(() => theme.fixedHeaderAndTab || theme.navStyle.mode === 'horizontal-mix');
|
||||
|
Reference in New Issue
Block a user