|
|
|
@ -26,7 +26,7 @@ |
|
|
|
type="primary" |
|
|
|
size="mini" |
|
|
|
:disabled="scope.row.status !== 2" |
|
|
|
@click="handleDownload(scope.row.download_url)" |
|
|
|
@click="handleDownload(scope.row)" |
|
|
|
> |
|
|
|
下载 |
|
|
|
</el-button> |
|
|
|
@ -78,9 +78,14 @@ const exportListAll = async () => { |
|
|
|
}; |
|
|
|
|
|
|
|
// 下载按钮 |
|
|
|
const handleDownload = (downloadUrl) => { |
|
|
|
if (!downloadUrl) return; |
|
|
|
window.open(downloadUrl, '_blank'); |
|
|
|
const handleDownload = (exportdata) => { |
|
|
|
if (!exportdata.download_url) return; |
|
|
|
const link = document.createElement('a'); |
|
|
|
link.href = exportdata.download_url; |
|
|
|
link.style.display = 'none'; |
|
|
|
document.body.appendChild(link); |
|
|
|
link.click(); |
|
|
|
document.body.removeChild(link); |
|
|
|
}; |
|
|
|
|
|
|
|
// 关闭按钮 |
|
|
|
|