better handling of the case: tableParams.total can be a function

having the control made in the ngTableParams.total function makes custom pager templates creation easier: they not have to deal with the fact .total() returning a function