hide SS# unless you turn it on via config file
authorivan <ivan>
Sun, 10 Feb 2002 02:28:28 +0000 (02:28 +0000)
committerivan <ivan>
Sun, 10 Feb 2002 02:28:28 +0000 (02:28 +0000)
FS/FS/Conf.pm
httemplate/edit/cust_main.cgi
httemplate/view/cust_main.cgi

index da6bf72..20ec138 100644 (file)
@@ -723,6 +723,13 @@ httemplate/docs/config.html
     'type'        => 'checkbox',
   },
 
+  {
+    'key'         => 'show_ss',
+    'section'     => 'UI',
+    'description' => 'Turns on display/collection of SS# in the web interface.',
+    'type'        => 'checkbox',
+  },
+
 );
 
 1;
index fad4d9e..5be6a35 100755 (executable)
@@ -1,4 +1,4 @@
-<!-- $Id: cust_main.cgi,v 1.19 2002-01-30 14:18:08 ivan Exp $ -->
+<!-- $Id: cust_main.cgi,v 1.20 2002-02-10 02:28:27 ivan Exp $ -->
 <%
 
   #for misplaced logic below
@@ -153,10 +153,17 @@ END
 print <<END;
 <INPUT TYPE="text" NAME="last" VALUE="$last"> , 
 <INPUT TYPE="text" NAME="first" VALUE="$first">
+</TD>
 END
 
+if ( $conf->exists('show_ss') ) {
+  print qq!<TD ALIGN="right">SS#</TD><TD><INPUT TYPE="text" NAME="ss" VALUE="$ss" SIZE=11></TD>!;
+} else {
+  print qq!<TD><INPUT TYPE="hidden" NAME="ss" VALUE="$ss"></TD>!;
+}
+
 print <<END;
-</TD><TD ALIGN="right">SS#</TD><TD><INPUT TYPE="text" NAME="ss" VALUE="$ss" SIZE=11></TD></TR>
+</TR>
 <TR><TD ALIGN="right">Company</TD><TD COLSPAN=5><INPUT TYPE="text" NAME="company" VALUE="$company" SIZE=70></TD></TR>
 <TR><TH ALIGN="right">${r}Address</TH><TD COLSPAN=5><INPUT TYPE="text" NAME="address1" VALUE="$address1" SIZE=70></TD></TR>
 <TR><TD ALIGN="right">&nbsp;</TD><TD COLSPAN=5><INPUT TYPE="text" NAME="address2" VALUE="$address2" SIZE=70></TD></TR>
index dc4760d..946fc63 100755 (executable)
@@ -1,4 +1,4 @@
-<!-- $Id: cust_main.cgi,v 1.20 2002-02-07 22:29:35 ivan Exp $ -->
+<!-- $Id: cust_main.cgi,v 1.21 2002-02-10 02:28:28 ivan Exp $ -->
 <%
 
 my $conf = new FS::Conf;
@@ -49,8 +49,12 @@ print '<TD VALIGN="top">';
     '<TR><TD ALIGN="right">Contact name</TD>',
       '<TD COLSPAN=3 BGCOLOR="#ffffff">',
       $cust_main->last, ', ', $cust_main->first,
-      '</TD><TD ALIGN="right">SS#</TD><TD BGCOLOR="#ffffff">',
-      $cust_main->ss || '&nbsp', '</TD></TR>',
+      '</TD>';
+print '<TD ALIGN="right">SS#</TD><TD BGCOLOR="#ffffff">',
+      $cust_main->ss || '&nbsp', '</TD>'
+  if $conf->exists('show_ss');
+
+print '</TR>',
     '<TR><TD ALIGN="right">Company</TD><TD COLSPAN=5 BGCOLOR="#ffffff">',
       $cust_main->company,
       '</TD></TR>',