capture B:OP and B:BP failure_status values from payment attempts, #21117
[freeside.git] / httemplate / view / cust_main / payment_history / attempted_batch_payment.html
1 <I><% mt('Payment attempt') |h %> <% $info |h %></I>
2 <%init>
3
4 my( $cust_pay_batch, %opt ) = @_;
5
6 my ($payby,$payinfo) = translate_payinfo($cust_pay_batch);
7 $payby = translate_payby($payby,$payinfo);
8 my $info = $payby ? "($payby$payinfo)" : '';
9
10 my $detail = '';
11 if ( $cust_pay_batch->failure_status ) {
12   $detail = $cust_pay_batch->display_status;
13   $detail .= ' ('.$cust_pay_batch->error_message.')' 
14     if $cust_pay_batch->error_message;
15 } else {
16   $detail = $cust_pay_batch->error_message;
17 }
18 $info .= ': '.$detail if length($detail);
19
20 </%init>