From 5761a73287965d00cde0df992236952b940f234b Mon Sep 17 00:00:00 2001 From: zhangdi <1104545947@qq.com> Date: Sat, 28 Mar 2026 10:52:46 +0800 Subject: [PATCH] =?UTF-8?q?=E9=95=80=E5=89=8D=E5=87=BA=E5=85=A5=E5=BA=93?= =?UTF-8?q?=E6=8E=A5=E5=8F=A3=E8=81=94=E8=B0=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/afterPlatingEntryDialog.vue | 28 ++-- .../components/beforePlatingBoundDialog.vue | 34 ++-- .../components/beforePlatingEntryDialog.vue | 147 ++++++++++++++---- 3 files changed, 147 insertions(+), 62 deletions(-) diff --git a/src/views/productionManagement/beforeAndAfterPlating/components/afterPlatingEntryDialog.vue b/src/views/productionManagement/beforeAndAfterPlating/components/afterPlatingEntryDialog.vue index ee5eb0b..9ae41ef 100644 --- a/src/views/productionManagement/beforeAndAfterPlating/components/afterPlatingEntryDialog.vue +++ b/src/views/productionManagement/beforeAndAfterPlating/components/afterPlatingEntryDialog.vue @@ -87,8 +87,8 @@ @@ -109,6 +109,7 @@ export default { }, data() { return { + sunmitLoading:false, tableLoading: false, formError: '', cardNo: '', @@ -199,25 +200,24 @@ export default { } // 校验通过:准备提交数据(过滤无用字段) - const submitData = this.form.tableData.map(row => { + const submitData = this.form.beforePlatingEntryData.map(row => { const { _select, ...validData } = row; // 剔除选择状态字段 return validData; }); - + this.sunmitLoading =true // 调用接口提交(实际项目替换) try { - savePlateAroundPlateAfterEnter({ ...this.form.beforePlatingEntryData , paType: 3 }).then( - res => { - this.$message.success('提交成功'); - this.closeDialog(); - this.$emit('submitSuccess', submitData); - } - ); - - // 演示用 + savePlateAroundPlateAfterEnter(this.form.beforePlatingEntryData).then(res => { + this.$message.success('提交成功'); + this.closeDialog(); + this.$emit('submitSuccess', submitData); + this.sunmitLoading =false + }).catch(err=>{ + this.sunmitLoading =false + }) } catch (err) { - this.$message.error('网络错误,请稍后重试'); console.error('提交失败:', err); + this.sunmitLoading =false } }); }, diff --git a/src/views/productionManagement/beforeAndAfterPlating/components/beforePlatingBoundDialog.vue b/src/views/productionManagement/beforeAndAfterPlating/components/beforePlatingBoundDialog.vue index 1a3ebcf..4de569c 100644 --- a/src/views/productionManagement/beforeAndAfterPlating/components/beforePlatingBoundDialog.vue +++ b/src/views/productionManagement/beforeAndAfterPlating/components/beforePlatingBoundDialog.vue @@ -43,7 +43,8 @@ - + +