Merge pull request #11212 from dataease/pr@dev-v2@refactor_tab-redo

fix: 修复因在编辑界面点击撤销或重做导致的Tab页布局变化问题
This commit is contained in:
王嘉豪 2024-07-29 11:13:45 +08:00 committed by GitHub
commit 99e990eb5c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -134,23 +134,25 @@ const handleMouseDown = e => {
}
const canvasInit = (isFistLoad = true) => {
renderState.value = true
setTimeout(function () {
if (canvasOut.value) {
dashboardCanvasSizeInit()
nextTick(() => {
cyGridster.value.canvasInit() //
cyGridster.value.afterInitOk(function () {
renderState.value = false
if (canvasActive.value) {
renderState.value = true
setTimeout(function () {
if (canvasOut.value) {
dashboardCanvasSizeInit()
nextTick(() => {
cyGridster.value.canvasInit() //
cyGridster.value.afterInitOk(function () {
renderState.value = false
})
})
})
}
// afterInit
dvMainStore.setDataPrepareState(true)
if (isMainCanvas(canvasId.value) && isFistLoad) {
snapshotStore.recordSnapshotCache('renderChart')
}
}, 500)
}
// afterInit
dvMainStore.setDataPrepareState(true)
if (isMainCanvas(canvasId.value) && isFistLoad) {
snapshotStore.recordSnapshotCache('renderChart')
}
}, 500)
}
}
const canvasSizeInit = () => {