[freeside-commits] freeside/httemplate/browse agent.cgi,1.32,1.33
Ivan,,,
ivan at wavetail.420.am
Tue Jul 25 01:33:48 PDT 2006
Update of /home/cvs/cvsroot/freeside/httemplate/browse
In directory wavetail:/tmp/cvs-serv29002/httemplate/browse
Modified Files:
agent.cgi
Log Message:
this should finish adding the "inactive" status, i think?
Index: agent.cgi
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/browse/agent.cgi,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -d -r1.32 -r1.33
--- agent.cgi 31 Jan 2006 04:26:54 -0000 1.32
+++ agent.cgi 25 Jul 2006 08:33:46 -0000 1.33
@@ -29,21 +29,27 @@
%>
<% } %>
-<%= table() %>
+<%= include('/elements/table-grid.html') %>
+
+<% my $bgcolor1 = '#eeeeee';
+ my $bgcolor2 = '#ffffff';
+ my $bgcolor = '';
+%>
+
<TR>
- <TH COLSPAN=<%= ( $cgi->param('showdisabled') || !dbdef->table('agent')->column('disabled') ) ? 2 : 3 %>>Agent</TH>
- <TH>Type</TH>
- <TH>Customers</TH>
- <TH><FONT SIZE=-1>Customer<BR>packages</FONT></TH>
- <TH>Reports</TH>
- <TH>Registration codes</TH>
- <TH>Prepaid cards</TH>
+ <TH CLASS="grid" BGCOLOR="#cccccc" COLSPAN=<%= ( $cgi->param('showdisabled') || !dbdef->table('agent')->column('disabled') ) ? 2 : 3 %>>Agent</TH>
+ <TH CLASS="grid" BGCOLOR="#cccccc">Type</TH>
+ <TH CLASS="grid" BGCOLOR="#cccccc">Customers</TH>
+ <TH CLASS="grid" BGCOLOR="#cccccc"><FONT SIZE=-1>Customer<BR>packages</FONT></TH>
+ <TH CLASS="grid" BGCOLOR="#cccccc">Reports</TH>
+ <TH CLASS="grid" BGCOLOR="#cccccc">Registration codes</TH>
+ <TH CLASS="grid" BGCOLOR="#cccccc">Prepaid cards</TH>
<% if ( $conf->config('ticket_system') ) { %>
- <TH>Ticketing</TH>
+ <TH CLASS="grid" BGCOLOR="#cccccc">Ticketing</TH>
<% } %>
- <TH><FONT SIZE=-1>Payment Gateway Overrides</FONT></TH>
- <TH><FONT SIZE=-1>Freq.</FONT></TH>
- <TH><FONT SIZE=-1>Prog.</FONT></TH>
+ <TH CLASS="grid" BGCOLOR="#cccccc"><FONT SIZE=-1>Payment Gateway Overrides</FONT></TH>
+ <TH CLASS="grid" BGCOLOR="#cccccc"><FONT SIZE=-1>Freq.</FONT></TH>
+ <TH CLASS="grid" BGCOLOR="#cccccc"><FONT SIZE=-1>Prog.</FONT></TH>
</TR>
<%
# <TH><FONT SIZE=-1>Agent #</FONT></TH>
@@ -58,107 +64,157 @@
'agentnum='. $agent->agentnum;
my $cust_pkg_link = $p. 'search/cust_pkg.cgi?agentnum='. $agent->agentnum;
+
+ if ( $bgcolor eq $bgcolor1 ) {
+ $bgcolor = $bgcolor2;
+ } else {
+ $bgcolor = $bgcolor1;
+ }
%>
<TR>
- <TD><A HREF="<%=$p%>edit/agent.cgi?<%= $agent->agentnum %>">
+ <TD CLASS="grid" BGCOLOR="<%= $bgcolor %>"><A HREF="<%=$p%>edit/agent.cgi?<%= $agent->agentnum %>">
<%= $agent->agentnum %></A></TD>
<% if ( dbdef->table('agent')->column('disabled')
&& !$cgi->param('showdisabled') ) { %>
- <TD><%= $agent->disabled ? 'DISABLED' : '' %></TD>
+ <TD CLASS="grid" BGCOLOR="<%= $bgcolor %>"><%= $agent->disabled ? 'DISABLED' : '' %></TD>
<% } %>
- <TD><A HREF="<%=$p%>edit/agent.cgi?<%= $agent->agentnum %>">
+ <TD CLASS="grid" BGCOLOR="<%= $bgcolor %>"><A HREF="<%=$p%>edit/agent.cgi?<%= $agent->agentnum %>">
<%= $agent->agent %></A></TD>
- <TD><A HREF="<%=$p%>edit/agent_type.cgi?<%= $agent->typenum %>"><%= $agent->agent_type->atype %></A></TD>
+ <TD CLASS="grid" BGCOLOR="<%= $bgcolor %>"><A HREF="<%=$p%>edit/agent_type.cgi?<%= $agent->typenum %>"><%= $agent->agent_type->atype %></A></TD>
+
+ <TD CLASS="inv" BGCOLOR="<%= $bgcolor %>">
+ <TABLE CLASS="inv" CELLSPACING=0 CELLPADDING=0>
- <TD>
- <TABLE CELLSPACING=0 CELLPADDING=0>
<TR>
<TH ALIGN="right" WIDTH="40%">
- <%= my $num_prospect = $agent->num_prospect_cust_main %>
+ <FONT COLOR="#7e0079">
+ <%= my $num_prospect = $agent->num_prospect_cust_main %>
+ </FONT>
</TH>
+
<TD>
<% if ( $num_prospect ) { %>
<A HREF="<%= $cust_main_link %>&prospect=1"><% } %>prospects<% if ($num_prospect ) { %></A><% } %>
<TD>
</TR>
+
+ <TR>
+ <TH ALIGN="right" WIDTH="40%">
+ <FONT COLOR="#0000CC">
+ <%= my $num_inactive = $agent->num_inactive_cust_main %>
+ </FONT>
+ </TH>
+
+ <TD>
+ <% if ( $num_inactive ) { %>
+ <A HREF="<%= $cust_main_link %>&inactive=1"><% } %>inactive<% if ( $num_inactive ) { %></A><% } %>
+ </TD>
+ </TR>
+
<TR>
<TH ALIGN="right" WIDTH="40%">
<FONT COLOR="#00CC00">
<%= my $num_active = $agent->num_active_cust_main %>
</FONT>
</TH>
+
<TD>
<% if ( $num_active ) { %>
<A HREF="<%= $cust_main_link %>&active=1"><% } %>active<% if ( $num_active ) { %></A><% } %>
</TD>
</TR>
+
<TR>
<TH ALIGN="right" WIDTH="40%">
<FONT COLOR="#FF9900">
<%= my $num_susp = $agent->num_susp_cust_main %>
</FONT>
</TH>
+
<TD>
<% if ( $num_susp ) { %>
<A HREF="<%= $cust_main_link %>&suspended=1"><% } %>suspended<% if ( $num_susp ) { %></A><% } %>
</TD>
</TR>
+
<TR>
<TH ALIGN="right" WIDTH="40%">
<FONT COLOR="#FF0000">
<%= my $num_cancel = $agent->num_cancel_cust_main %>
</FONT>
</TH>
+
<TD>
<% if ( $num_cancel ) { %>
<A HREF="<%= $cust_main_link %>&showcancelledcustomers=1&cancelled=1"><% } %>cancelled<% if ( $num_cancel ) { %></A><% } %>
</TD>
</TR>
+
</TABLE>
</TD>
- <TD>
- <TABLE CELLSPACING=0 CELLPADDING=0>
+ <TD CLASS="inv" BGCOLOR="<%= $bgcolor %>" VALIGN="bottom">
+ <TABLE CLASS="inv" CELLSPACING=0 CELLPADDING=0>
+
+ <TR>
+ <TH ALIGN="right" WIDTH="40%">
+ <FONT COLOR="#0000CC">
+ <%= my $num_inactive_pkg = $agent->num_inactive_cust_pkg %>
+ </FONT>
+ </TH>
+
+ <TD>
+ <% if ( $num_inactive_pkg ) { %>
+ <A HREF="<%= $cust_pkg_link %>&magic=inactive"><% } %>inactive<% if ( $num_inactive_pkg ) { %></A><% } %>
+ </TD>
+ </TR>
+
<TR>
<TH ALIGN="right" WIDTH="40%">
<FONT COLOR="#00CC00">
<%= my $num_active_pkg = $agent->num_active_cust_pkg %>
</FONT>
</TH>
+
<TD>
<% if ( $num_active_pkg ) { %>
<A HREF="<%= $cust_pkg_link %>&magic=active"><% } %>active<% if ( $num_active_pkg ) { %></A><% } %>
</TD>
</TR>
+
<TR>
<TH ALIGN="right" WIDTH="40%">
<FONT COLOR="#FF9900">
<%= my $num_susp_pkg = $agent->num_susp_cust_pkg %>
</FONT>
+
</TH>
<TD>
<% if ( $num_susp_pkg ) { %>
<A HREF="<%= $cust_pkg_link %>&magic=suspended"><% } %>suspended<% if ( $num_susp_pkg ) { %></A><% } %>
</TD>
</TR>
+
<TR>
<TH ALIGN="right" WIDTH="40%">
<FONT COLOR="#FF0000">
<%= my $num_cancel_pkg = $agent->num_cancel_cust_pkg %>
</FONT>
</TH>
+
<TD>
<% if ( $num_cancel_pkg ) { %>
<A HREF="<%= $cust_pkg_link %>&magic=cancelled"><% } %>cancelled<% if ( $num_cancel_pkg ) { %></A><% } %>
</TD>
</TR>
+
</TABLE>
</TD>
- <TD>
+ <TD CLASS="grid" BGCOLOR="<%= $bgcolor %>">
<A HREF="<%= $p %>search/report_cust_pay.html?agentnum=<%= $agent->agentnum %>">Payments</A>
<BR><A HREF="<%= $p %>search/report_cust_credit.html?agentnum=<%= $agent->agentnum %>">Credits</A>
<BR><A HREF="<%= $p %>search/report_receivables.cgi?agentnum=<%= $agent->agentnum %>">A/R Aging</A>
@@ -166,14 +222,14 @@
</TD>
- <TD>
+ <TD CLASS="grid" BGCOLOR="<%= $bgcolor %>">
<%= my $num_reg_code = $agent->num_reg_code %>
<% if ( $num_reg_code ) { %>
<A HREF="<%=$p%>search/reg_code.html?agentnum=<%= $agent->agentnum %>"><% } %>Unused<% if ( $num_reg_code ) { %></A><% } %>
<BR><A HREF="<%=$p%>edit/reg_code.cgi?agentnum=<%= $agent->agentnum %>">Generate codes</A>
</TD>
- <TD>
+ <TD CLASS="grid" BGCOLOR="<%= $bgcolor %>">
<%= my $num_prepay_credit = $agent->num_prepay_credit %>
<% if ( $num_prepay_credit ) { %>
<A HREF="<%=$p%>search/prepay_credit.html?agentnum=<%= $agent->agentnum %>"><% } %>Unused<% if ( $num_prepay_credit ) { %></A><% } %>
@@ -182,7 +238,7 @@
<% if ( $conf->config('ticket_system') ) { %>
- <TD>
+ <TD CLASS="grid" BGCOLOR="<%= $bgcolor %>">
<% if ( $agent->ticketing_queueid ) { %>
Queue: <%= $agent->ticketing_queueid %>: <%= $agent->ticketing_queue %><BR>
<% } %>
@@ -190,7 +246,7 @@
<% } %>
- <TD>
+ <TD CLASS="grid" BGCOLOR="<%= $bgcolor %>">
<TABLE CELLSPACING=0 CELLPADDING=0>
<% foreach my $override (
# sort { } want taxclass-full stuff first? and default cards (empty cardtype)
@@ -214,8 +270,10 @@
</TABLE>
</TD>
- <TD><%= $agent->freq %></TD>
- <TD><%= $agent->prog %></TD>
+<!--
+ <TD CLASS="grid" BGCOLOR="<%= $bgcolor %>"><%= $agent->freq %></TD>
+ <TD CLASS="grid" BGCOLOR="<%= $bgcolor %>"><%= $agent->prog %></TD>
+-->
</TR>
More information about the freeside-commits
mailing list