- %><%
-
-}elsif ($format eq "PAP"){
-
- my($origid,$datacenter,$typecode,$shortname,$longname,$mybank,$myacct) =
- $conf->config("batchconfig-$format");
- %><%= sprintf( "H%10sD%3s%06u%-15s%09u%-12s%04u%19s\n",$origid,$typecode,$cdate,$shortname,$mybank,$myacct,$pay_batch->batchnum,"")
-
- %><%
-
-}elsif ($format eq "csv-td_canada_trust-merchant_pc_batch"){
-# 1;
-}else{
- die "Unknown format for batch in batchconfig. \n";
-}
-
-
-for my $cust_pay_batch ( sort { $a->paybatchnum <=> $b->paybatchnum }
- qsearch('cust_pay_batch',
- {'batchnum'=>$pay_batch->batchnum} )
-) {
-
- $cust_pay_batch->exp =~ /^\d{2}(\d{2})[\/\-](\d+)[\/\-]\d+$/;
- my( $mon, $y ) = ( $2, $1 );
- $mon = "0$mon" if $mon < 10;
- my $exp = "$mon$y";
- $batchcount++;
- $batchtotal += $cust_pay_batch->amount;
-
- if ($format eq "BoM") {
-
- my( $account, $aba ) = split( '@', $cust_pay_batch->payinfo );
- %><%= sprintf( "D%010.0f%09u%-12s%-29s%-19s\n",$cust_pay_batch->amount*100,$aba,$account,$cust_pay_batch->payname,$cust_pay_batch->paybatchnum) %><%
-
- } elsif ($format eq "PAP"){
-
- my( $account, $aba ) = split( '@', $cust_pay_batch->payinfo );
- %><%= sprintf( "D%-23s%06u%-19s%09u%-12s%010.0f\n",$cust_pay_batch->payname,$cdate,$cust_pay_batch->paybatchnum,$aba,$account,$cust_pay_batch->amount*100) %><%
-
- } elsif ($format eq "csv-td_canada_trust-merchant_pc_batch") {
-
- %>,,,,<%= $cust_pay_batch->payinfo %>,<%= $exp %>,<%= $cust_pay_batch->amount %>,<%= $cust_pay_batch->paybatchnum %><%
-
- } else {
- die "I'm already dead, but you did not know that.\n";
- }
-
-}
-
-if ($format eq "BoM") {
-
- %><%= sprintf( "YD%08u%014.0f%56s\n",$batchcount,$batchtotal*100,"" ).
- sprintf( "Z%014u%05u%014u%05u%41s\n",$batchtotal*100,$batchcount,"0","0","" ) %><%
-
-} elsif ($format eq "PAP"){
-
- %><%= sprintf( "T%08u%014.0f%57s\n",$batchcount,$batchtotal*100,"" ) %><%
-
-} elsif ($format eq "csv-td_canada_trust-merchant_pc_batch"){
- #1;
-} else {
- die "I'm already dead (again), but you did not know that.\n";
-}
-
-$dbh->commit or die $dbh->errstr if $oldAutoCommit;
+ %>
+%
+%
+%}elsif ($format eq "PAP"){
+%
+% my($origid,$datacenter,$typecode,$shortname,$longname,$mybank,$myacct) =
+% $conf->config("batchconfig-$format");
+%
+<% sprintf( "H%10sD%3s%06u%-15s%09u%-12s%04u%19s\n",$origid,$typecode,$cdate,$shortname,$mybank,$myacct,$pay_batch->batchnum,"")
+
+ %>
+%
+%
+%}elsif ($format eq "csv-td_canada_trust-merchant_pc_batch"){
+%# 1;
+%}else{
+% die "Unknown format for batch in batchconfig. \n";
+%}
+%
+%
+%for my $cust_pay_batch ( sort { $a->paybatchnum <=> $b->paybatchnum }
+% qsearch('cust_pay_batch',
+% {'batchnum'=>$pay_batch->batchnum} )
+%) {
+%
+% $cust_pay_batch->exp =~ /^\d{2}(\d{2})[\/\-](\d+)[\/\-]\d+$/;
+% my( $mon, $y ) = ( $2, $1 );
+% $mon = "0$mon" if $mon < 10;
+% my $exp = "$mon$y";
+% $batchcount++;
+% $batchtotal += $cust_pay_batch->amount;
+%
+% if ($format eq "BoM") {
+%
+% my( $account, $aba ) = split( '@', $cust_pay_batch->payinfo );
+%
+<% sprintf( "D%010.0f%09u%-12s%-29s%-19s\n",$cust_pay_batch->amount*100,$aba,$account,$cust_pay_batch->payname,$cust_pay_batch->paybatchnum) %>
+%
+%
+% } elsif ($format eq "PAP"){
+%
+% my( $account, $aba ) = split( '@', $cust_pay_batch->payinfo );
+%
+<% sprintf( "D%-23s%06u%-19s%09u%-12s%010.0f\n",$cust_pay_batch->payname,$cdate,$cust_pay_batch->paybatchnum,$aba,$account,$cust_pay_batch->amount*100) %>
+%
+%
+% } elsif ($format eq "csv-td_canada_trust-merchant_pc_batch") {
+%
+%
+,,,,<% $cust_pay_batch->payinfo %>,<% $exp %>,<% $cust_pay_batch->amount %>,<% $cust_pay_batch->paybatchnum %>
+%
+%
+% } else {
+% die "I'm already dead, but you did not know that.\n";
+% }
+%
+%}
+%
+%if ($format eq "BoM") {
+%
+%
+<% sprintf( "YD%08u%014.0f%56s\n",$batchcount,$batchtotal*100,"" ).
+ sprintf( "Z%014u%05u%014u%05u%41s\n",$batchtotal*100,$batchcount,"0","0","" ) %>
+%
+%
+%} elsif ($format eq "PAP"){
+%
+%
+<% sprintf( "T%08u%014.0f%57s\n",$batchcount,$batchtotal*100,"" ) %>
+%
+%
+%} elsif ($format eq "csv-td_canada_trust-merchant_pc_batch"){
+% #1;
+%} else {
+% die "I'm already dead (again), but you did not know that.\n";
+%}
+%
+%$dbh->commit or die $dbh->errstr if $oldAutoCommit;
+%
+%