Merge branch 'dev' of github.com:jetlinks/jetlinks-ui-vue into dev
This commit is contained in:
commit
d3bdbe8909
|
@ -97,7 +97,7 @@ export const _import = (configId: any, params: any) => server.get(`/network/card
|
|||
* @param format 类型 xlsx、csv
|
||||
* @param params
|
||||
*/
|
||||
export const _export = (format: string, data: any) => server.post(`/network/card/download.${format}/_query`, data, 'blob');
|
||||
export const _export = (format: string, data: any) => server.post(`/network/card/download.${format}/_query`, data, { responseType: 'blob' });
|
||||
|
||||
/**
|
||||
* 验证iccid
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<page-container
|
||||
:tabList="list"
|
||||
@back="onBack"
|
||||
:tabActiveKey="productStore.active"
|
||||
:tabActiveKey="productStore.tabActiveKey"
|
||||
@tabChange="onTabChange"
|
||||
>
|
||||
<template #title>
|
||||
|
|
|
@ -45,8 +45,9 @@ const handleOk = () => {
|
|||
console.log(props.data);
|
||||
_export(type.value, props.data).then((res: any) => {
|
||||
if (res) {
|
||||
const blob = new Blob([res.data], { type: type.value });
|
||||
const blob = new Blob([res], { type: type.value });
|
||||
const url = URL.createObjectURL(blob);
|
||||
console.log(url);
|
||||
downloadFileByUrl(
|
||||
url,
|
||||
`物联卡管理-${moment(new Date()).format(
|
||||
|
|
Loading…
Reference in New Issue