From 904a96539a4d994b56759782b3c671fbc3d33490 Mon Sep 17 00:00:00 2001 From: wangjiahao <1522128093@qq.com> Date: Thu, 23 May 2024 17:47:50 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E4=BB=AA=E8=A1=A8=E6=9D=BF):=20=E4=BF=AE?= =?UTF-8?q?=E5=A4=8D=E6=96=B0=E5=A4=8D=E5=88=B6=E7=9A=84=E4=BB=AA=E8=A1=A8?= =?UTF-8?q?=E6=9D=BF=E6=9C=AA=E4=BF=9D=E5=AD=98=E6=98=AF=E5=88=87=E6=8D=A2?= =?UTF-8?q?=E5=88=B0=E7=A7=BB=E5=8A=A8=E7=AB=AF=E4=BC=9A=E5=BC=B9=E5=87=BA?= =?UTF-8?q?=E6=9D=83=E9=99=90=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- core/core-frontend/src/components/dashboard/DbToolbar.vue | 2 +- core/core-frontend/src/views/dashboard/index.vue | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/core/core-frontend/src/components/dashboard/DbToolbar.vue b/core/core-frontend/src/components/dashboard/DbToolbar.vue index a1a57a20a6..bf19c1b2d7 100644 --- a/core/core-frontend/src/components/dashboard/DbToolbar.vue +++ b/core/core-frontend/src/components/dashboard/DbToolbar.vue @@ -219,7 +219,7 @@ const openDataBoardSetting = () => { } const openMobileSetting = () => { - if (!dvInfo.value.id) { + if (!dvInfo.value.id || dvInfo.value.dataState === 'prepare') { ElMessage.warning('请先保存当前页面') return } diff --git a/core/core-frontend/src/views/dashboard/index.vue b/core/core-frontend/src/views/dashboard/index.vue index 8e3541c2b6..ac9d33590d 100644 --- a/core/core-frontend/src/views/dashboard/index.vue +++ b/core/core-frontend/src/views/dashboard/index.vue @@ -137,6 +137,13 @@ const initLocalCanvasData = () => { dvInfo.value.pid = sourcePid setTimeout(() => { snapshotStore.recordSnapshotCache() + // 复制时,初始化的保存按钮为激活状态 + if (opt === 'copy') { + // 使用缓存时,初始化的保存按钮为激活状态 + setTimeout(() => { + snapshotStore.recordSnapshotCache('renderChart') + }, 1000) + } }, 1500) } })