improve speed in customer search, #13364
[freeside.git] / httemplate / search / cust_bill_event.html
index 7cdf251..0f84a55 100755 (executable)
@@ -1,16 +1,18 @@
 <% include(
       '/elements/header.html',
       ( $cgi->param('failed') ? 'Failed invoice events' : 'Invoice events' ),
-      include('/elements/menubar.html',
-                'Main menu' => $p, # popurl(2),
-             ),
-
-    )
+   )
 %>
 
+    <FONT SIZE="+1">Invoice events are the deprecated, old-style actions taken
+    on open invoices.  See Reports-&gt;Billing events-&gt;Billing events for current event reports.</FONT><BR><BR>
+
     <FORM ACTION="cust_bill_event.cgi" METHOD="GET">
-    <INPUT TYPE="hidden" NAME="failed" VALUE="<% $cgi->param('failed') %>">
+    <INPUT TYPE="hidden" NAME="failed" VALUE="<% $cgi->param('failed') ? 1 : 0 %>">
     <TABLE>
+
+      <% include( '/elements/tr-select-agent.html', 'disable_empty'=>0 ) %>
+
       <!--<TR>
         <TD ALIGN="right">Customer type</TD>
         <TD><SELECT MULTIPLE NAME="perhaps_payby">
@@ -30,8 +32,8 @@
         <TD>
           <SELECT NAME="eventpart">
             <OPTION SELECTED VALUE=""><% $cgi->param('failed') ? '(all failed events)' : '(all events)' %>
-% foreach my $part_bill_event ( qsearch( 'part_bill_event', {} ) ) { 
-% } 
+% #foreach my $part_bill_event ( qsearch( 'part_bill_event', {} ) ) { 
+% #
 
           </SELECT>
         </TD>
     </TABLE>
     <BR><INPUT TYPE="submit" VALUE="Get Report">
     </FORM>
-  </BODY>
-</HTML>
+
+<% include('/elements/footer.html') %>
+<%init>
+
+die "access denied"
+  unless $FS::CurrentUser::CurrentUser->access_right('Billing event reports');
+
+</%init>