From 86e37cdfc389cd5f0e824659caf83b3c7c6b0514 Mon Sep 17 00:00:00 2001 From: fengyuan_yang <1976974459@qq.com> Date: Fri, 30 Jan 2026 16:23:29 +0800 Subject: [PATCH] =?UTF-8?q?2026-01-30=20=E5=B7=A5=E7=A8=8B=E5=8F=98?= =?UTF-8?q?=E6=9B=B4=E7=94=B3=E8=AF=B7=E5=8D=95=E4=BA=BA=E5=A4=9A=E6=9D=A1?= =?UTF-8?q?=E7=9A=84=E9=97=AE=E9=A2=98=EF=BC=8C=E7=82=B9=E5=87=BB=E6=89=A7?= =?UTF-8?q?=E8=A1=8C/=E4=BC=9A=E7=AD=BE=E4=BC=9A=E5=B0=86=E6=89=A7?= =?UTF-8?q?=E8=A1=8C/=E4=BC=9A=E7=AD=BE=E4=BA=BA=E7=9B=B8=E5=90=8C?= =?UTF-8?q?=E7=9A=84=E4=BF=A1=E6=81=AF=E4=B8=80=E5=B9=B6=E5=A4=84=E7=90=86?= =?UTF-8?q?=EF=BC=88=E6=A0=87=E8=AF=86=E5=92=8C=E6=97=B6=E9=97=B4=E8=B5=8B?= =?UTF-8?q?=E5=80=BC=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../modules/changeManagement/changeRecord.vue | 55 ++++++++++++++----- 1 file changed, 40 insertions(+), 15 deletions(-) diff --git a/src/views/modules/changeManagement/changeRecord.vue b/src/views/modules/changeManagement/changeRecord.vue index 2775291..cca40e2 100644 --- a/src/views/modules/changeManagement/changeRecord.vue +++ b/src/views/modules/changeManagement/changeRecord.vue @@ -4756,8 +4756,16 @@ this.$message.warning('请添加需要变更的技术参数卡!') return } - row.executeFlag = 'Y' - row.itemExecutionDate = new Date(+ new Date() + 8 * 3600 * 1000).toISOString().replace(/T/g, ' ').replace(/\.[\d]{3}Z/, '') + // 获取当前执行时间 + const executionDate = new Date(+ new Date() + 8 * 3600 * 1000).toISOString().replace(/T/g, ' ').replace(/\.[\d]{3}Z/, '') + // 获取当前行的执行人 + const currentExecutor = row.executor + // 找出所有执行人相同的行,一起更新执行标识和执行时间 + const sameExecutorRows = this.chooseItemList.filter(item => item.executor === currentExecutor && item.executeFlag !== 'Y') + sameExecutorRows.forEach(item => { + item.executeFlag = 'Y' + item.itemExecutionDate = executionDate + }) this.costImpactData.changeTotalCost = this.totalCost this.executionInfoData.chooseItemList = this.chooseItemList this.executionInfoData.chooseItemList2 = this.chooseItemList2 @@ -4783,21 +4791,22 @@ this.$alert(data.msg, '错误', { confirmButtonText: '确定' }) - row.executeFlag = '' - row.itemExecutionDate = '' + // 回滚:清除所有相同执行人的执行标识和时间 + sameExecutorRows.forEach(item => { + item.executeFlag = '' + item.itemExecutionDate = '' + }) } this.submitLoading = false }).catch(()=>{ + // 回滚:清除所有相同执行人的执行标识和时间 + sameExecutorRows.forEach(item => { + item.executeFlag = '' + item.itemExecutionDate = '' + }) this.submitLoading = false }) }) - // row.executeFlag = 'Y' - // row.itemExecutionDate = new Date(+ new Date() + 8 * 3600 * 1000).toISOString().replace(/T/g, ' ').replace(/\.[\d]{3}Z/, '') - // row.executor = this.$store.state.user.name - // // 执行时调用同意提交方法 // 2025-04-15 海波要求修改 一定会是审批中状态 - // if (this.modalData.changeStatus === '审批中') { - // this.agreeSubmit() - // } }, // 执行所选属性 @@ -4885,8 +4894,16 @@ this.$message.warning('请添加需要变更的技术参数卡!') return } - row.executeFlag = 'Y' - row.itemExecutionDate = new Date(+ new Date() + 8 * 3600 * 1000).toISOString().replace(/T/g, ' ').replace(/\.[\d]{3}Z/, '') + // 获取当前会签时间 + const executionDate = new Date(+ new Date() + 8 * 3600 * 1000).toISOString().replace(/T/g, ' ').replace(/\.[\d]{3}Z/, '') + // 获取当前行的会签人(itemDesc 字段) + const currentCountersigner = row.itemDesc + // 找出所有会签人相同的行,一起更新会签标识和会签时间 + const sameCountersignerRows = this.chooseCSItemList.filter(item => item.itemDesc === currentCountersigner && item.executeFlag !== 'Y') + sameCountersignerRows.forEach(item => { + item.executeFlag = 'Y' + item.itemExecutionDate = executionDate + }) this.costImpactData.changeTotalCost = this.totalCost this.executionInfoData.chooseItemList = this.chooseItemList this.executionInfoData.chooseItemList2 = this.chooseItemList2 @@ -4912,11 +4929,19 @@ this.$alert(data.msg, '错误', { confirmButtonText: '确定' }) - row.executeFlag = '' - row.itemExecutionDate = '' + // 回滚:清除所有相同会签人的会签标识和时间 + sameCountersignerRows.forEach(item => { + item.executeFlag = '' + item.itemExecutionDate = '' + }) } this.submitLoading = false }).catch(()=>{ + // 回滚:清除所有相同会签人的会签标识和时间 + sameCountersignerRows.forEach(item => { + item.executeFlag = '' + item.itemExecutionDate = '' + }) this.submitLoading = false }) })