From f56553a3a203eb41765a5ab8b6758399ac306b36 Mon Sep 17 00:00:00 2001 From: "farhan.taghash" Date: Thu, 20 Nov 2025 17:09:58 +0530 Subject: [PATCH 1/3] Adding a more button when adding to the api --- lib/http/public/javascripts/main.js | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/http/public/javascripts/main.js b/lib/http/public/javascripts/main.js index 89f4784d..1c9ac7da 100755 --- a/lib/http/public/javascripts/main.js +++ b/lib/http/public/javascripts/main.js @@ -143,6 +143,7 @@ function show(state) { o('#jobs .job').remove(); o('#menu li a').removeClass('active'); o('#menu li.' + state + ' a').addClass('active'); + to = more; pollForJobs(state, 1000); return false; } From 36b133e99af8c85b90c205535e605843e95ba0a9 Mon Sep 17 00:00:00 2001 From: "farhan.taghash" Date: Thu, 20 Nov 2025 18:06:19 +0530 Subject: [PATCH 2/3] Adding a timer to keep polling for jobs --- lib/http/public/javascripts/main.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/http/public/javascripts/main.js b/lib/http/public/javascripts/main.js index 1c9ac7da..e47a7f96 100755 --- a/lib/http/public/javascripts/main.js +++ b/lib/http/public/javascripts/main.js @@ -120,6 +120,12 @@ function infiniteScroll() { infiniteScroll.bound = false; showLoading(); o(window).unbind('scroll'); + // Immediately poll for jobs with the new 'to' value + if (pollForJobs.timer) { + clearTimeout(pollForJobs.timer); + delete pollForJobs.timer; + } + pollForJobs(active, 1000); } }); } From e53eb6385c42b117f78f97d7d7b7cc38a109a743 Mon Sep 17 00:00:00 2001 From: "farhan.taghash" Date: Thu, 20 Nov 2025 18:14:25 +0530 Subject: [PATCH 3/3] Reverted timer comment --- lib/http/public/javascripts/main.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/http/public/javascripts/main.js b/lib/http/public/javascripts/main.js index e47a7f96..b68edf8c 100755 --- a/lib/http/public/javascripts/main.js +++ b/lib/http/public/javascripts/main.js @@ -121,10 +121,10 @@ function infiniteScroll() { showLoading(); o(window).unbind('scroll'); // Immediately poll for jobs with the new 'to' value - if (pollForJobs.timer) { - clearTimeout(pollForJobs.timer); - delete pollForJobs.timer; - } + // if (pollForJobs.timer) { + // clearTimeout(pollForJobs.timer); + // delete pollForJobs.timer; + // } pollForJobs(active, 1000); } });