Commit 50a79f7a authored by dragondean@qq.com's avatar dragondean@qq.com

下载异常

parent 1a9ed372
......@@ -19,5 +19,5 @@ export function download(id){
// 获取文件二进制
export function downloadFileResponse(url){
return axios.get(url)
return axios.get(url, {responseType: 'blob'})
}
......@@ -84,6 +84,7 @@ export default {
download(row.id).then(res => {
return downloadFileResponse(res.data)
}).then(res => {
console.log({res})
this.$download.download0(res.data, row.name + row.fileSuffix, res.headers['content-type'])
}).finally(() => {
loading.close()
......
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