From 5335b3aa84623d590346183b71117772af6113e0 Mon Sep 17 00:00:00 2001 From: luojie <125330818@qq.com> Date: Tue, 24 Feb 2026 18:22:00 +0800 Subject: [PATCH] =?UTF-8?q?feat:[=E6=A8=A1=E6=9D=BF=E7=AE=A1=E7=90=86][upd?= =?UTF-8?q?ate]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../business/comps/template/comps/sp/SP003.vue | 4 ++ .../business/comps/template/comps/sp/SP00456.vue | 53 ++++++++++++++-------- 2 files changed, 38 insertions(+), 19 deletions(-) diff --git a/src/views/business/comps/template/comps/sp/SP003.vue b/src/views/business/comps/template/comps/sp/SP003.vue index 9c84f7f..a6a9467 100644 --- a/src/views/business/comps/template/comps/sp/SP003.vue +++ b/src/views/business/comps/template/comps/sp/SP003.vue @@ -307,6 +307,7 @@ export default { showBodySub: this.fillType === "preFill", bodyDisabled: true, bodyPrecisionKey: "targetStartSolutionVolumePrecision", + subPrecision:0, bodyMaxlength: 10, bodySubPlaceholder: "template.common.xswsPlaceholder", headerSelectTo: "actStartSolutionVolumeUnit", @@ -341,6 +342,7 @@ export default { showBodySub: this.fillType === "preFill", bodyDisabled: true, bodyPrecisionKey: "targetDiluentVolumePrecision", + subPrecision:0, bodyMaxlength: 10, bodySubPlaceholder: "请输入保留小数位数", headerSelectTo: "actDiluentVolumeUnit", @@ -388,6 +390,7 @@ export default { showBodySub: this.fillType === "preFill", bodyDisabled: true, bodyPrecisionKey: "actSolutionConcentrationPrecision", + subPrecision:0, bodyMaxlength: 10, bodySubPlaceholder: "请输入保留小数位数", compareTo: "targetSolutionConcentration",//与哪个字段比较 @@ -421,6 +424,7 @@ export default { showBodySub: this.fillType === "preFill", bodyDisabled: true, bodyPrecisionKey: "actSolutionVolumePrecision", + subPrecision:0, bodyMaxlength: 10, bodySubPlaceholder: "请输入保留小数位数", compareTo: "targetSolutionVolume",//与哪个字段比较 diff --git a/src/views/business/comps/template/comps/sp/SP00456.vue b/src/views/business/comps/template/comps/sp/SP00456.vue index 90fac05..a20ca1d 100644 --- a/src/views/business/comps/template/comps/sp/SP00456.vue +++ b/src/views/business/comps/template/comps/sp/SP00456.vue @@ -23,14 +23,14 @@ -
+
{{ $t('template.common.jtpz') }}
{{ $t('template.common.deleteBtn') - }} + @click="deleteConfig('ladderConfigs', ladderConfig)">{{ $t('template.common.deleteBtn') + }}
-
+
{{ $t('template.common.pxpz') }}
{{ $t('template.common.deleteBtn') - }} + @click="deleteConfig('paralleConfigs', paralleConfig)">{{ $t('template.common.deleteBtn') + }}
config.id === config.id); + if (configIndex !== -1) { + // 创建新数组,确保响应式更新 + const newConfigs = [...this.formData[type]]; + newConfigs.splice(configIndex, 1); + this.$set(this.formData, type, newConfigs); + this.$nextTick(() => { + //通知后端保存数据 + const params = { + type: "fieldChanged", + newRecord: null, + resourceList: null, + } + EventBus.$emit('onModifyRecord', params,) + }) + } }, // 添加表格行 handleAddRow(type, rowIndex, configIndex = 0) { @@ -631,6 +642,7 @@ export default { const ladderConfigsData = []; if (this.formData.ladderConfigs && this.formData.ladderConfigs.length > 0) { for (let i = 0; i < this.formData.ladderConfigs.length; i++) { + const id = this.formData.ladderConfigs[i].id; const ladderFormData = this.$refs[`ladderStepFormPackageRef_${i}`][0].getFilledFormData(); const ladderTableFormData = this.$refs[`ladderStepTableRef_${i}`][0].getFilledFormData(); const ladderStepData = this.$refs[`ladderStepRef_${i}`][0].getFilledFormData(); @@ -639,7 +651,8 @@ export default { ...ladderFormData, ...ladderTableFormData, ladderStepData: ladderStepData.stepData, - showLadderConfig: true + showLadderConfig: true, + id }); } } @@ -648,6 +661,7 @@ export default { const paralleConfigsData = []; if (this.formData.paralleConfigs && this.formData.paralleConfigs.length > 0) { for (let i = 0; i < this.formData.paralleConfigs.length; i++) { + const id = this.formData.paralleConfigs[i].id; const paralleFormData = this.$refs[`paralleStepFormPackageRef_${i}`][0].getFilledFormData(); const paralleTableFormData = this.$refs[`paralleStepTableRef_${i}`][0].getFilledFormData(); const paralleStepData = this.$refs[`paralleStepRef_${i}`][0].getFilledFormData(); @@ -656,7 +670,8 @@ export default { ...paralleFormData, ...paralleTableFormData, paralleStepData: paralleStepData.stepData, - showParalleConfig: true + showParalleConfig: true, + id }); } }