fix: [临时方案]修复因element-plus-x 1.3.98 中Conversations组件销毁问题出现的布局路由缺陷

This commit is contained in:
Gsh
2025-12-16 22:00:15 +08:00
parent 4a8b58a65c
commit 9a9230786b
5 changed files with 10 additions and 9 deletions

View File

@@ -13,7 +13,6 @@
.layout-blank{ .layout-blank{
height: 100vh; height: 100vh;
overflow: auto; overflow: auto;
//margin: 20px ;
} }
/* 无样式 */ /* 无样式 */
</style> </style>

View File

@@ -29,7 +29,6 @@ useWindowWidthObserver();
// 应用加载时检查是否需要显示公告弹窗 // 应用加载时检查是否需要显示公告弹窗
onMounted(() => { onMounted(() => {
console.log('announcementStore.shouldShowDialog--', announcementStore.shouldShowDialog);
// 检查是否应该显示弹窗(只有"关闭一周"且未超过7天才不显示 // 检查是否应该显示弹窗(只有"关闭一周"且未超过7天才不显示
// 数据获取已移至 SystemAnnouncementDialog 组件内部,每次打开弹窗时都会获取最新数据 // 数据获取已移至 SystemAnnouncementDialog 组件内部,每次打开弹窗时都会获取最新数据
if (announcementStore.shouldShowDialog) { if (announcementStore.shouldShowDialog) {

View File

@@ -42,8 +42,12 @@ onMounted(() => {
</script> </script>
<template> <template>
<div> <div v-show="layout === 'blankPage'">
<component :is="LayoutComponent[layout]" /> <LayoutBlankPage />
<!-- <component :is="LayoutComponent[layout]" /> -->
</div>
<div v-show="layout !== 'blankPage'">
<LayoutVertical />
</div> </div>
</template> </template>

View File

@@ -37,7 +37,7 @@ export const layoutRouter: RouteRecordRaw[] = [
component: () => import('@/pages/products/index.vue'), component: () => import('@/pages/products/index.vue'),
meta: { meta: {
title: '产品页面', title: '产品页面',
keepAlive: true, keepAlive: 0,
isDefaultChat: false, isDefaultChat: false,
layout: 'blankPage', layout: 'blankPage',
}, },
@@ -49,7 +49,7 @@ export const layoutRouter: RouteRecordRaw[] = [
component: () => import('@/pages/modelLibrary/index.vue'), component: () => import('@/pages/modelLibrary/index.vue'),
meta: { meta: {
title: '模型库', title: '模型库',
keepAlive: true, keepAlive: 0,
isDefaultChat: false, isDefaultChat: false,
layout: 'blankPage', layout: 'blankPage',
}, },
@@ -60,7 +60,7 @@ export const layoutRouter: RouteRecordRaw[] = [
component: () => import('@/pages/payResult/index.vue'), component: () => import('@/pages/payResult/index.vue'),
meta: { meta: {
title: '支付结果', title: '支付结果',
keepAlive: true, // 如果需要缓存 keepAlive: 0, // 如果需要缓存
isDefaultChat: false, // 根据实际情况设置 isDefaultChat: false, // 根据实际情况设置
layout: 'blankPage', // 如果需要自定义布局 layout: 'blankPage', // 如果需要自定义布局
}, },
@@ -88,6 +88,7 @@ export const layoutRouter: RouteRecordRaw[] = [
}, },
], ],
}, },
]; ];
// staticRouter[静态路由] 预留 // staticRouter[静态路由] 预留

View File

@@ -24,8 +24,6 @@ declare module 'vue' {
ElCollapseItem: typeof import('element-plus/es')['ElCollapseItem'] ElCollapseItem: typeof import('element-plus/es')['ElCollapseItem']
ElContainer: typeof import('element-plus/es')['ElContainer'] ElContainer: typeof import('element-plus/es')['ElContainer']
ElDatePicker: typeof import('element-plus/es')['ElDatePicker'] ElDatePicker: typeof import('element-plus/es')['ElDatePicker']
ElDescriptions: typeof import('element-plus/es')['ElDescriptions']
ElDescriptionsItem: typeof import('element-plus/es')['ElDescriptionsItem']
ElDialog: typeof import('element-plus/es')['ElDialog'] ElDialog: typeof import('element-plus/es')['ElDialog']
ElDivider: typeof import('element-plus/es')['ElDivider'] ElDivider: typeof import('element-plus/es')['ElDivider']
ElEmpty: typeof import('element-plus/es')['ElEmpty'] ElEmpty: typeof import('element-plus/es')['ElEmpty']