aggregate functions in footer
| Total users:{{$filtered.length}} | Total balance:{{ $owner.getTotalBalance($filtered) }} $ | |
| {{::item.name}} | {{::item.age}} | {{item.money}} |
money columnvariable $filtered contains displayed array (It depends on the filters like search or your custom filters);
If you want to apply your aggregate function for all data array despite filters, please use getTotalBalance(data). In this case returned of function value won't be changed during search.
The <tfoot> tag must be used in the following context: As a child of a <table> element, after any <caption>, <colgroup>, and <thead> elements and before any <tbody> and <tr> elements.
getTotalBalance in controller: