//report报告数据导出
export function outReport(params) {
return request({
url: `${report}/report/download?keyWord=${params.keyword}&page=${params.page}&pageSize=${params.pageSize}&endTime=${params.endTime}®ionId=${params.regionId}&shopId=${params.shopId}&startTime=${params.startTime}&testType=${params.testType}&timeType=${params.timeType}&vinEnabled=${params.vinEnabled}`,
method: 'GET',
responseType: 'blob', //excel
})
}
// export 导出设备
exportDevice() {
let params = {
keyWord: this.keyWord,
regionId: this.regionId,
reportTimeType: this.reportTimeType,
versionEnabled: this.versionEnabled,
workShopId: this.workShopId,
}
downLoad(params).then((res) => {
console.log('导出数据', res)
let url = window.URL.createObjectURL(res)
let a = document.createElement('a')
document.body.appendChild(a)
a.href = url
a.download = 'autel-device-template-download'
a.click()
window.URL.revokeObjectURL(url)
})
},
网友评论