Fix worker status polling init/interval and repair describe script syntax

This commit is contained in:
hbrain 2026-05-31 19:26:25 +02:00
parent 8a91cec6c3
commit 85419507cf
2 changed files with 6 additions and 6 deletions

View file

@ -1368,7 +1368,7 @@ function applySwitchPayload(payload){
}
</script>
<script>
(function(){
document.addEventListener('DOMContentLoaded', function(){
const box=document.getElementById('job-status');
if(!box) return;
function fmt(job){
@ -1434,8 +1434,8 @@ function applySwitchPayload(payload){
}
}
updateJobs();
setInterval(updateJobs,30000);
})();
setInterval(updateJobs,32000);
});
</script></main>
<footer>Input dirs are saved under <code>in-dir/</code>.</footer>
<footer class="site-footer admin-footer"><div class="admin-left"><nav class="tabs"><a class="<?= $tab==='new'?'active':'' ?>" href="new.php?tab=new">New</a><a class="<?= $tab==='edit'?'active':'' ?>" href="new.php?tab=edit">Edit</a><a class="<?= $tab==='videos'?'active':'' ?>" href="new.php?tab=videos">Videos</a></nav></div><div id="job-status" class="job-status"<?= empty($runningJobs) ? ' hidden' : '' ?>><?php foreach($runningJobs as $job): ?><span class="job-dot"></span><span><?=h(str_replace('_', ' ', $job['name']))?></span><?php if(!empty($job['started_at'])): ?><span class="job-age">(<?=h(format_job_age($job['started_at']))?>)</span><?php endif; ?><?php endforeach; ?></div><div class="admin-right"><a class="logout-link" href="logout.php">Log off</a></div></footer>