2020-10-09 22:29:56 +02:00
|
|
|
// Generated by CoffeeScript 1.12.8
|
2017-01-19 12:33:11 +01:00
|
|
|
(function() {
|
|
|
|
var _go, go, i, stop, timer;
|
2014-02-06 17:48:02 +01:00
|
|
|
|
2017-01-19 12:33:11 +01:00
|
|
|
i = 30;
|
2014-02-06 17:48:02 +01:00
|
|
|
|
2017-01-19 12:33:11 +01:00
|
|
|
_go = 1;
|
2014-02-06 17:48:02 +01:00
|
|
|
|
2017-01-19 12:33:11 +01:00
|
|
|
stop = function() {
|
|
|
|
_go = 0;
|
2020-01-15 20:49:14 +01:00
|
|
|
$('#divToHide').hide();
|
|
|
|
return $('#wait').hide();
|
2017-01-19 12:33:11 +01:00
|
|
|
};
|
2014-02-06 17:48:02 +01:00
|
|
|
|
2017-01-19 12:33:11 +01:00
|
|
|
go = function() {
|
|
|
|
if (_go) {
|
|
|
|
return $("#form").submit();
|
|
|
|
}
|
|
|
|
};
|
2014-02-06 17:48:02 +01:00
|
|
|
|
2017-01-19 12:33:11 +01:00
|
|
|
timer = function() {
|
|
|
|
var h;
|
|
|
|
h = $('#timer').html();
|
|
|
|
if (i > 0) {
|
|
|
|
i--;
|
|
|
|
}
|
|
|
|
h = h.replace(/\d+/, i);
|
|
|
|
$('#timer').html(h);
|
|
|
|
return window.setTimeout(timer, 1000);
|
|
|
|
};
|
|
|
|
|
2020-01-15 20:49:14 +01:00
|
|
|
$(window).on('load', function() {
|
2017-01-19 12:33:11 +01:00
|
|
|
if (window.datas['activeTimer']) {
|
2017-03-16 21:19:06 +01:00
|
|
|
window.setTimeout(go, 30000);
|
2017-01-19 22:48:07 +01:00
|
|
|
window.setTimeout(timer, 1000);
|
2017-01-19 12:33:11 +01:00
|
|
|
} else {
|
2017-01-19 22:48:07 +01:00
|
|
|
stop;
|
2017-01-19 12:33:11 +01:00
|
|
|
}
|
2017-01-19 22:48:07 +01:00
|
|
|
return $("#wait").on('click', function() {
|
|
|
|
return stop();
|
|
|
|
});
|
2017-01-19 12:33:11 +01:00
|
|
|
});
|
|
|
|
|
|
|
|
}).call(this);
|