make progress visable and only show registration if enabled
This commit is contained in:
parent
b134b19876
commit
ff176028d1
8 changed files with 42 additions and 20 deletions
|
|
@ -13,9 +13,10 @@ window.downloadAll = function () {
|
|||
};
|
||||
const jobId = window.location.pathname.split("/").pop();
|
||||
const main = document.querySelector("main");
|
||||
const progressElem = document.querySelector("progress");
|
||||
let progressElem = document.querySelector("progress");
|
||||
|
||||
const refreshData = () => {
|
||||
// console.log("Refreshing data...", progressElem.value, progressElem.max);
|
||||
if (progressElem.value !== progressElem.max) {
|
||||
fetch(`/progress/${jobId}`, {
|
||||
method: "POST",
|
||||
|
|
@ -28,6 +29,8 @@ const refreshData = () => {
|
|||
|
||||
setTimeout(refreshData, 1000);
|
||||
}
|
||||
|
||||
progressElem = document.querySelector("progress");
|
||||
};
|
||||
|
||||
refreshData();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue