[freeside-commits] branch master updated. 3a7f3a2e81cc7423ba9a08fd4b28b3b5f4f227a2

Carl J. Adams-Collier cjac at 420.am
Fri Sep 26 12:00:46 PDT 2014


The branch, master has been updated
       via  3a7f3a2e81cc7423ba9a08fd4b28b3b5f4f227a2 (commit)
      from  698e8e9c11cea396fdb1e867b24bc2412e98781d (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 3a7f3a2e81cc7423ba9a08fd4b28b3b5f4f227a2
Author: C.J. Adams-Collier <cjac at colliertech.org>
Date:   Fri Sep 26 12:00:43 2014 -0700

    FS RT #30363 - Hide Account usage template output in an HTML comment when $hide_usage is true

diff --git a/FS/FS/ClientAPI/MyAccount.pm b/FS/FS/ClientAPI/MyAccount.pm
index 86e4b89..bcfe35c 100644
--- a/FS/FS/ClientAPI/MyAccount.pm
+++ b/FS/FS/ClientAPI/MyAccount.pm
@@ -398,11 +398,12 @@ sub access_info {
 
   $info->{'timeout'} = $conf->config('selfservice-timeout') || 3600;
 
+  $info->{'hide_usage'} = $conf->exists('selfservice_hide-usage');
+
   return { %$info,
            'custnum'       => $custnum,
            'access_pkgnum' => $session->{'pkgnum'},
            'access_svcnum' => $session->{'svcnum'},
-	   'hide_usage'    => $conf->exists('selfservice_hide-usage'),
          };
 }
 
diff --git a/fs_selfservice/FS-SelfService/cgi/view_usage.html b/fs_selfservice/FS-SelfService/cgi/view_usage.html
index f50f770..c43f7d3 100644
--- a/fs_selfservice/FS-SelfService/cgi/view_usage.html
+++ b/fs_selfservice/FS-SelfService/cgi/view_usage.html
@@ -18,6 +18,8 @@
     '';
 %>
 <%= include('header', 'Account usage') %>
+<%= if( $hide_usage ){ $OUT .= '<' . '!--' } %>
+
 
 <%= if ( $error ) {
   $OUT .= qq!<FONT SIZE="+1" COLOR="#ff0000">$error</FONT><BR><BR>!;
@@ -216,4 +218,6 @@ foreach my $svc_port ( @svc_port ) {
 
 
 </TD></TR></TABLE>
+<%= if( $hide_usage ){ $OUT .= '--'. '>' } %>
 <%= include('footer') %>
+

-----------------------------------------------------------------------

Summary of changes:
 FS/FS/ClientAPI/MyAccount.pm                      |    3 ++-
 fs_selfservice/FS-SelfService/cgi/view_usage.html |    4 ++++
 2 files changed, 6 insertions(+), 1 deletion(-)




More information about the freeside-commits mailing list