summaryrefslogtreecommitdiff
path: root/httemplate/graph
diff options
context:
space:
mode:
authorC.J. Adams-Collier <cjac@colliertech.org>2014-09-08 14:14:20 -0700
committerC.J. Adams-Collier <cjac@colliertech.org>2014-09-08 14:14:20 -0700
commitc9860506278274605e76c1a8c18084db134d7409 (patch)
tree00b9ec49d51e0618965e0808408e38c766aa0d85 /httemplate/graph
parentb853ec09fb19df91fe0188c5dde9d759333a2503 (diff)
moved WHERE/AND logic in to calling code. FS RT #884
Diffstat (limited to 'httemplate/graph')
-rw-r--r--httemplate/graph/signupdate.cgi5
1 files changed, 3 insertions, 2 deletions
diff --git a/httemplate/graph/signupdate.cgi b/httemplate/graph/signupdate.cgi
index 011817c3a..8261257f3 100644
--- a/httemplate/graph/signupdate.cgi
+++ b/httemplate/graph/signupdate.cgi
@@ -43,8 +43,9 @@ my $edate = DateTime->new(
month => $cgi->param('end_month')
)->add( months => 1 )->epoch();
-my $where .= " AND signupdate >= $sdate ".
- " AND signupdate < $edate ";
+my $where = (%where ? ' AND ' : ' WHERE ');
+$where .= " signupdate >= $sdate ".
+ " AND signupdate < $edate ";
foreach my $cust (qsearch({ table => 'cust_main',
hashref => \%where,