summaryrefslogtreecommitdiff
path: root/httemplate/search/cust_credit.html
diff options
context:
space:
mode:
authorivan <ivan>2006-11-24 08:49:09 +0000
committerivan <ivan>2006-11-24 08:49:09 +0000
commit39fd666a49b2be516967131a46891f17ce0101da (patch)
treee5e3ead6d6943990466724c3c6bc4b224fdb5a79 /httemplate/search/cust_credit.html
parent5f6615875ca497d46c4f8cd810310d4b2db24bfd (diff)
add less than and greater than amounts to credit and payment searches
Diffstat (limited to 'httemplate/search/cust_credit.html')
-rwxr-xr-xhttemplate/search/cust_credit.html23
1 files changed, 4 insertions, 19 deletions
diff --git a/httemplate/search/cust_credit.html b/httemplate/search/cust_credit.html
index 80cfc4585..c52394a5b 100755
--- a/httemplate/search/cust_credit.html
+++ b/httemplate/search/cust_credit.html
@@ -15,26 +15,11 @@
% $title = $agent->agent. " $title";
% }
%
-% #false laziness with cust_pkg.cgi and cust_pay.cgi
-% if ( $cgi->param('beginning')
-% && $cgi->param('beginning') =~ /^([ 0-9\-\/]{1,10})$/ ) {
-% my $beginning = str2time($1);
-% push @search, "_date >= $beginning ";
-% }
-% if ( $cgi->param('ending')
-% && $cgi->param('ending') =~ /^([ 0-9\-\/]{1,10})$/ ) {
-% my $ending = str2time($1) + 86399;
-% push @search, " _date <= $ending ";
-% }
+% my($beginning, $ending) = FS::UI::Web::parse_beginning_ending($cgi);
+% push @search, "_date >= $beginning ",
+% "_date <= $ending";
%
-% if ( $cgi->param('begin')
-% && $cgi->param('begin') =~ /^(\d+)$/ ) {
-% push @search, "_date >= $1 ";
-% }
-% if ( $cgi->param('end')
-% && $cgi->param('end') =~ /^(\d+)$/ ) {
-% push @search, " _date < $1 ";
-% }
+% push @search, FS::UI::Web::parse_lt_gt($cgi, 'amount' );
%
% #here is the agent virtualization
% push @search, $FS::CurrentUser::CurrentUser->agentnums_sql;