summaryrefslogtreecommitdiff
path: root/httemplate/search/cust_bill.html
diff options
context:
space:
mode:
authorcvs2git <cvs2git>2010-11-05 19:05:57 +0000
committercvs2git <cvs2git>2010-11-05 19:05:57 +0000
commitaaf8baf3662e16e9414de236a39f8801a8c41b01 (patch)
tree2cda603e4311b3e80f79b93d9bcce3a7c7c2d053 /httemplate/search/cust_bill.html
parent995a145c931164347683071c95c6754379d36604 (diff)
parent9b2de4257b6a2877434008188e52b8ef71ff339d (diff)
This commit was manufactured by cvs2svn to create branch
'FREESIDE_2_1_BRANCH'.
Diffstat (limited to 'httemplate/search/cust_bill.html')
-rwxr-xr-xhttemplate/search/cust_bill.html12
1 files changed, 10 insertions, 2 deletions
diff --git a/httemplate/search/cust_bill.html b/httemplate/search/cust_bill.html
index 1e9ee8d..cf6ce49 100755
--- a/httemplate/search/cust_bill.html
+++ b/httemplate/search/cust_bill.html
@@ -122,8 +122,16 @@ if ( $cgi->param('invnum') =~ /^\s*(FS-)?(\d+)\s*$/ ) {
$search{'newest_percust'} = 1;
$count_query = "SELECT COUNT(DISTINCT cust_bill.custnum), 'N/A', 'N/A'";
}
-
- my $extra_sql = ' WHERE '. FS::cust_bill->search_sql_where( \%search );
+
+ my $payby_sql = '';
+ $payby_sql = ' AND (' .
+ join(' OR ', map { "cust_main.payby = '$_'" } $cgi->param('payby') ) .
+ ')'
+ if $cgi->param('payby');
+
+ my $extra_sql = ' WHERE '.
+ FS::cust_bill->search_sql_where( \%search ).
+ $payby_sql;
unless ( $count_query ) {
$count_query = 'SELECT COUNT(*), '. join(', ',