diff --git a/public/js/download-manager.js b/public/js/download-manager.js index 3a41763..136ad52 100644 --- a/public/js/download-manager.js +++ b/public/js/download-manager.js @@ -43,12 +43,14 @@ const component = () => { this.loading = false; }); }, - jobAction(action, id) { + jobAction(action, event) { let url = `${base_url}api/admin/mangadex/queue/${action}`; - if (id !== undefined) - url += '?' + $.param({ + if (event) { + const id = event.currentTarget.closest('tr').id.split('-')[1]; + url = `${url}?${$.param({ id: id - }); + })}`; + } console.log(url); $.ajax({ type: 'POST', diff --git a/src/views/download-manager.html.ecr b/src/views/download-manager.html.ecr index 1e53be0..2f25d27 100644 --- a/src/views/download-manager.html.ecr +++ b/src/views/download-manager.html.ecr @@ -51,9 +51,9 @@