X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fsearch%2Felements%2Fcust_pay_batch_top.html;h=bf3047769c6ecc0273d9eb41dd6cc266a4c6957d;hb=4c11454b932bb5cc58ad6405949c815beebc3278;hp=ce0ee9ed42e739ec424cb2640c914056499c43af;hpb=db4d8679af26c301cb66f3f3da7f7cd7a3ae4854;p=freeside.git diff --git a/httemplate/search/elements/cust_pay_batch_top.html b/httemplate/search/elements/cust_pay_batch_top.html index ce0ee9ed4..bf3047769 100644 --- a/httemplate/search/elements/cust_pay_batch_top.html +++ b/httemplate/search/elements/cust_pay_batch_top.html @@ -14,7 +14,8 @@ Download batch in format + +<& .select_gateway &> % }

% } # end of download @@ -31,7 +32,8 @@ Download batch in format +Upload in format + % } % else { % } % } % else { -Format % foreach ( keys(%upload_formats) ) { % } + +<& .select_gateway &> % } # if $fixed
@@ -82,6 +86,26 @@ Batch is <% $statustext{$status} %>
<%$count%> payments batched
<%$money_char%><%$total%> total in batch
+<%def .select_gateway> +% if ( $show_gateways ) { + or for gateway +<& /elements/select-table.html, + empty_label => ' ', + field => 'gatewaynum', + table => 'payment_gateway', + name_col => 'label', + value_col => 'gatewaynum', + order_by => 'ORDER BY gatewaynum', + hashref => { + 'gateway_namespace' => 'Business::BatchPayment', + 'disabled' => '', + } +&> +% } + +<%shared> +my $show_gateways = FS::payment_gateway->count("gateway_namespace = 'Business::BatchPayment' AND disabled IS NULL"); + <%init> my %opt = @_; my $pay_batch = $opt{'pay_batch'} or return; @@ -91,11 +115,12 @@ my $payby = $pay_batch->payby; my $status = $pay_batch->status; my $curuser = $FS::CurrentUser::CurrentUser; my $batchnum = $pay_batch->batchnum; - + my $fixed = $conf->config("batch-fixed_format-$payby"); tie my %download_formats, 'Tie::IxHash', ( '' => 'Default batch mode', +'NACHA' => '94 byte NACHA', 'csv-td_canada_trust-merchant_pc_batch' => 'CSV file for TD Canada Trust Merchant PC Batch', 'csv-chase_canada-E-xactBatch' =>