From ec01b80fd09bcafe4da228c8df2a9a0e34c82791 Mon Sep 17 00:00:00 2001 From: wangjiahao <1522128093@qq.com> Date: Thu, 31 Oct 2024 13:46:23 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E5=9B=BE=E8=A1=A8):=20=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E7=A7=BB=E5=8A=A8=E7=AB=AF=E8=AE=BE=E8=AE=A1,=E9=83=A8?= =?UTF-8?q?=E5=88=86=E5=9B=BE=E8=A1=A8=E6=A0=B7=E5=BC=8F=E4=B8=AD=E7=9A=84?= =?UTF-8?q?=E6=8C=87=E6=A0=87=E5=80=BC=E4=B8=8D=E6=98=BE=E7=A4=BA=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../editor/editor-style/ChartStyleCommon.vue | 141 ------------------ .../views/chart/components/editor/index.vue | 28 ++-- 2 files changed, 15 insertions(+), 154 deletions(-) delete mode 100644 core/core-frontend/src/views/chart/components/editor/editor-style/ChartStyleCommon.vue diff --git a/core/core-frontend/src/views/chart/components/editor/editor-style/ChartStyleCommon.vue b/core/core-frontend/src/views/chart/components/editor/editor-style/ChartStyleCommon.vue deleted file mode 100644 index 13850514ad..0000000000 --- a/core/core-frontend/src/views/chart/components/editor/editor-style/ChartStyleCommon.vue +++ /dev/null @@ -1,141 +0,0 @@ - - - - - diff --git a/core/core-frontend/src/views/chart/components/editor/index.vue b/core/core-frontend/src/views/chart/components/editor/index.vue index 197f4bcf55..7472ca678b 100644 --- a/core/core-frontend/src/views/chart/components/editor/index.vue +++ b/core/core-frontend/src/views/chart/components/editor/index.vue @@ -223,20 +223,22 @@ provide('quota', () => state.quota) watch( [() => view.value['tableId']], () => { - if ('picture-group' === props.view.type) { - return - } - getFields(props.view.tableId, props.view.id, props.view.type) - const nodeId = view.value['tableId'] - if (!!nodeId) { - cacheId = nodeId as unknown as string - } - const node = datasetSelector?.value?.getNode(nodeId) - if (node?.data) { - curDatasetWeight.value = node.data.weight - } + nextTick(() => { + if ('picture-group' === props.view.type) { + return + } + getFields(props.view.tableId, props.view.id, props.view.type) + const nodeId = view.value['tableId'] + if (!!nodeId) { + cacheId = nodeId as unknown as string + } + const node = datasetSelector?.value?.getNode(nodeId) + if (node?.data) { + curDatasetWeight.value = node.data.weight + } + }) }, - { deep: true } + { deep: true, immediate: true } ) const getFields = (id, chartId, type) => { if (id && chartId) {