gutterboy Posted September 9, 2014 Report Posted September 9, 2014 I need to get the users total overdue amount - is there a quick way to do this via the API or do I need to use something like the getAll method and do my own calculations? Thanks!
bobwhite Posted September 9, 2014 Report Posted September 9, 2014 I am having the same issue as gutterboy. v3.2 does not apply add any past due amount on invoices like v2.5 did. Someone please help!
Blesta Addons Posted September 9, 2014 Report Posted September 9, 2014 try this $client_id = 1; $currency_code = "USD"; $obj = new stdClass(); Loader::loadModels($obj, array("Invoices")); $amount_due = $obj->Invoices->amountDue($client_id, $currency_code);
Tyson Posted September 9, 2014 Report Posted September 9, 2014 naja7host's method would fetch the total amount due (past due or not). You would need to calculate the total past due via Invoices::getAll if that's all you wanted
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now