Browse Source

Merge branch 'master' into dev-calendar

test
dai 3 years ago
parent
commit
36c6ae9aad
  1. 11
      src/views/modules/cpts/baobiao/index.vue

11
src/views/modules/cpts/baobiao/index.vue

@ -148,6 +148,14 @@ export default {
async exportAll(reportId, paramKey, reportName) {
const url = "/oper/customize/icCustomerReport/batch-export";
const loading = this.$loading({
lock: true,
text: "批量导出中",
spinner: "el-icon-loading",
background: "rgba(0, 0, 0, 0.5)",
});
axios({
url: window.SITE_CONFIG["apiURL"] + url,
method: "post",
@ -158,6 +166,7 @@ export default {
responseType: "blob",
})
.then((res) => {
loading.close();
console.log("批量导出接口返回", res);
// let fileName = window.decodeURI(
// res.headers["content-disposition"].split(";")[1].split("=")[1]
@ -177,6 +186,8 @@ export default {
})
.catch((err) => {
console.log("批量导出失败", err);
loading.close();
return this.$message.error("网络错误");
});
},

Loading…
Cancel
Save