v0.0.12: fix download — window.location вместо a.click()
Deploy drhider / validate (push) Waiting to run
Deploy drhider / validate (push) Waiting to run
This commit is contained in:
@@ -257,22 +257,12 @@ async function uploadFiles() {
|
||||
|
||||
function downloadZip() {
|
||||
if (!currentSid) return;
|
||||
const a = document.createElement('a');
|
||||
a.href = '/api/download/' + currentSid;
|
||||
a.download = 'drhider_' + ts() + '.zip';
|
||||
document.body.appendChild(a);
|
||||
a.click();
|
||||
document.body.removeChild(a);
|
||||
window.location = '/api/download/' + currentSid;
|
||||
}
|
||||
|
||||
function downloadCsv() {
|
||||
if (!currentSid) return;
|
||||
const a = document.createElement('a');
|
||||
a.href = '/api/csv/' + currentSid;
|
||||
a.download = 'mapping_' + ts() + '.csv';
|
||||
document.body.appendChild(a);
|
||||
a.click();
|
||||
document.body.removeChild(a);
|
||||
window.location = '/api/csv/' + currentSid;
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
|
||||
Reference in New Issue
Block a user