[freeside-commits] freeside/httemplate/search report_cust_event.html, 1.3, 1.4 cust_event.html, 1.6, 1.7

Ivan,,, ivan at wavetail.420.am
Fri Oct 30 16:29:20 PDT 2009


Update of /home/cvs/cvsroot/freeside/httemplate/search
In directory wavetail.420.am:/tmp/cvs-serv24975/httemplate/search

Modified Files:
	report_cust_event.html cust_event.html 
Log Message:
more reporting options for failed billing events, RT#6447

Index: report_cust_event.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/search/report_cust_event.html,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- report_cust_event.html	10 Dec 2008 21:43:43 -0000	1.3
+++ report_cust_event.html	30 Oct 2009 23:29:18 -0000	1.4
@@ -6,52 +6,36 @@
 
     <FORM ACTION="cust_event.html" METHOD="GET">
     <INPUT TYPE="hidden" NAME="failed" VALUE="<% $cgi->param('failed') ? 1 : 0 %>">
-    <TABLE>
+    <TABLE BGCOLOR="#cccccc" CELLSPACING=0>
+
+      <TR>
+        <TH BGCOLOR="#e8e8e8" COLSPAN=2 ALIGN="left"><FONT SIZE="+1">Search options</FONT></TH>
+      </TR>
 
       <% include( '/elements/tr-select-agent.html', 'disable_empty'=>0 ) %>
 
-      <!--<TR>
-        <TD ALIGN="right">Customer type</TD>
-        <TD><SELECT MULTIPLE NAME="perhaps_payby">
-          <OPTION SELECTED VALUE="CARD">Credit card (automatic)
-          <OPTION SELECTED VALUE="CHEK">E-check (automatic)
-          <OPTION SELECTED VALUE="LECB">Phone bill billing
-          <OPTION SELECTED VALUE="BILL">Billing
-          <OPTION SELECTED VALUE="DCRD">Credit card (on-demand)
-          <OPTION SELECTED VALUE="DCHK">E-check (on-demand)
-        </TD>
-      </TR>
-      -->
+      <% include( '/elements/tr-select-cust_main-status.html',
+                    'label' => 'Status'
+                )
+      %>
+
+      <% include( '/elements/tr-select-payby.html',
+                    'label'        => 'Customer payment type',
+                    'payby_type'   => 'cust',
+                    'multiple'     => 1,
+                    'all_selected' => 1,
+                )
+      %>
+
+      <% include( '/elements/tr-select-part_event.html',
+                    'label'        => 'Events',
+                    'multiple'     => 1,
+                    'all_selected' => 1,
+                )
+      %>
+
       <% include( '/elements/tr-input-beginning_ending.html' ) %>
-      <!--
-      <TR>
-        <TD ALIGN="right">Events: </TD>
-        <TD>
-          <SELECT NAME="eventpart">
-            <OPTION SELECTED VALUE=""><% $cgi->param('failed') ? '(all failed events)' : '(all events)' %>
-% #foreach my $part_bill_event ( qsearch( 'part_bill_event', {} ) ) { 
-% #} 
 
-          </SELECT>
-        </TD>
-      </TR>
-      -->
-<!--      <TR>
-        <TD ALIGN="right">Events for payment type: </TD>
-        <TD>
-          <SELECT NAME="part_bill_event.payby">
-            <OPTION SELECTED VALUE="">(all)
-            <OPTION VALUE="CARD">Credit card (automatic)
-            <OPTION VALUE="BILL">Billing
-            <OPTION VALUE="CHEK">Electronic check (automatic)
-            <OPTION VALUE="DCRD">Credit card (on-demand)
-            <OPTION VALUE="DCHK">Electronic check (on-demand)
-            <OPTION VALUE="LECB">Phone bill billing
-            <OPTION VALUE="COMP">Complimentary
-          </SELECT>
-        </TD>
-      </TR>
--->
     </TABLE>
     <BR><INPUT TYPE="submit" VALUE="Get Report">
     </FORM>

Index: cust_event.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/search/cust_event.html,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- cust_event.html	7 Oct 2009 23:44:25 -0000	1.6
+++ cust_event.html	30 Oct 2009 23:29:18 -0000	1.7
@@ -157,12 +157,18 @@
 
 my %search = ();
 
-my @scalars = qw ( agentnum custnum invnum pkgnum failed );
-for my $param ( @scalars ) {
+my @scalars = qw( agentnum status custnum invnum pkgnum failed );
+for my $param (@scalars) {
   $search{$param} = scalar( $cgi->param($param) )
     if $cgi->param($param);
 }
 
+#lists
+my @lists = qw( payby eventpart );
+foreach my $param (@lists) {
+  $search{$param} = [ $cgi->param($param) ];
+}
+
 my($beginning, $ending) = FS::UI::Web::parse_beginning_ending($cgi);
 $search{'beginning'} = $beginning;
 $search{'ending'}    = $ending;
@@ -208,6 +214,11 @@
         }
         @params #keys %search
   ),
+  ( map { my $value = encode_entities( join(',', @{ $search{$_} } ) );
+          qq(<INPUT TYPE="hidden" NAME="$_" VALUE="$value">);
+        }
+        @lists
+  ),
   qq!</FORM>!
 } qw( print_ email_ fax_ ) ).
 



More information about the freeside-commits mailing list