diff options
author | Mark Wells <mark@freeside.biz> | 2012-04-06 12:33:20 -0700 |
---|---|---|
committer | Mark Wells <mark@freeside.biz> | 2012-04-06 12:33:20 -0700 |
commit | 23b0288f93882b3de9e6531b33c76517e47353c5 (patch) | |
tree | 3c334f4439aa77029088e29fdfa7fb1f8dfa3093 /httemplate | |
parent | 43d5252f60e7322ea4a0922658939b703f304db2 (diff) |
search by change date on advanced package report, #17113
Diffstat (limited to 'httemplate')
-rwxr-xr-x | httemplate/search/cust_pkg.cgi | 11 | ||||
-rwxr-xr-x | httemplate/search/report_cust_pkg.html | 43 |
2 files changed, 35 insertions, 19 deletions
diff --git a/httemplate/search/cust_pkg.cgi b/httemplate/search/cust_pkg.cgi index 297edee90..887ec6039 100755 --- a/httemplate/search/cust_pkg.cgi +++ b/httemplate/search/cust_pkg.cgi @@ -20,6 +20,7 @@ emt('Susp. delay'), emt('Expire'), emt('Contract end'), + emt('Changed'), emt('Cancel'), emt('Reason'), FS::UI::Web::cust_header( @@ -45,7 +46,7 @@ sub { FS::part_pkg::freq_pretty(shift); }, ( map { time_or_blank($_) } - qw( setup last_bill bill adjourn susp dundate expire contract_end cancel ) ), + qw( setup last_bill bill adjourn susp dundate expire contract_end change_date cancel ) ), sub { my $self = shift; my $return = ''; @@ -94,13 +95,14 @@ '', '', '', + '', FS::UI::Web::cust_colors(), '', ], - 'style' => [ '', '', '', '', 'b', '', '', '', '', '', '', '', '', '', '', '', '', '', + 'style' => [ '', '', '', '', 'b', '', '', '', '', '', '', '', '', '', '', '', '', '', '', FS::UI::Web::cust_styles() ], 'size' => [ '', '', '', '', '-1' ], - 'align' => 'rrlccrrlrrrrrrrrrl'. FS::UI::Web::cust_aligns(). 'r', + 'align' => 'rrlccrrlrrrrrrrrrrl'. FS::UI::Web::cust_aligns(). 'r', 'links' => [ $link, $link, @@ -117,6 +119,7 @@ '', '', '', + '', # link to changed-from package? '', '', '', @@ -182,7 +185,7 @@ my %disable = ( '' => {}, ); -foreach my $field (qw( setup last_bill bill adjourn susp expire contract_end cancel active )) { +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/search/report_cust_pkg.html b/httemplate/search/report_cust_pkg.html index 3da59c2ac..e47bbb1e5 100755 --- a/httemplate/search/report_cust_pkg.html +++ b/httemplate/search/report_cust_pkg.html @@ -88,23 +88,35 @@ %> % } - + <TR> + <TD COLSPAN=2> + <TABLE> + <TR> + <TD></TD> + <TD>From date <i>(m/d/y)</i></TD> + <TD>To date <i>(m/d/y)</i></TD> + </TR> +% my $noinit = 0; % foreach my $field (@date_fields) { - <TR> - <TD ALIGN="right" VALIGN="center"><% $label{$field} %></TD> - <TD> - <TABLE> - <% include( '/elements/tr-input-beginning_ending.html', - prefix => $field, - layout => 'horiz', - ) - %> - </TABLE> - </TD> - </TR> - -% } + <TR> + <TD ALIGN="right" VALIGN="center"><% $label{$field} %></TD> +% foreach (qw(beginning ending)) { + <TD> + <& /elements/input-date-field.html, { + 'name' => $field.'_'.$_, + 'value' => '', + 'noinit' => $noinit, + 'format' => '%m/%d/%Y', + } &> + </TD> +% $noinit = 1; +% } + </TR> +% } #foreach $field + </TABLE> + </TD> + </TR> <SCRIPT TYPE="text/javascript"> @@ -186,6 +198,7 @@ tie my %label, 'Tie::IxHash', 'dundate' => 'Suspension delayed until', 'expire' => 'Expires', 'contract_end' => 'Contract ends', + 'change_date' => 'Changed from other package', 'cancel' => 'Cancelled', ; my @date_fields = keys %label; |