zmdms-utils 0.0.11 → 0.0.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/es/file.js CHANGED
@@ -42,7 +42,7 @@ function downloadFile(fileId, fileName, options) {
42
42
  resolve({ msg: "文件下载成功!" });
43
43
  }
44
44
  else {
45
- reject();
45
+ reject(xhr.response);
46
46
  }
47
47
  };
48
48
  xhr.onerror = function (err) {
@@ -84,7 +84,7 @@ function batchDownloadFiles(fileList, options) {
84
84
  resolve({ msg: "文件下载成功!" });
85
85
  }
86
86
  else {
87
- reject();
87
+ reject(xhr.response);
88
88
  }
89
89
  };
90
90
  xhr.onerror = function (err) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zmdms-utils",
3
- "version": "0.0.11",
3
+ "version": "0.0.12",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",
package/src/file.ts CHANGED
@@ -62,7 +62,7 @@ export function downloadFile(
62
62
 
63
63
  resolve({ msg: "文件下载成功!" });
64
64
  } else {
65
- reject();
65
+ reject(xhr.response);
66
66
  }
67
67
  };
68
68
  xhr.onerror = function (err) {
@@ -119,7 +119,7 @@ export function batchDownloadFiles(
119
119
 
120
120
  resolve({ msg: "文件下载成功!" });
121
121
  } else {
122
- reject();
122
+ reject(xhr.response);
123
123
  }
124
124
  };
125
125
  xhr.onerror = function (err) {