mirror of
https://gitlab.ub.uni-bielefeld.de/sfb1288inf/nopaque.git
synced 2024-12-25 10:54:18 +00:00
Fix job deletion from job page
This commit is contained in:
parent
a7cbce1eda
commit
17a9338d9f
@ -153,16 +153,16 @@
|
|||||||
let deleteJobRequestElement = document.querySelector('#delete-job-request');
|
let deleteJobRequestElement = document.querySelector('#delete-job-request');
|
||||||
let restartJobRequestElement = document.querySelector('#restart-job-request');
|
let restartJobRequestElement = document.querySelector('#restart-job-request');
|
||||||
deleteJobRequestElement.addEventListener('click', (event) => {
|
deleteJobRequestElement.addEventListener('click', (event) => {
|
||||||
requests.jobs.entity.delete({{ job.hashid|tojson }});
|
nopaque.requests.jobs.entity.delete({{ job.hashid|tojson }});
|
||||||
});
|
});
|
||||||
restartJobRequestElement.addEventListener('click', (event) => {
|
restartJobRequestElement.addEventListener('click', (event) => {
|
||||||
requests.jobs.entity.restart({{ job.hashid|tojson }});
|
nopaque.requests.jobs.entity.restart({{ job.hashid|tojson }});
|
||||||
});
|
});
|
||||||
|
|
||||||
if ({{ current_user.is_administrator()|tojson }}) {
|
if ({{ current_user.is_administrator()|tojson }}) {
|
||||||
let jobLogButtonElement = document.querySelector('#job-log-button');
|
let jobLogButtonElement = document.querySelector('#job-log-button');
|
||||||
jobLogButtonElement.addEventListener('click', (event) => {
|
jobLogButtonElement.addEventListener('click', (event) => {
|
||||||
requests.jobs.entity.log({{ job.hashid|tojson }})
|
nopaque.requests.jobs.entity.log({{ job.hashid|tojson }})
|
||||||
.then(
|
.then(
|
||||||
(response) => {
|
(response) => {
|
||||||
response.json()
|
response.json()
|
||||||
|
Loading…
Reference in New Issue
Block a user