X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fsearch%2Fcust_pay_batch.cgi;h=d5fe52ba5553eeeb91a6b02e03a1520c021ebd9c;hb=5499e8e571862b071e1b072a017aba16636ea34b;hp=dde54614347a33b2e49c18c9edfce6341480d84c;hpb=e55892bdf6dc95710a19876087690a9664421215;p=freeside.git diff --git a/httemplate/search/cust_pay_batch.cgi b/httemplate/search/cust_pay_batch.cgi index dde546143..d5fe52ba5 100755 --- a/httemplate/search/cust_pay_batch.cgi +++ b/httemplate/search/cust_pay_batch.cgi @@ -30,10 +30,10 @@ sub { sprintf('%.02f', $_[0]->amount) }, - 'status', + sub { $_[0]->display_status }, 'error_message', ], - 'align' => 'rrrlllcrll', + 'align' => 'rrrlllcrlll', 'links' => [ '', ["${p}view/cust_bill.cgi?", 'invnum'], (["${p}view/cust_main.cgi?", 'custnum']) x 2, @@ -87,7 +87,7 @@ if ( $cgi->param('payby') ) { } if ( not $cgi->param('dcln') ) { - push @search, "cpb.status IS DISTINCT FROM 'Approved'"; + push @search, "cust_pay_batch.status IS DISTINCT FROM 'Approved'"; } my ($beginning, $ending) = FS::UI::Web::parse_beginning_ending($cgi); @@ -105,7 +105,7 @@ push @search, $curuser->agentnums_sql({ table => 'pay_batch', my $search = ' WHERE ' . join(' AND ', @search); -$count_query = 'SELECT COUNT(*) FROM cust_pay_batch AS cpb ' . +$count_query = 'SELECT COUNT(*) FROM cust_pay_batch ' . 'LEFT JOIN cust_main USING ( custnum ) ' . 'LEFT JOIN pay_batch USING ( batchnum )' . $search;