Vue2导出方法修改成文件流
This commit is contained in:
parent
54a7734fa9
commit
25142f5cc5
@ -134,8 +134,8 @@ namespace ZR.Admin.WebApi.Controllers.System
|
||||
{
|
||||
var list = PostService.GetAll();
|
||||
|
||||
string sFileName = ExportExcel(list, "syspost", "岗位");
|
||||
return SUCCESS(new { path = "/export/" + sFileName, fileName = sFileName });
|
||||
var result = ExportExcelMini(list, "post", "岗位列表");
|
||||
return ExportExcel(result.Item2, result.Item1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -372,13 +372,9 @@ $if(replaceDto.ShowBtnExport)
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
type: "warning",
|
||||
}).then(async () => {
|
||||
await export${genTable.BusinessName}(queryParams);
|
||||
})
|
||||
.then(function () {
|
||||
return export${genTable.BusinessName}(queryParams);
|
||||
})
|
||||
.then((response) => {
|
||||
this.download(response.data.path);
|
||||
});
|
||||
},
|
||||
$end
|
||||
//展开/折叠操作
|
||||
|
||||
@ -376,13 +376,9 @@ $if(replaceDto.ShowBtnExport)
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
type: "warning",
|
||||
}).then(async () => {
|
||||
await export${genTable.BusinessName}(queryParams);
|
||||
})
|
||||
.then(function () {
|
||||
return export${genTable.BusinessName}(queryParams);
|
||||
})
|
||||
.then((response) => {
|
||||
this.download(response.data.path);
|
||||
});
|
||||
},
|
||||
$end
|
||||
},
|
||||
|
||||
@ -249,13 +249,9 @@ $if(replaceDto.ShowBtnExport)
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
type: "warning",
|
||||
}).then(async () => {
|
||||
await export${genTable.BusinessName}(queryParams);
|
||||
})
|
||||
.then(function () {
|
||||
return export${genTable.BusinessName}(queryParams);
|
||||
})
|
||||
.then((response) => {
|
||||
this.download(response.data.path);
|
||||
});
|
||||
},
|
||||
$end
|
||||
},
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user