diff options
author | Ivan Kohler <ivan@freeside.biz> | 2016-12-22 16:01:11 -0800 |
---|---|---|
committer | Ivan Kohler <ivan@freeside.biz> | 2016-12-22 16:01:11 -0800 |
commit | a953abfe224ff0fbdefbec6672daf12efff3ee65 (patch) | |
tree | a700041f22de601127905b472d894f1b763bc86d | |
parent | 6d1586037b5b12a7b8097750372241aba18c730c (diff) |
package search on null dates, RT#73715
-rwxr-xr-x | httemplate/misc/bulk_change_pkg.cgi | 28 | ||||
-rwxr-xr-x | httemplate/misc/bulk_pkg_increment_bill.cgi | 28 | ||||
-rwxr-xr-x | httemplate/misc/process/bulk_change_pkg.cgi | 2 | ||||
-rwxr-xr-x | httemplate/misc/process/bulk_pkg_increment_bill.cgi | 2 |
4 files changed, 46 insertions, 14 deletions
diff --git a/httemplate/misc/bulk_change_pkg.cgi b/httemplate/misc/bulk_change_pkg.cgi index 4964e59..6ed272f 100755 --- a/httemplate/misc/bulk_change_pkg.cgi +++ b/httemplate/misc/bulk_change_pkg.cgi @@ -10,16 +10,32 @@ %# some false laziness w/search/cust_pkg.cgi <INPUT TYPE="hidden" NAME="query" VALUE="<% $cgi->keywords |h %>"> -% for my $param (qw(agentnum custnum magic status classnum custom censustract)) { -<INPUT TYPE="hidden" NAME="<% $param %>" VALUE="<% $cgi->param($param) |h %>"> -% } +% for my $param ( +% qw( +% agentnum cust_status cust_main_salesnum salesnum custnum magic status +% custom pkgbatch zip +% 477part 477rownum date +% report_option +% ), +% grep { /^location_\w+$/ || /^report_option_any/ } $cgi->param +% ) { + <INPUT TYPE="hidden" NAME="<% $param %>" VALUE="<% $cgi->param($param) |h %>"> +% } +% +% for my $param (qw( censustract censustract2 ) ) { +% next unless grep { $_ eq $param } $cgi->param; + <INPUT TYPE="hidden" NAME="<% $param %>" VALUE="<% $cgi->param($param) |h %>"> +% } % -% foreach my $pkgpart ($cgi->param('pkgpart')) { -<INPUT TYPE="hidden" NAME="pkgpart" VALUE="<% $pkgpart |h %>"> +% for my $param (qw( pkgpart classnum refnum towernum )) { +% foreach my $value ($cgi->param($param)) { + <INPUT TYPE="hidden" NAME="<% $param %>" VALUE="<% $value |h %>"> +% } % } % -% foreach my $field (qw( setup last_bill bill adjourn susp expire cancel )) { +% foreach my $field (qw( setup last_bill bill adjourn susp expire contract_end change_date cancel active )) { % + <INPUT TYPE="hidden" NAME="<% $field %>_null" VALUE="<% $cgi->param("${field}_null") |h %>"> <INPUT TYPE="hidden" NAME="<% $field %>begin" VALUE="<% $cgi->param("${field}.begin") |h %>"> <INPUT TYPE="hidden" NAME="<% $field %>beginning" VALUE="<% $cgi->param("${field}beginning") |h %>"> <INPUT TYPE="hidden" NAME="<% $field %>end" VALUE="<% $cgi->param("${field}.end") |h %>"> diff --git a/httemplate/misc/bulk_pkg_increment_bill.cgi b/httemplate/misc/bulk_pkg_increment_bill.cgi index d594b55..fc9bbc8 100755 --- a/httemplate/misc/bulk_pkg_increment_bill.cgi +++ b/httemplate/misc/bulk_pkg_increment_bill.cgi @@ -10,16 +10,32 @@ %# some false laziness w/search/cust_pkg.cgi <INPUT TYPE="hidden" NAME="query" VALUE="<% $cgi->keywords |h %>"> -% for my $param (qw(agentnum custnum magic status classnum custom censustract)) { -<INPUT TYPE="hidden" NAME="<% $param %>" VALUE="<% $cgi->param($param) |h %>"> -% } +% for my $param ( +% qw( +% agentnum cust_status cust_main_salesnum salesnum custnum magic status +% custom pkgbatch zip +% 477part 477rownum date +% report_option +% ), +% grep { /^location_\w+$/ || /^report_option_any/ } $cgi->param +% ) { + <INPUT TYPE="hidden" NAME="<% $param %>" VALUE="<% $cgi->param($param) |h %>"> +% } +% +% for my $param (qw( censustract censustract2 ) ) { +% next unless grep { $_ eq $param } $cgi->param; + <INPUT TYPE="hidden" NAME="<% $param %>" VALUE="<% $cgi->param($param) |h %>"> +% } % -% foreach my $pkgpart ($cgi->param('pkgpart')) { -<INPUT TYPE="hidden" NAME="pkgpart" VALUE="<% $pkgpart |h %>"> +% for my $param (qw( pkgpart classnum refnum towernum )) { +% foreach my $value ($cgi->param($param)) { + <INPUT TYPE="hidden" NAME="<% $param %>" VALUE="<% $value |h %>"> +% } % } % -% foreach my $field (qw( setup last_bill bill adjourn susp expire cancel )) { +% foreach my $field (qw( setup last_bill bill adjourn susp expire contract_end change_date cancel active )) { % + <INPUT TYPE="hidden" NAME="<% $field %>_null" VALUE="<% $cgi->param("${field}_null") |h %>"> <INPUT TYPE="hidden" NAME="<% $field %>begin" VALUE="<% $cgi->param("${field}.begin") |h %>"> <INPUT TYPE="hidden" NAME="<% $field %>beginning" VALUE="<% $cgi->param("${field}beginning") |h %>"> <INPUT TYPE="hidden" NAME="<% $field %>end" VALUE="<% $cgi->param("${field}.end") |h %>"> diff --git a/httemplate/misc/process/bulk_change_pkg.cgi b/httemplate/misc/process/bulk_change_pkg.cgi index e22dafe..469ae7c 100755 --- a/httemplate/misc/process/bulk_change_pkg.cgi +++ b/httemplate/misc/process/bulk_change_pkg.cgi @@ -30,7 +30,7 @@ my %disable = ( '' => {}, ); -foreach my $field (qw( setup last_bill bill adjourn susp expire cancel )) { +foreach my $field (qw( setup last_bill bill adjourn susp expire contract_end change_date cancel active )) { my($beginning, $ending) = FS::UI::Web::parse_beginning_ending($cgi, $field); diff --git a/httemplate/misc/process/bulk_pkg_increment_bill.cgi b/httemplate/misc/process/bulk_pkg_increment_bill.cgi index d89f491..b734910 100755 --- a/httemplate/misc/process/bulk_pkg_increment_bill.cgi +++ b/httemplate/misc/process/bulk_pkg_increment_bill.cgi @@ -45,7 +45,7 @@ my %disable = ( '' => {}, ); -foreach my $field (qw( setup last_bill bill adjourn susp expire cancel )) { +foreach my $field (qw( setup last_bill bill adjourn susp expire contract_end change_date cancel active )) { my($beginning, $ending) = FS::UI::Web::parse_beginning_ending($cgi, $field); |