X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fbrowse%2Fpart_referral.html;h=c7374673ff2d9cb175714db41759a7f1e302d911;hb=ada2ac371279555b1009db1f995861eee2fa4bf2;hp=9cc32c4594a8b131a5f4136ff291feea447172c5;hpb=dc847cc499934b48c9da04bd0adb9c500ea6c0ac;p=freeside.git
diff --git a/httemplate/browse/part_referral.html b/httemplate/browse/part_referral.html
index 9cc32c459..c7374673f 100755
--- a/httemplate/browse/part_referral.html
+++ b/httemplate/browse/part_referral.html
@@ -6,6 +6,13 @@ Where a customer heard about your service. Tracked for informational purposes.
Add a new advertising source
+<% $cgi->param('showdisabled')
+ ? do { $cgi->param('showdisabled', 0);
+ '( hide disabled advertising sources )'; }
+ : do { $cgi->param('showdisabled', 1);
+ '( show disabled advertising sources )'; }
+%>
+
<% include('/elements/table-grid.html') %>
% my $bgcolor1 = '#eeeeee';
% my $bgcolor2 = '#ffffff';
@@ -13,8 +20,12 @@ Where a customer heard about your service. Tracked for informational purposes.
Advertising source |
-% if ( $show_agentnums ) {
+% if ( ! $cgi->param('showdisabled') ) {
+ |
+% }
+
+% if ( $show_agentnums ) {
Agent |
% }
@@ -27,7 +38,7 @@ Where a customer heard about your service. Tracked for informational purposes.
-%foreach my $part_referral ( FS::part_referral->all_part_referral(1) ) {
+%foreach my $part_referral ( FS::part_referral->all_part_referral(1,!scalar($cgi->param('showdisabled'))) ) {
%
% if ( $bgcolor eq $bgcolor1 ) {
% $bgcolor = $bgcolor2;
@@ -55,6 +66,16 @@ Where a customer heard about your service. Tracked for informational purposes.
% }
<% $part_referral->referral %><% $a ? '' : '' %>
+
+% if ( ! $cgi->param('showdisabled') ) {
+
+ <% $part_referral->disabled
+ ? 'DISABLED'
+ : 'Active'
+ %>
+ |
+% }
+
% if ( $show_agentnums ) {
<% $part_referral->agentnum ? $part_referral->agent->agent : '(global)' %> |
@@ -73,11 +94,11 @@ Where a customer heard about your service. Tracked for informational purposes.
<% $num_cust %> |
- customers |
+ customers |
<% $num_pkg %> |
- packages |
+ packages |
@@ -94,7 +115,7 @@ Where a customer heard about your service. Tracked for informational purposes.
% or die dbh->errstr;
- Total |
+ param('showdisabled') %>Total |
% for my $period ( keys %after ) {
% my @param = ( $today-$after{$period},
% $today+$before{$period},
@@ -108,11 +129,11 @@ Where a customer heard about your service. Tracked for informational purposes.
<% $num_cust %> |
- customers |
+ customers |
<% $num_pkg %> |
- packages |
+ packages |