forked from hummypkg/webif
Delay refresh on UI interaction
This commit is contained in:
parent
00e8a342c0
commit
a587278586
@ -103,6 +103,8 @@ function load()
|
||||
|
||||
$(function() {
|
||||
|
||||
var loader=0;
|
||||
|
||||
$('table')
|
||||
.tablesorter({
|
||||
sortList: [[0,1]],
|
||||
@ -198,7 +200,16 @@ $('#queuetab').on('click', 'a.file', function(e) {
|
||||
encodeURIComponent('{root}/' + dirname(file));
|
||||
});
|
||||
|
||||
setInterval(load, 60000);
|
||||
function set_loader() {
|
||||
if (loader != 0)
|
||||
clearInterval(loader);
|
||||
|
||||
loader=setInterval(load, 60000);
|
||||
}
|
||||
|
||||
$('#queuetab').on('change', 'input[type=checkbox]', set_loader);
|
||||
|
||||
set_loader();
|
||||
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user