|
@@ -50,6 +50,7 @@
|
|
|
:type="exportDetailDisabled ? 'info' : 'primary'"
|
|
|
v-if="exportDetailShow"
|
|
|
:disabled="exportDetailDisabled"
|
|
|
+ :loading="exportLoading"
|
|
|
size="small"
|
|
|
@click="downInfo"
|
|
|
>{{ exportBtnText }}</el-button
|
|
@@ -139,6 +140,7 @@ export default {
|
|
|
data() {
|
|
|
return {
|
|
|
exportDialogVisible: false,
|
|
|
+ exportLoading: false,
|
|
|
exportUrl: '',
|
|
|
exportForm: {
|
|
|
startDate: ''
|
|
@@ -491,6 +493,7 @@ export default {
|
|
|
|
|
|
async downInfo() {
|
|
|
try {
|
|
|
+ this.exportLoading = true;
|
|
|
// 拼接日期,格式为 年/月
|
|
|
const dateStr = dayjs().format('YYYY-MM');
|
|
|
const fileName = `监督任务数据${dateStr}.xlsx`;
|
|
@@ -516,8 +519,10 @@ export default {
|
|
|
|
|
|
// 释放内存
|
|
|
URL.revokeObjectURL(link.href);
|
|
|
+ this.exportLoading = false;
|
|
|
} catch (err) {
|
|
|
console.error('下载出错:', err);
|
|
|
+ this.exportLoading = false;
|
|
|
}
|
|
|
},
|
|
|
handleExportDialogClose() {
|