From 86daf12f24a41ed4279720426c291416e4394cb7 Mon Sep 17 00:00:00 2001 From: dataeaseShu Date: Thu, 4 Jul 2024 15:57:48 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E6=9F=A5=E8=AF=A2=E7=BB=84=E4=BB=B6):=20?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E9=9B=86=E6=B2=A1=E6=9C=89=E8=A2=AB=E5=9B=BE?= =?UTF-8?q?=E8=A1=A8=E4=BD=BF=E7=94=A8=E7=9A=84=E6=83=85=E5=86=B5=E4=B8=8B?= =?UTF-8?q?=EF=BC=8C=E6=97=A0=E6=B3=95=E8=AE=BE=E7=BD=AE=E8=B7=A8=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E9=9B=86=E7=BA=A7=E8=81=94?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/custom-component/v-query/QueryCascade.vue | 2 +- .../v-query/QueryConditionConfiguration.vue | 11 +++++++++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/core/core-frontend/src/custom-component/v-query/QueryCascade.vue b/core/core-frontend/src/custom-component/v-query/QueryCascade.vue index f0e9ec50f5..9ac5b8d3a7 100644 --- a/core/core-frontend/src/custom-component/v-query/QueryCascade.vue +++ b/core/core-frontend/src/custom-component/v-query/QueryCascade.vue @@ -209,7 +209,7 @@ defineExpose({ - 基于当前查询组件的查询条件,如果需要进行级联联配置,需要满足以下条件:
+ 基于当前查询组件的查询条件,如果需要进行级联配置,需要满足以下条件:
1. 展示类型:文本下拉组件和数字下拉组件;2. 选项值来源:选择数据集
diff --git a/core/core-frontend/src/custom-component/v-query/QueryConditionConfiguration.vue b/core/core-frontend/src/custom-component/v-query/QueryConditionConfiguration.vue index 72948e8c92..d7c4865081 100644 --- a/core/core-frontend/src/custom-component/v-query/QueryConditionConfiguration.vue +++ b/core/core-frontend/src/custom-component/v-query/QueryConditionConfiguration.vue @@ -540,14 +540,20 @@ const CascadeDialog = defineAsyncComponent(() => import('./QueryCascade.vue')) const cascadeDialog = ref() const openCascadeDialog = () => { const cascadeMap = conditions.value - .filter(ele => [0, 2, 5].includes(+ele.displayType) && ele.optionValueSource === 1) + .filter( + ele => + [0, 2, 5].includes(+ele.displayType) && + ele.optionValueSource === 1 && + !!ele.checkedFields?.length && + !!Object.values(ele.checkedFieldsMap).filter(item => !!item).length + ) .reduce((pre, next) => { pre[next.id] = { datasetId: next.dataset.id, name: next.name, queryId: next.id, fieldId: next.field.id, - deType: datasetMap[next.dataset.id].fields?.dimensionList.find( + deType: (datasetMap[next.dataset.id]?.fields?.dimensionList || next.dataset.fields).find( ele => ele.id === next.field.id )?.deType } @@ -1417,6 +1423,7 @@ defineExpose({ +