X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fsearch%2Freport_cust_pkg.html;h=5b2efa2ca56673452dad0f607c741dd0bb1e10b3;hb=6309b438373b226e3bc4ec8406a64154f87e1ccd;hp=2193cac8b19a97ff5f97e7f50509c5a2b139fcde;hpb=0c2f4bccc3810426d4b9e31dca645711c32f0b63;p=freeside.git
diff --git a/httemplate/search/report_cust_pkg.html b/httemplate/search/report_cust_pkg.html
index 2193cac8b..5b2efa2ca 100755
--- a/httemplate/search/report_cust_pkg.html
+++ b/httemplate/search/report_cust_pkg.html
@@ -12,23 +12,81 @@
$cgi->param('agentnum'),
)
%>
- <% include( '/elements/tr-select-cust_pkg-status.html' ) %>
+
+ <% include( '/elements/tr-select-cust_pkg-status.html', '',
+ 'onchange' => 'status_changed(this);',
+ )
+ %>
+
+
+
<% include( '/elements/tr-select-pkg_class.html', '',
'pre_options' => [ '0' => 'all' ],
'empty_label' => '(empty class)',
)
%>
- <% include( '/elements/tr-selectmultiple-part_pkg.html' ) %>
-
- Next bill date |
-
-
- <% include( '/elements/tr-input-beginning_ending.html' ) %>
-
- |
-
+% foreach my $field (qw( setup last_bill bill susp expire cancel )) {
+
+
+ <% $label{$field} %> |
+
+
+ <% include( '/elements/tr-input-beginning_ending.html',
+ prefix => $field,
+ layout => 'horiz',
+ )
+ %>
+
+ |
+
+
+% }
+ <% include( '/elements/tr-selectmultiple-part_pkg.html' ) %>
+
|
@@ -46,3 +104,41 @@
<% include('/elements/footer.html') %>
+<%init>
+
+die "access denied"
+ unless $FS::CurrentUser::CurrentUser->access_right('List packages');
+
+%init>
+<%once>
+
+my %label = (
+ 'setup' => 'Setup',
+ 'last_bill' => 'Last bill',
+ 'bill' => 'Next bill',
+ 'susp' => 'Suspended',
+ 'expire' => 'Expires',
+ 'cancel' => 'Cancelled',
+);
+
+#false laziness w/cust_pkg.cgi
+my %disable = (
+ 'all' => {},
+ 'one-time charge' => { 'last_bill'=>1, 'bill'=>1, 'susp'=>1, 'expire'=>1, 'cancel'=>1, },
+ 'active' => { 'susp'=>1, 'cancel'=>1 },
+ 'suspended' => { 'cancel' => 1 },
+ 'cancelled' => {},
+ '' => {},
+);
+
+#hmm?
+my %checkbox = (
+ 'setup' => 0,
+ 'last_bill' => 0,
+ 'bill' => 0,
+ 'susp' => 1,
+ 'expire' => 1,
+ 'cancel' => 1,
+);
+
+%once>