HTML templates for printable form letters, #17349
[freeside.git] / httemplate / edit / cust_main.cgi
index 1ad031d..2628b4e 100755 (executable)
@@ -28,7 +28,8 @@
 <& cust_main/top_misc.html, $cust_main, 'custnum' => $custnum  &>
 
 %# birthdate
-% if (    $conf->exists('cust_main-enable_birthdate')
+% if (    $conf->config('national_id-country')
+%      || $conf->exists('cust_main-enable_birthdate')
 %      || $conf->exists('cust_main-enable_spouse_birthdate')
 %      || $conf->exists('cust_main-enable_anniversary_date')
 %    )
@@ -52,6 +53,7 @@
     <& /elements/location.html,
         object => $cust_main->bill_location,
         prefix => 'bill_',
+        enable_coords => 1,
     &>
     <& cust_main/after_bill_location.html, $cust_main &>
     </TABLE>
@@ -76,6 +78,7 @@
         prefix => 'ship_',
         enable_censustract => 1,
         enable_district => 1,
+        enable_coords => 1,
     &>
     </TABLE>
     <TABLE CLASS="fsinnerbox" ID="table_ship_location_blank"
@@ -247,6 +250,8 @@ if ( $cgi->param('error') ) {
   $stateid = $cust_main->stateid; # don't mask an entered value on errors
   $payinfo = $cust_main->payinfo; # don't mask an entered value on errors
 
+  $cust_main->national_id( $cgi->param('national_id1') || $cgi->param('national_id2') );
+
   $prospectnum = $cgi->param('prospectnum') || '';
 
   $pkgpart_svcpart = $cgi->param('pkgpart_svcpart') || '';
@@ -310,6 +315,8 @@ if ( $cgi->param('error') ) {
   $stateid = '';
   $payinfo = '';
 
+  $cgi->param('tagnum', FS::part_tag->default_tags);
+
   if ( $cgi->param('qualnum') =~ /^(\d+)$/ ) {
     my $qualnum = $1;
     my $qual = qsearchs('qual', { 'qualnum' => $qualnum } )