Commit 65891de3 authored by dragondean@qq.com's avatar dragondean@qq.com

商品和价格导出改异步

parent df21715e
......@@ -389,7 +389,6 @@ export function exportSettlementExcel(params) {
return request({
url: "/shipment/box/export-shipment-summary",
method: "get",
responseType: "blob",
params,
});
}
......@@ -66,8 +66,7 @@ export function exportProductExcel(query) {
return request({
url: '/ecw/product/export-excel',
method: 'get',
params: query,
responseType: 'blob'
params: query
})
}
......
......@@ -50,7 +50,6 @@ export function exportProductPriceExcel(query) {
method: 'get',
timeout: 3*60*1000,
params: query,
responseType: 'blob'
})
}
......
......@@ -671,7 +671,8 @@ export default {
this.exportLoading = true;
return exportProductExcel(params);
}).then(response => {
this.$download.excel(response, '商品.xlsx');
// this.$download.excel(response, '商品.xlsx');
this.$message.success(this.$t('已加入导出队列,请稍后在下载日志中下载'))
this.exportLoading = false;
}).catch(() => { });
},
......
......@@ -548,7 +548,7 @@ export default {
// }
// 价格列表 跟 商品的价格列表,有时候商品价格列表的路由变动会导致价格列表也执行此处代码,所以做一个判断排除
// https://zentao.test.jdshangmen.com/bug-view-4928.html
if(this.$route.path != this.entryPath) return
if(this.$route.path != this.entryPath) return
let productId = this.product?.id
if(this.$route.name === 'ProductPrice'){
......@@ -847,8 +847,9 @@ export default {
this.exportLoading = true;
return exportProductPriceExcel(params);
}).then(response => {
this.$download.excel(response, '路线价格.xlsx');
// this.$download.excel(response, '路线价格.xlsx');
this.exportLoading = false;
this.$message.success(this.$t('已加入导出队列,请稍后在下载日志中下载'))
}).catch(() => {
this.exportLoading = false;
});
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment