Add daemon for checking finished jobs

This commit is contained in:
Eike Foken
2011-09-15 18:48:58 +02:00
parent 1496c44505
commit 672f1a5186
4 changed files with 35 additions and 7 deletions

View File

@@ -9,6 +9,13 @@ function getNotifications() {
});
}
/**
* Looks for finished jobs.
*/
function jobDaemon() {
$.get(SITE_URL + 'ajax/check_jobs');
}
/**
* Sets a cookie.
*
@@ -121,6 +128,7 @@ $(document).ready(function() {
$('#notifications').hide();
getNotifications();
setInterval('getNotifications()', '5000');
setInterval('jobDaemon()', JOBS_CHECK_INTERVAL * 1000);
/*
* Tables