+% if ( $total_pkgs > $maxrecords ) {
+
+% if ( 1 ) { #FS::pkg_class->num_pkg_class ) {
+ <% $br++ ? ' | ' : '' %>
+ Class: <& /elements/select-cust-pkg_class.html,
+ curr_value => scalar($cgi->param('classnum')),
+ onchange => 'classnum_changed(this);',
+ pre_options => [ '-1' => 'all',
+ '0' => '(none)',
+ ],
+ &>
+% }
+
+ <% $br++ ? ' | ' : '' %>
+ Status: <& /elements/select-cust_pkg-status.html,
+ curr_value => scalar($cgi->param('status')),
+ onchange => 'status_changed(this);',
+ &>
+
+% if ( 1 ) { #$cust_main->num_cust_location ) {
+ <% $br++ ? ' | ' : '' %>
+ Location: <& /elements/select-cust_location.html,
+ cust_main => $cust_main,
+ curr_value => scalar($cgi->param('locationnum')),
+ addnew => 0,
+ onchange => 'locationnum_changed(this);',
+ pre_options => [ '-1' => 'all', ],
+ &>
+% }
+
+ <SCRIPT TYPE="text/javascript">
+
+ function classnum_changed(what) {
+% my $classnum = $cgi->param('classnum');
+% $cgi->delete('classnum');
+ window.location = '<% $cgi->self_url %>;classnum=' + what.options[what.selectedIndex].value;
+% $cgi->param('classnum', $classnum);
+ }
+
+ function status_changed(what) {
+% my $status = $cgi->param('status');
+% $cgi->delete('status');
+ window.location = '<% $cgi->self_url %>;status=' + what.options[what.selectedIndex].value;
+% $cgi->param('status', $status);
+ }
+
+ function locationnum_changed(what) {
+% my $locationnum = $cgi->param('locationnum');
+% $cgi->delete('locationnum');
+ window.location = '<% $cgi->self_url %>;locationnum=' + what.options[what.selectedIndex].value;
+% $cgi->param('locationnum', $locationnum);
+ }
+
+ </SCRIPT>
+
+% }
+
+<% $br++ ? ' | ' : '' %>