This commit was generated by cvs2svn to compensate for changes in r4888,
[freeside.git] / httemplate / edit / cust_main.cgi
index dfcd040..57d4dac 100755 (executable)
 % } else { 
 
 
-   <% include('/elements/tr-select-part_referral.html') %>
+   <% include('/elements/tr-select-part_referral.html', $refnum ) %>
 % } 
 
 
 
 </TABLE>
 
+<!-- birthdate -->
+
+% if ( $conf->exists('cust_main-enable_birthdate') ) {
+
+  <BR>
+  <% ntable("#cccccc", 2) %>
+  <% include ('/elements/tr-input-date-field.html',
+              'birthdate',
+              $cust_main->birthdate,
+              'Date of Birth',
+              $conf->config('date_format') || "%m/%d/%Y")
+  %>
+
+  </TABLE>
+
+% }
+
 <!-- contact info -->
 
 <BR><BR>
@@ -247,6 +264,8 @@ Service address
 function bottomfixup(what) {
 
   var topvars = new Array(
+    'birthdate',
+
     'custnum', 'agentnum', 'refnum', 'referral_custnum',
 
     'last', 'first', 'ss', 'company',
@@ -329,6 +348,8 @@ function copyelement(from, to) {
 
 <FORM ACTION="<% popurl(1) %>process/cust_main.cgi" METHOD=POST NAME="bottomform" onSubmit="document.bottomform.submit.disabled=true; bottomfixup(this.form);" STYLE="margin-top: 0; margin-bottom: 0">
 % foreach my $hidden (
+%     'birthdate',
+%
 %     'custnum', 'agentnum', 'refnum', 'referral_custnum',
 %     'last', 'first', 'ss', 'company',
 %     'address1', 'address2', 'city',
@@ -359,17 +380,20 @@ function copyelement(from, to) {
 
   <INPUT TYPE="hidden" NAME="<% $hidden %>" VALUE="">
 % } 
-
+%
+% my $ro_comments = $conf->exists('cust_main-use_comments')?'':'readonly';
+% if (!$ro_comments || $cust_main->comments) {
 
 <BR>Comments
 <% &ntable("#cccccc") %>
   <TR>
     <TD>
-      <TEXTAREA COLS=80 ROWS=5 WRAP="HARD" NAME="comments"><% $cust_main->comments %></TEXTAREA>
+      <TEXTAREA COLS=80 ROWS=5 WRAP="HARD" NAME="comments" <%$ro_comments%>><% $cust_main->comments %></TEXTAREA>
     </TD>
   </TR>
 </TABLE>
 %
+% }
 %
 %unless ( $custnum ) {
 %  # pry the wrong place for this logic.  also pretty expensive