correct getTotal() and getPayTable()