From 3fe8324c941cfb04b3bc253f04e8f389cc1a5856 Mon Sep 17 00:00:00 2001 From: quanyawei <401863037@qq.com> Date: Wed, 29 Nov 2023 08:58:57 +0800 Subject: [PATCH] fix:导出修改 --- src/views/toCarryOutLegislativeReforms/reform/index.vue | 19 +++++++++++++++---- 1 files changed, 15 insertions(+), 4 deletions(-) diff --git a/src/views/toCarryOutLegislativeReforms/reform/index.vue b/src/views/toCarryOutLegislativeReforms/reform/index.vue index cdeb5b5..b12d231 100644 --- a/src/views/toCarryOutLegislativeReforms/reform/index.vue +++ b/src/views/toCarryOutLegislativeReforms/reform/index.vue @@ -332,15 +332,20 @@ this.$confirm('������������������������������?', '������', { confirmButtonText: '������������', cancelButtonText: '������������', + distinguishCancelAndClose: true, type: 'warning' }) .then(() => { this.loading = true this.exportData() }) - .catch(() => { - this.loading = false - this.exportData() + .catch(action => { + if (action === 'cancel') { + this.loading = false + this.exportData() + } else { + this.loading = false + } }) }, exportData() { @@ -371,6 +376,7 @@ cancel = c }), onDownloadProgress(progress) { + console.log('onDownloadProgress', progress) const loaded = progress.loaded // progress������������loaded������������������������������total������������������������������������������ let downProgress = Math.round((loaded / totalSize) * 100) @@ -427,7 +433,12 @@ link.click() // ������������������������ url.revokeObjectURL(link.href) - this.$message.success('���������������') + this.$message({ + showClose: true, + duration: 0, + message: '���������������', + type: 'success' + }) this.loading = false } }, -- Gitblit v1.8.0