Jafari & Job: Refactored getTotalReceived and getTotalDispensed into a generic method getTotal in genericService