X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fsearch%2Felements%2Fcust_pay_or_refund.html;h=c60411107c6f70e4418e9973f91c4857d1f94151;hb=0ad946f751d3a953c8a41eea1d30ad362ba38ace;hp=dc3cb2a994c96e5db9d1ab96e674da0e26be791a;hpb=26004f55ce70242d07fc8de51e24439e783e9e49;p=freeside.git diff --git a/httemplate/search/elements/cust_pay_or_refund.html b/httemplate/search/elements/cust_pay_or_refund.html index dc3cb2a99..c60411107 100755 --- a/httemplate/search/elements/cust_pay_or_refund.html +++ b/httemplate/search/elements/cust_pay_or_refund.html @@ -357,6 +357,15 @@ if ( $cgi->param('magic') ) { $orderby = "LOWER(company || ' ' || last || ' ' || first )"; + } elsif ( $cgi->param('magic') eq 'batchnum' ) { + + $cgi->param('batchnum') =~ /^(\d+)$/ + or die "illegal batchnum: ".$cgi->param('batchnum'); + + push @search, "batchnum = $1"; + + $orderby = "LOWER(company || ' ' || last || ' ' || first )"; + } else { die "unknown search magic: ". $cgi->param('magic'); }