Got the bank deposit working well.

git-svn-id: file:///svn-source/pmgr/branches/invoice_receipt_20090629@198 97e9348a-65ac-dc4b-aefc-98561f571b83
This commit is contained in:
abijah
2009-07-02 07:41:18 +00:00
parent 3ad0cc1d20
commit 63b2e7360b
5 changed files with 203 additions and 69 deletions

View File

@@ -19,14 +19,20 @@ class FormatHelper extends AppHelper {
true));
}
function currency($amount) {
function currency($amount, $spans = false) {
if (!isset($amount))
return '-';
//return null;
return (isset($amount)
? self::$number->currency($amount)
: null);
$currency = self::$number->currency($amount,
'USD',
$spans ? array('before'=>'', 'after'=>'') : array());
if ($spans)
return ('<SPAN CLASS="dollar-sign">$</SPAN>' .
'<SPAN CLASS="dollar-amount">' . $currency . '</SPAN>');
return $currency;
}
function date($date, $age = false) {