From 2c76369e3187d5d2916f736cea9876bb99524f59 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=98=89=E8=B1=AA?= <42510293+ziyujiahao@users.noreply.github.com> Date: Mon, 13 Oct 2025 16:12:14 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E4=BB=AA=E8=A1=A8=E6=9D=BF=E3=80=81?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E5=A4=A7=E5=B1=8F):=20=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E8=AE=BE=E7=BD=AE=E5=A4=9A=E7=BB=84=E7=BA=A7=E8=81=94=EF=BC=8C?= =?UTF-8?q?=E6=90=AD=E9=85=8D=E5=A4=96=E9=83=A8=E5=8F=82=E6=95=B0=E4=BD=BF?= =?UTF-8?q?=E7=94=A8=E4=BC=A0=E5=85=A5=E5=A4=9A=E5=8F=82=E6=95=B0=EF=BC=8C?= =?UTF-8?q?=E5=8F=AA=E4=BC=9A=E7=94=9F=E6=95=88=E4=B8=80=E7=BB=84=E9=97=AE?= =?UTF-8?q?=E9=A2=98=20#17035=20(#17169)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/store/modules/data-visualization/dvMain.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/core/core-frontend/src/store/modules/data-visualization/dvMain.ts b/core/core-frontend/src/store/modules/data-visualization/dvMain.ts index 96a86ff43b..fa2059bfef 100644 --- a/core/core-frontend/src/store/modules/data-visualization/dvMain.ts +++ b/core/core-frontend/src/store/modules/data-visualization/dvMain.ts @@ -1194,6 +1194,7 @@ export const dvMainStore = defineStore('dataVisualization', { return } const currentFilters = [] // 外部参数信息 + const defaultValueMap = {} // 外部参数 可能会包含多个参数 Object.keys(params).forEach(function (sourceInfo) { // 获取外部参数的值 sourceInfo 是外部参数名称 支持数组传入 @@ -1258,7 +1259,6 @@ export const dvMainStore = defineStore('dataVisualization', { preActiveComponentIds.push(element.id) } if (element.component === 'VQuery') { - const defaultValueMap = {} element.propValue?.forEach(filterItem => { if (filterItem.id === targetViewId) { let queryParams = paramValue @@ -1330,6 +1330,10 @@ export const dvMainStore = defineStore('dataVisualization', { } } }) + const allCascadeDataset = element.cascade + .flat() + .map(item => `--${item.datasetId}`) + .join('') // 级联条件处理 if (element.cascade?.length && Object.keys(defaultValueMap).length) { element.cascade.forEach(cascadeItem => { @@ -1344,7 +1348,7 @@ export const dvMainStore = defineStore('dataVisualization', { itemInner['selectValue'] = Array.isArray(curDefaultValue) ? curDefaultValue : [curDefaultValue] - } else { + } else if (!allCascadeDataset.includes(key)) { itemInner['currentSelectValue'] = [] itemInner['selectValue'] = [] }