checkTasks() also checks documents to receipt and revise

This commit is contained in:
Uwe Steinmann 2015-07-09 18:29:08 +02:00
parent f25c090039
commit 7a601a1cd0

View File

@ -696,14 +696,18 @@ $(document).ready(function() {
});
var approval_count, review_count;
var approval_count, review_count, receipt_count, revision_count;
var checkTasks = function() {
$.get('../op/op.Ajax.php', { command: 'mytasks' }, function(data) {
if(approval_count != data.data.approval.length ||
review_count != data.data.review.length) {
review_count != data.data.review.length ||
receipt_count != data.data.receipt.length ||
revision_count != data.data.revision.length) {
$("#menu-tasks > ul > li").html('Loading').hide().load('../op/op.Ajax.php?command=view&view=menutasks').fadeIn('500')
approval_count = data.data.approval.length;
review_count = data.data.review.length;
receipt_count = data.data.receipt.length;
revision_count = data.data.revision.length;
}
}, 'json');
timeOutId = setTimeout(checkTasks, 10000);