+ <TR>
+ <TH ALIGN="right">Tags</TH>
+ <TD>
+ <& /elements/select-cust_tag.html,
+ 'cgi' => $cgi,
+ 'is_report' => 1,
+ 'multiple' => 1,
+ &>
+ <DIV STYLE="display:inline-block; vertical-align:baseline">
+ <INPUT TYPE="radio" NAME="all_tags" VALUE="0" CHECKED> Any of these
+ <BR>
+ <INPUT TYPE="radio" NAME="all_tags" VALUE="1"> All of these
+ </DIV>
+ </TD>
+ </TR>
+
+ </TABLE>
+ <BR>
+
+ <FONT CLASS="fsinnerbox-title"><% emt('Referral search options') %></FONT>
+ <TABLE CLASS="fsinnerbox">
+
+ <& /elements/tr-input-text.html,
+ label => emt('At least this many'),
+ field => 'with_referrals',
+ size => 4,
+ maxlength => 4,
+ &>
+
+ <& /elements/tr-select-cust_main-status.html,
+ label => emt('Referral status'),
+ field => 'referral_status',
+ &>
+
+ </TABLE>
+ <BR>
+
+ <FONT CLASS="fsinnerbox-title"><% emt('Package search options') %></FONT>
+ <TABLE CLASS="fsinnerbox">
+
+ <TR>
+
+ <TH ALIGN="right">With</TH>
+ <TD><SELECT NAME="any_pkg_status">
+ <OPTION VALUE="0">active packages
+ <OPTION VALUE="1">any status packages
+ </SELECT>
+ </TD>
+ </TR>
+
+ <TH ALIGN="right">of class</TH>
+ <TD>
+ <& /elements/select-pkg_class.html,
+ 'field' => 'pkg_classnum',
+ 'multiple' => 1,
+ &>
+ <DIV STYLE="display:inline-block; vertical-align:baseline">
+ <INPUT TYPE="radio" NAME="all_pkg_classnums" VALUE="0" CHECKED>
+ Any of these
+ <BR>
+ <INPUT TYPE="radio" NAME="all_pkg_classnums" VALUE="1">
+ All of these
+ </DIV>
+ </TD>
+ </TR>
+
+ </TABLE>
+ <BR>
+
+ <FONT CLASS="fsinnerbox-title"><% emt('Location search options') %></FONT>
+ <TABLE CLASS="fsinnerbox">
+ <& elements/options_cust_location.html &>
+ </TABLE>
+ <BR>
+
+ <FONT CLASS="fsinnerbox-title"><% emt('Contacts search options') %></FONT>
+ <TABLE CLASS="fsinnerbox">
+ <& elements/options_cust_contacts.html,
+ 'pre_fix' => 'contacts_',
+ &>
+ </TABLE>
+ <BR>
+
+ <FONT CLASS="fsinnerbox-title"><% emt('Billing search options') %></FONT>
+ <TABLE CLASS="fsinnerbox">
+
+% my @exempt_groups = grep /\S/, $conf->config('tax-cust_exempt-groups');
+% unless ( @exempt_groups ) {
+
+% #falze laziness with With/Without postal mail invoices
+ <TR>
+ <TH ALIGN="right" VALIGN="center"><% mt('Tax exempt') |h %></TH>
+ <TD><INPUT TYPE="checkbox" NAME="tax" ID="tax" onClick="tax_changed();"></TD>
+ </TR>
+
+ <TR>
+ <TH ALIGN="right" VALIGN="center"><% mt('Not tax exempt') |h %></TH>
+ <TD><INPUT TYPE="checkbox" NAME="no_tax" ID="no_tax" onClick="no_tax_changed();"></TD>
+ </TR>
+
+ <SCRIPT TYPE="text/javascript">
+ function tax_changed() {
+ if ( document.getElementById('tax').checked == true ) {
+ document.getElementById('no_tax').checked = false;
+ }
+ }
+ function no_tax_changed() {
+ if ( document.getElementById('no_tax').checked == true ) {
+ document.getElementById('tax').checked = false;
+ }
+ }
+ </SCRIPT>
+% }
+
+ <TR>
+ <TH ALIGN="right"><% mt('Invoice terms') |h %></TH>
+ <TD>
+% my @agentnums = $FS::CurrentUser::CurrentUser->agentnums;
+% my $agentnum = scalar(@agentnums) == 1 ? $agentnums[0] : '';
+ <& /elements/select-terms.html,
+ 'pre_options' => [ '' => emt('all') ],
+ 'empty_value' => 'NULL',
+ 'agentnum' => $agentnum,
+ &>
+ </TD>
+ </TR>