1 <b><font size="+1" color="#FF0000">Pending payment </font></b> <% "$info $status ($link)" %>
4 my( $cust_pay_pending, %opt ) = @_;
6 my $conf = new FS::Conf;
8 my $curuser = $FS::CurrentUser::CurrentUser;
10 my $payby = $cust_pay_pending->payby;
13 if ( $payby eq 'CARD' ) {
14 $payinfo = $cust_pay_pending->paymask;
15 } elsif ( $payby eq 'CHEK' ) {
16 my( $account, $aba ) = split('@', $cust_pay_pending->paymask );
17 $payinfo = "ABA $aba, Acct #$account";
19 $payinfo = $cust_pay_pending->payinfo;
22 my $target = "$payby$payinfo";
23 $payby =~ s/^BILL$/Check #/ if $payinfo;
24 $payby =~ s/^CHEK$/Electronic check /;
25 $payby =~ s/^PREP$/Prepaid card /;
26 $payby =~ s/^CARD$/Credit card #/;
27 $payby =~ s/^COMP$/Complimentary by /;
28 $payby =~ s/^CASH$/Cash/;
29 $payby =~ s/^WEST$/Western Union/;
30 $payby =~ s/^MCRD$/Manual credit card/;
32 my $info = $payby ? "($payby$payinfo)" : '';
36 'thirdparty' => 'delete',
37 'pending' => 'complete',
38 'captured' => 'capture',
42 $FS::CurrentUser::CurrentUser->access_right('Edit customer pending payments');
44 my $status = "Status: ".$cust_pay_pending->status;
46 my $action = $statusaction{$cust_pay_pending->status};
49 if ( $action && $edit_pending ) {
50 $link = include('/elements/popup_link.html',
51 'action' => $p. 'edit/cust_pay_pending.html'.
52 '?paypendingnum='. $cust_pay_pending->paypendingnum.
57 'height' => ( $action eq 'delete' ? 480 : 575 ),
58 'actionlabel' => ucfirst($action). ' pending payment',