Nowhere near done yet, but checking in a snapshot of semi-working code. There is some simultaneous support for both with and without use of the Invoice/Receipt account. I want to do away with them completely, but will need to change how sitelink payments are mapped (right now, they split a payment into multiple parts to match the charge).

git-svn-id: file:///svn-source/pmgr/branches/single_AR_20090622@181 97e9348a-65ac-dc4b-aefc-98561f571b83
This commit is contained in:
abijah
2009-06-23 19:04:41 +00:00
parent 7aa1100cac
commit 80f8bd36d5
18 changed files with 502 additions and 409 deletions

View File

@@ -121,7 +121,7 @@ class UnitsController extends AppController {
// Get the balance on each lease.
foreach ($unit['Lease'] AS &$lease) {
$stats = $this->Unit->Lease->stats($lease['id']);
$lease['balance'] = $stats['Account']['Ledger']['balance'];
$lease['balance'] = $stats['balance'];
}
$outstanding_balance = 0;
@@ -130,7 +130,7 @@ class UnitsController extends AppController {
// Figure out the outstanding balance of the current lease.
$stats = $this->Unit->stats($id);
$outstanding_balance =
$stats['CurrentLease']['Account']['Ledger']['balance'];
$stats['CurrentLease']['balance'];
// Figure out the total security deposit for the current lease.
$deposits = $this->Unit->Lease->findSecurityDeposits($unit['CurrentLease']['id']);