edit
This commit is contained in:
		@ -189,7 +189,6 @@ export class OrderManagementService extends ShipperBaseService {
 | 
			
		||||
  //  查询异常预警表
 | 
			
		||||
  $api_get_abnormalWarning = `/api/sdc/abnormalWarning/list/page`;
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
  //  异步导出运营后台大宗订单列表
 | 
			
		||||
  $api_get_asyncExportBulkList = `/api/sdc/billOperate/asyncExportBulkList`;
 | 
			
		||||
  //  异步导出运营后台整车订单列表
 | 
			
		||||
@ -248,21 +247,22 @@ export class OrderManagementService extends ShipperBaseService {
 | 
			
		||||
    if (!url) {
 | 
			
		||||
      return;
 | 
			
		||||
    }
 | 
			
		||||
    const uA = window.navigator.userAgent; // 判断浏览器内核
 | 
			
		||||
    const isIE =
 | 
			
		||||
      /msie\s|trident\/|edge\//i.test(uA) &&
 | 
			
		||||
      !!('uniqueID' in document || 'documentMode' in document || 'ActiveXObject' in window || 'MSInputMethodContext' in window);
 | 
			
		||||
    const objectUrl = url;
 | 
			
		||||
    const a = document.createElement('a');
 | 
			
		||||
    document.body.appendChild(a);
 | 
			
		||||
    a.href = objectUrl;
 | 
			
		||||
    a.download = '附件.pdf';
 | 
			
		||||
    if (isIE) {
 | 
			
		||||
      // 兼容IE11无法触发下载的问题
 | 
			
		||||
      (navigator as any).msSaveBlob(url, a.download);
 | 
			
		||||
    } else {
 | 
			
		||||
      a.click();
 | 
			
		||||
    }
 | 
			
		||||
    a.remove();
 | 
			
		||||
    this.openURL(url);
 | 
			
		||||
    // const uA = window.navigator.userAgent; // 判断浏览器内核
 | 
			
		||||
    // const isIE =
 | 
			
		||||
    //   /msie\s|trident\/|edge\//i.test(uA) &&
 | 
			
		||||
    //   !!('uniqueID' in document || 'documentMode' in document || 'ActiveXObject' in window || 'MSInputMethodContext' in window);
 | 
			
		||||
    // const objectUrl = url;
 | 
			
		||||
    // const a = document.createElement('a');
 | 
			
		||||
    // document.body.appendChild(a);
 | 
			
		||||
    // a.href = objectUrl;
 | 
			
		||||
    // a.download = '附件.pdf';
 | 
			
		||||
    // if (isIE) {
 | 
			
		||||
    //   // 兼容IE11无法触发下载的问题
 | 
			
		||||
    //   (navigator as any).msSaveBlob(url, a.download);
 | 
			
		||||
    // } else {
 | 
			
		||||
    //   a.click();
 | 
			
		||||
    // }
 | 
			
		||||
    // a.remove();
 | 
			
		||||
  }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user