Minor work on ADSL/Domain/Hosting and other minor fixes

This commit is contained in:
Deon George
2011-10-11 10:38:21 +11:00
parent 0f45467ec8
commit 50a096e22a
12 changed files with 110 additions and 28 deletions

View File

@@ -163,5 +163,19 @@ class Model_Service extends ORMOSB {
return $result;
}
/**
* List services that need to be billed.
*/
public function list_invoicesoon() {
$result = array();
foreach ($this->list_active() as $so)
// @todo This should be configurable
if (! $so->suspend_billing AND $so->date_next_invoice < time()+35*86400)
array_push($result,$so);
return $result;
}
}
?>