From 74490007da9650b74ca1ceba7391b18f6b215f95 Mon Sep 17 00:00:00 2001 From: dataeaseShu Date: Thu, 8 Aug 2024 15:25:07 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E6=95=B0=E6=8D=AE=E9=9B=86):=20=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E9=9B=86=E6=B7=BB=E5=8A=A0=E8=AE=A1=E7=AE=97=E5=8F=82?= =?UTF-8?q?=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../visualized/data/dataset/form/CalcFieldEdit.vue | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/core/core-frontend/src/views/visualized/data/dataset/form/CalcFieldEdit.vue b/core/core-frontend/src/views/visualized/data/dataset/form/CalcFieldEdit.vue index d750291987..669fee0a9d 100644 --- a/core/core-frontend/src/views/visualized/data/dataset/form/CalcFieldEdit.vue +++ b/core/core-frontend/src/views/visualized/data/dataset/form/CalcFieldEdit.vue @@ -64,7 +64,6 @@ const state = reactive({ functionData: [], dimensionData: [], dimensionList: [], - quotaList: [], quotaData: [] }) const formQuotaRef = ref() @@ -96,13 +95,11 @@ const formQuotaConfirm = () => { const q = cloneDeep(unref(formQuota)) fieldForm.params = [q] const i = state.quotaData.find(ele => ele.id === formQuota.id) - const j = state.quotaList.find(ele => ele.id === formQuota.id) - if (i && j) { + if (i) { const str = mirror.value.state.doc.toString() const name2Auto = [] fieldForm.originName = setNameIdTrans('name', 'id', str, name2Auto) Object.assign(i, cloneDeep(unref(formQuota))) - Object.assign(j, cloneDeep(unref(formQuota))) nextTick(() => { mirror.value.dispatch({ @@ -115,7 +112,6 @@ const formQuotaConfirm = () => { }) } else { state.quotaData.push(q) - state.quotaList.push(q) } formQuotaClose() } @@ -263,9 +259,10 @@ defineExpose({ fieldForm, formField }) - +const parmasTitle = ref('') const addParmasToQuota = () => { if (disableCaParams.value) return + parmasTitle.value = '添加计算参数' if (!fieldForm.params) { fieldForm.params = [] } @@ -274,6 +271,7 @@ const addParmasToQuota = () => { const updateParmasToQuota = () => { const [o] = fieldForm.params + parmasTitle.value = '编辑计算参数' Object.assign(formQuota, o || {}) dialogFormVisible.value = true } @@ -289,7 +287,6 @@ const delParmasToQuota = () => { const name2Auto = [] fieldForm.originName = setNameIdTrans('name', 'id', str, name2Auto).replaceAll(`[${o.id}]`, '') state.quotaData = state.quotaData.filter(ele => ele.id !== o.id) - state.quotaList = state.quotaList.filter(ele => ele.id !== o.id) mirror.value.dispatch({ changes: { from: 0,