Changed the default collected results to be those collected into any account, not just payable ones.

git-svn-id: file:///svn-source/pmgr/branches/invoice_receipt_20090629@342 97e9348a-65ac-dc4b-aefc-98561f571b83
This commit is contained in:
abijah
2009-07-15 08:01:56 +00:00
parent 75ff8a2a40
commit 405e20f37f
2 changed files with 2 additions and 1 deletions

View File

@@ -155,6 +155,7 @@ class AccountsController extends AppController {
$payment_accounts = $this->Account->paymentAccounts();
$payment_accounts[$this->Account->nsfAccountID()] =
$this->Account->name($this->Account->nsfAccountID());
//$payment_accounts[$this->Account->nameToID('Bank')] = 'Bank';
$default_accounts = array_diff_key($payment_accounts,
array($this->Account->concessionAccountID() => 1));
$this->set(compact('payment_accounts', 'default_accounts'));

View File

@@ -217,7 +217,7 @@ class LedgerEntriesController extends AppController {
if (isset($collected_payment_accounts))
$conditions[] = array('MoneyAccount.id' => $collected_payment_accounts);
else
$conditions[] = array('MoneyAccount.payable' => 1);
$conditions[] = array('NOT' => array(array('MoneyAccount.id' => null)));
}
if ($params['action'] === 'ledger') {