X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fsearch%2Fcust_credit.html;h=c52394a5b6b3122407ba62d3e753f05399042518;hb=39fd666a49b2be516967131a46891f17ce0101da;hp=80cfc45852f8bd2df388e6ebcc24a690c8f10704;hpb=3ce7691203a7737406bf2d4442f7fd84b81f847e;p=freeside.git 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;