summaryrefslogtreecommitdiff
path: root/httemplate/search
diff options
context:
space:
mode:
authorMark Wells <mark@freeside.biz>2012-08-02 15:54:31 -0700
committerMark Wells <mark@freeside.biz>2012-08-02 15:54:31 -0700
commit0f2d1070bc6f1521ab50dd07e475587f1117eec6 (patch)
tree61accbd6ccf848b815bbcd17fa138e9f8f1896ac /httemplate/search
parent7404ff9d5df7679054dd73f17b3737f5474e5512 (diff)
sales by ad source report: filter by ad source, #17971
Diffstat (limited to 'httemplate/search')
-rw-r--r--httemplate/search/cust_bill_pkg_referral.html10
-rw-r--r--httemplate/search/report_cust_bill_pkg_referral.html5
2 files changed, 15 insertions, 0 deletions
diff --git a/httemplate/search/cust_bill_pkg_referral.html b/httemplate/search/cust_bill_pkg_referral.html
index 3cb434caa..77b486021 100644
--- a/httemplate/search/cust_bill_pkg_referral.html
+++ b/httemplate/search/cust_bill_pkg_referral.html
@@ -146,6 +146,16 @@ if ( @status_where ) {
') IN (' . join(',', @status_where) .')';
}
+my @refnum;
+foreach my $refnum ($cgi->param('refnum')) {
+ if ( $refnum =~ /^\d+$/ ) {
+ push @refnum, $refnum;
+ }
+}
+if ( @refnum ) {
+ push @where, 'cust_main.refnum IN ('.join(',', @refnum).')';
+}
+
if ( $cgi->param('agentnum') =~ /^(\d+)$/ ) {
push @where, "cust_main.agentnum = $1";
}
diff --git a/httemplate/search/report_cust_bill_pkg_referral.html b/httemplate/search/report_cust_bill_pkg_referral.html
index ff2caa1fa..b4716d4fc 100644
--- a/httemplate/search/report_cust_bill_pkg_referral.html
+++ b/httemplate/search/report_cust_bill_pkg_referral.html
@@ -18,6 +18,11 @@
'disable_empty' => 1,
&>
+<& /elements/tr-select-part_referral.html,
+ 'multiple' => 1,
+ 'disable_empty' => 1,
+&>
+
<& /elements/tr-select-pkg_class.html,
'pre_options' => [ '' => 'all', '0' => '(empty class)' ],
'disable_empty' => 1,