sirius-common-utils 1.0.19 → 1.0.20

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.
@@ -387,6 +387,17 @@ function downloadServerData(url) {
387
387
  resolve(true);
388
388
  });
389
389
  }
390
+ function downloadServerBlobData(url) {
391
+ return new Promise(function(resolve, reject) {
392
+ axios.get(url, {
393
+ responseType: "blob"
394
+ }).then((res) => {
395
+ resolve(res.data);
396
+ }, (error) => {
397
+ resolve(null);
398
+ });
399
+ });
400
+ }
390
401
  function uploadFile(url, file, headers, onUploadProgress, customizedOptions) {
391
402
  headers = headers || {};
392
403
  let formdata = new FormData();
@@ -575,6 +586,7 @@ const AxiosUtils = {
575
586
  downloadExcelData,
576
587
  downloadImageData,
577
588
  downloadServerData,
589
+ downloadServerBlobData,
578
590
  uploadFile,
579
591
  getStaticTextFile,
580
592
  appSessionExit,
@@ -388,6 +388,17 @@
388
388
  resolve(true);
389
389
  });
390
390
  }
391
+ function downloadServerBlobData(url) {
392
+ return new Promise(function(resolve, reject) {
393
+ axios.get(url, {
394
+ responseType: "blob"
395
+ }).then((res) => {
396
+ resolve(res.data);
397
+ }, (error) => {
398
+ resolve(null);
399
+ });
400
+ });
401
+ }
391
402
  function uploadFile(url, file, headers, onUploadProgress, customizedOptions) {
392
403
  headers = headers || {};
393
404
  let formdata = new FormData();
@@ -576,6 +587,7 @@
576
587
  downloadExcelData,
577
588
  downloadImageData,
578
589
  downloadServerData,
590
+ downloadServerBlobData,
579
591
  uploadFile,
580
592
  getStaticTextFile,
581
593
  appSessionExit,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sirius-common-utils",
3
- "version": "1.0.19",
3
+ "version": "1.0.20",
4
4
  "description": "",
5
5
  "main": "./dist/sirius-common-utils.umd.cjs",
6
6
  "module": "./dist/sirius-common-utils.js",