From 55fb956c733bffcb34297a4abec5ba6627355544 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B8=B8=E7=86=9F=E5=90=B4=E5=BD=A6=E7=A5=96?= Date: Wed, 21 Jan 2026 10:35:14 +0800 Subject: [PATCH] =?UTF-8?q?fix(warehouse):=20=E8=A7=A3=E5=86=B3IFS?= =?UTF-8?q?=E8=B0=83=E7=94=A8=E9=94=99=E8=AF=AF=E6=97=A5=E5=BF=97=E9=87=8D?= =?UTF-8?q?=E8=AF=95=E5=8A=9F=E8=83=BD=E5=B9=B6=E5=8F=91=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 使用全局重试状态控制按钮,避免多行同时重试 - 添加retryingRowId变量跟踪当前正在重试的行ID - 重试时检查是否有其他行正在重试并显示警告提示 - 优化重试按钮的加载和禁用状态逻辑 - 完善重试过程中的UI反馈和状态同步 --- .../modules/warehouse/ifsCallErrorLog.vue | 34 ++++++++++++++++--- 1 file changed, 29 insertions(+), 5 deletions(-) diff --git a/src/views/modules/warehouse/ifsCallErrorLog.vue b/src/views/modules/warehouse/ifsCallErrorLog.vue index 1a95454..3be25f1 100644 --- a/src/views/modules/warehouse/ifsCallErrorLog.vue +++ b/src/views/modules/warehouse/ifsCallErrorLog.vue @@ -118,15 +118,16 @@ @click="showDetailDialog(scope.row)"> 查看详情 + - {{ scope.row._retrying ? '重试中...' : '重试' }} + {{ retryingRowId === scope.row.id ? '重试中...' : '重试' }} - @@ -142,7 +143,21 @@ label="操作"> @@ -493,6 +508,7 @@ export default { processRemark: '', markProcessedLoading: false, markIgnoredLoading: false, + retryingRowId: null, // 正在重试的行ID,全局唯一 - rqrq // 导出相关 - rqrq exportData: [], exportName: 'IFS错误日志' + this.dayjs().format('YYYYMMDDHHmmss'), @@ -689,12 +705,19 @@ export default { // 手工重试IFS接口调用 - rqrq handleRetry(row) { + // 检查是否有其他行正在重试 - rqrq + if (this.retryingRowId !== null) { + this.$message.warning('请等待当前重试完成后再操作') + return + } + this.$confirm('确定要重试此记录的IFS接口调用吗?', '确认重试', { confirmButtonText: '确定', cancelButtonText: '取消', type: 'warning' }).then(() => { - // 设置loading状态 - rqrq + // 设置全局重试状态 - rqrq + this.retryingRowId = row.id this.$set(row, '_retrying', true) const params = { @@ -719,6 +742,7 @@ export default { }).finally(() => { // 取消loading状态 - rqrq this.$set(row, '_retrying', false) + this.retryingRowId = null }) }).catch(() => { // 用户取消操作