Consistent use of return , payment refund handling
This commit is contained in:
@@ -22,7 +22,7 @@ class Controller_Admin_Statement extends Controller_TemplateDefault_Admin {
|
||||
$ta = array();
|
||||
|
||||
foreach ($ao->payment->find_all() as $o) {
|
||||
if (round($o->total_amt-$o->refund_status,0) == 0)
|
||||
if ( ! $o->total())
|
||||
continue;
|
||||
|
||||
$i = count($ta);
|
||||
@@ -49,7 +49,7 @@ class Controller_Admin_Statement extends Controller_TemplateDefault_Admin {
|
||||
if (isset($v['invoice']))
|
||||
$t += $v['invoice']->total();
|
||||
elseif (isset($v['payment']))
|
||||
$t -= $v['payment']->total_amt-$v['payment']->refund_status;
|
||||
$t -= $v['payment']->total();
|
||||
|
||||
$ta[$k]['total'] = $t;
|
||||
$a = $v['time'];
|
||||
|
Reference in New Issue
Block a user