1 <& /elements/header.html, mt('Customer Report') &>
3 <FORM ACTION="cust_main.html" METHOD="GET">
4 <INPUT TYPE="hidden" NAME="magic" VALUE="bill">
6 <TABLE BGCOLOR="#cccccc" CELLSPACING=0>
9 <TH CLASS="background" COLSPAN=2 ALIGN="left"><FONT SIZE="+1"><% mt('Search options') |h %></FONT></TH>
12 <& /elements/tr-select-agent.html,
13 'curr_value' => scalar($cgi->param('agentnum')),
17 <& /elements/tr-select-cust_main-status.html,
18 'label' => emt('Status'),
21 <& /elements/tr-select-cust_class.html,
22 'label' => emt('Class'),
24 'pre_options' => [ '' => emt('(none)') ],
28 <& /elements/tr-select-part_referral.html,
29 'label' => emt('Advertising Source'),
35 <TD ALIGN="right" VALIGN="center"><% mt('Address') |h %></TD>
36 <TD><INPUT TYPE="text" NAME="address" SIZE=54></TD>
40 <TD ALIGN="right" VALIGN="center"><% mt('Signup date') |h %></TD>
43 <& /elements/tr-input-beginning_ending.html,
44 prefix => 'signupdate',
51 % if ( $conf->exists('cust_main-enable_birthdate') ) {
53 <TD ALIGN="right" VALIGN="center"><% mt('Date of Birth') |h %></TD>
56 <& /elements/tr-input-beginning_ending.html,
57 prefix => 'birthdate',
65 % if ( $conf->exists('cust_main-enable_spouse_birthdate') ) {
67 <TD ALIGN="right" VALIGN="center"><% mt('Spouse Date of Birth') |h %></TD>
70 <& /elements/tr-input-beginning_ending.html,
71 prefix => 'spouse_birthdate',
79 <& /elements/tr-select-cust_tag.html,
85 <& /elements/tr-select-payby.html,
86 'payby_type' => 'cust',
92 <TD ALIGN="right"><% mt('Payment expiration before') |h %></TD>
94 <SELECT NAME="paydate_month" DISABLED>
95 % foreach my $month ( 1 .. 12 ) {
96 <OPTION VALUE="<% $month %>"><% $month %></OPTION>
100 <SELECT NAME="paydate_year" onChange="paydate_year_changed(this);">
101 <OPTION VALUE=""></OPTION>
102 % my $lastyear = (localtime(time))[5] + 1899;
103 % foreach my $year ( $lastyear .. $lastyear+12 ) {
104 <OPTION VALUE="<% $year %>"><% $year %></OPTION>
110 <SCRIPT TYPE="text/javascript">
111 function paydate_year_changed(what) {
112 var value = what.options[what.selectedIndex].value;
113 var month_select = what.form.paydate_month;
115 month_select.disabled = true;
117 month_select.disabled = false;
123 <TD ALIGN="right"><% mt('Invoice terms') |h %></TD>
125 <& /elements/select-terms.html,
126 'pre_options' => [ '' => emt('all') ],
127 'empty_value' => 'NULL',
132 <& /elements/tr-input-lessthan_greaterthan.html,
133 label => emt('Current balance'),
134 field => 'current_balance',
138 <TD ALIGN="right" VALIGN="center"><% mt('Without census tract') |h %></TD>
139 <TD><INPUT TYPE="checkbox" NAME="no_censustract"></TD>
142 % if ( $conf->exists('enable_taxproducts') ) {
145 <TD ALIGN="right" VALIGN="center"><% mt('With hardcoded tax location') |h %></TD>
146 <TD><INPUT TYPE="checkbox" NAME="with_geocode"></TD>
152 <TH CLASS="background" COLSPAN=2> </TH>
156 <TH CLASS="background" COLSPAN=2 ALIGN="left"><FONT SIZE="+1"><% mt('Display options') |h %></FONT></TH>
158 <& /elements/tr-select-cust-fields.html &>
161 <TD ALIGN="right" VALIGN="center"><% mt('Add package columns') |h %></TD>
162 <TD><INPUT TYPE="checkbox" NAME="flattened_pkgs"></TD>
166 <TD ALIGN="right" VALIGN="center"><% mt('Include cancelled packages') |h %></TD>
167 <TD><INPUT TYPE="checkbox" NAME="cancelled_pkgs"></TD>
173 <INPUT TYPE="submit" VALUE="<% mt('Get Report') |h %>">
177 <& /elements/footer.html &>
181 unless $FS::CurrentUser::CurrentUser->access_right('Advanced customer search');
183 my $conf = new FS::Conf;