' . "\n";
echo '
Perform Bank Deposit
' . "\n";
//pr(compact('tillableAccount', 'depositableAccount'));
echo $form->create(null, array('id' => 'deposit-form',
'url' => array('controller' => 'accounts',
'action' => 'deposit')));
$grid_setup = array();
$grid_setup['hiddengrid'] = true;
foreach ($tillableAccount AS $acct) {
//$acct = $acct['Account'];
echo (' ');
echo ("I have exactly " .
FormatHelper::currency($acct['Account']['stats']['Ledger']['balance']) .
" in " . ($acct['Account']['name'] === 'Cash'
? 'Cash'
: Inflector::pluralize($acct['Account']['name'])) .
" and will be depositing it all." .
"" . "\n");
echo (' ');
$grid_div_id = 'ledger_entries'.$acct['CurrentLedger']['id'].'-list';
echo $this->element('ledger_entries',
array('grid_div_id' => $grid_div_id,
'caption' => ('Items in '.$acct['Account']['name'].' Ledger'),
'ledger_id' => $acct['CurrentLedger']['id'],
'no_account' => true,
'grid_setup' => $grid_setup,
//'account_id' => $acct['Account']['id'],
//'account_type' => $acct['Account']['type'],
//'account_ftype' => 'debit',
));
}
$options = array();
foreach ($depositableAccount AS $acct) {
$options[$acct['Account']['id']] = $acct['Account']['name'];
}
echo $form->input('Deposit.Account.id', array('label' => 'Deposit Account ',
'options' => $options));
echo $form->end('Perform Deposit');
/* End page div */
echo '' . "\n";