Lines 431-443
function LoadIssuesTable() {
Link Here
|
431 |
"dataSrc": "issued_today", |
431 |
"dataSrc": "issued_today", |
432 |
"startRender": function ( rows, group ) { |
432 |
"startRender": function ( rows, group ) { |
433 |
if ( group ) { |
433 |
if ( group ) { |
434 |
return __("Today's checkouts"); |
434 |
return "<span>" + __("Today's checkouts") + " (<span class='today_count'></span>)</span>"; |
435 |
} else { |
435 |
} else { |
436 |
return __("Previous checkouts"); |
436 |
return "<span>" + __("Previous checkouts") + " (<span class='previous_count'></span>)</span>"; |
437 |
} |
437 |
} |
438 |
} |
438 |
} |
439 |
}, |
439 |
}, |
440 |
"initComplete": function(oSettings, json) { |
440 |
"initComplete": function(oSettings, json) { |
|
|
441 |
|
442 |
let todaysIssuesCount = 0; |
443 |
let previousIssuesCount = 0; |
444 |
|
445 |
json.aaData.forEach( function(issue) { |
446 |
if ( issue.issued_today ) { |
447 |
todaysIssuesCount++; |
448 |
} else { |
449 |
previousIssuesCount++; |
450 |
} |
451 |
}); |
452 |
|
453 |
$('.previous_count').text(previousIssuesCount); |
454 |
$('.today_count').text(todaysIssuesCount); |
455 |
|
441 |
CheckRenewCheckinBoxes(); |
456 |
CheckRenewCheckinBoxes(); |
442 |
|
457 |
|
443 |
// Build a summary of checkouts grouped by itemtype |
458 |
// Build a summary of checkouts grouped by itemtype |
444 |
- |
|
|