X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=httemplate%2Fsearch%2Fcust_pay_pending.html;h=697bdbbf0f8ed3063c70f4fa224ce98c33185b96;hp=f46e08ab14a805521706c1550fcad702c949a54e;hb=f822e27a1e00594332ffa487a1c284234c5580a6;hpb=624b2d44625f69d71175c3348cae635d580c890b diff --git a/httemplate/search/cust_pay_pending.html b/httemplate/search/cust_pay_pending.html index f46e08ab1..697bdbbf0 100755 --- a/httemplate/search/cust_pay_pending.html +++ b/httemplate/search/cust_pay_pending.html @@ -1,25 +1,24 @@ -<% include( 'elements/cust_pay_or_refund.html', +<& elements/cust_pay_or_refund.html, 'thing' => 'pay_pending', 'amount_field' => 'paid', 'name_singular' => 'pending payment', 'name_verb' => 'pending', 'disable_link' => 1, 'disable_by' => 1, #add otaker to cust_pay_pending? - 'html_init' => include('/elements/init_overlib.html'), 'addl_header' => [ 'Time', 'Payment Status', ], 'addl_fields' => [ sub { time2str('%r', shift->_date ) }, $status_sub, ], + 'addl_sort_fields' => [ 'status' ], 'redirect_empty' => $redirect_empty, - ) -%> +&> <%init> my %statusaction = ( 'new' => 'delete', 'pending' => 'complete', - #'authorized' => '', - #'captured' => '', + 'authorized' => 'complete', + 'captured' => 'capture', #'declined' => '', #wouldn't need to take action on a done state#'done' ); @@ -30,6 +29,9 @@ my $edit_pending = my $status_sub = sub { my $pending = shift; my $return = $pending->status; + if ( $pending->failure_status ) { + $return = $pending->display_status; + } my $action = $statusaction{$pending->status}; return $return unless $action && $edit_pending; my $link = include('/elements/popup_link.html',