refactor(仪表板、数据大屏): 优化页面打开方式

This commit is contained in:
wangjiahao
2024-11-24 19:56:31 +08:00
parent 7d03a3822d
commit d145101de8
2 changed files with 10 additions and 3 deletions

View File

@@ -227,7 +227,7 @@ export function historyAdaptor(
canvasVersion
) {
const curVersion = wsCache.get('x-de-execute-version')
if (canvasInfo['checkVersion'] === curVersion) {
if (canvasInfo?.checkVersion === curVersion) {
return
}
//历史字段适配
@@ -262,7 +262,9 @@ export function historyAdaptor(
canvasDataResult.forEach(componentItem => {
historyItemAdaptor(componentItem, reportFilterInfo, attachInfo, canvasVersion, canvasInfo)
})
updateCheckVersion(canvasInfo.id)
if (canvasInfo && canvasInfo.id) {
updateCheckVersion(canvasInfo.id)
}
}
// 重置仪表板、大屏中的其他组件