Explorar el Código

feat(组件): 下载文件流

tangning hace 2 años
padre
commit
514002a9b5
Se han modificado 1 ficheros con 1 adiciones y 2 borrados
  1. 1 2
      src/utils/http/axios/Axios.ts

+ 1 - 2
src/utils/http/axios/Axios.ts

@@ -224,8 +224,7 @@ export class VAxios {
             createMessage.error(jsonData.message);
           } catch (err) { // 解析成对象失败,说明是正常的文件流
             // 下载文件
-            console.log('err',err)
-            downloadByData(err,config.fileName)
+            downloadByData(resData,config.fileName)
           }
         }
         fileReader.readAsText(resData)