X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=httemplate%2Fedit%2Fcust_main%2Fcontact.html;h=a001634a229950e38f9071bcf2bd80f2d08767ba;hp=6e4f08957f464922c2474899930406629a63a0db;hb=3ce7691203a7737406bf2d4442f7fd84b81f847e;hpb=15e561850b61b10a92a46d8f3e316d53d4970087 diff --git a/httemplate/edit/cust_main/contact.html b/httemplate/edit/cust_main/contact.html index 6e4f08957..a001634a2 100644 --- a/httemplate/edit/cust_main/contact.html +++ b/httemplate/edit/cust_main/contact.html @@ -1,125 +1,128 @@ -<% - -my( $cust_main, $pre, $onchange, $disabled ) = @_; -my $conf = new FS::Conf; - -#false laziness with ship state -my $countrydefault = $conf->config('countrydefault') || 'US'; -$cust_main->set($pre.'country', $countrydefault ) - unless $cust_main->get($pre.'country'); - -my $statedefault = $conf->config('statedefault') - || ($countrydefault eq 'US' ? 'CA' : ''); -$cust_main->set($pre.'state', $statedefault ) - unless $cust_main->get($pre.'state') - || $cust_main->get($pre.'country') ne $countrydefault; - -#my($county_html, $state_html, $country_html) = -# FS::cust_main_county::regionselector( $cust_main->get($pre.'county'), -# $cust_main->get($pre.'state'), -# $cust_main->get($pre.'country'), -# $pre, -# $onchange, -# $disabled, -# ); - -my %select_hash = ( - 'county' => $cust_main->get($pre.'county'), - 'state' => $cust_main->get($pre.'state'), - 'country' => $cust_main->get($pre.'country'), - 'prefix' => $pre, - 'onchange' => $onchange, - 'disabled' => $disabled, -); - -my $daytime_label = FS::Msgcat::_gettext('daytime') || 'Day Phone'; -my $night_label = FS::Msgcat::_gettext('night') || 'Night Phone'; - -my $r = qq!* !; - -%> - -<%= &ntable("#cccccc") %> +% +% +%my( $cust_main, $pre, $onchange, $disabled ) = @_; +%my $conf = new FS::Conf; +% +%#false laziness with ship state +%my $countrydefault = $conf->config('countrydefault') || 'US'; +%$cust_main->set($pre.'country', $countrydefault ) +% unless $cust_main->get($pre.'country'); +% +%my $statedefault = $conf->config('statedefault') +% || ($countrydefault eq 'US' ? 'CA' : ''); +%$cust_main->set($pre.'state', $statedefault ) +% unless $cust_main->get($pre.'state') +% || $cust_main->get($pre.'country') ne $countrydefault; +% +%#my($county_html, $state_html, $country_html) = +%# FS::cust_main_county::regionselector( $cust_main->get($pre.'county'), +%# $cust_main->get($pre.'state'), +%# $cust_main->get($pre.'country'), +%# $pre, +%# $onchange, +%# $disabled, +%# ); +% +%my %select_hash = ( +% 'county' => $cust_main->get($pre.'county'), +% 'state' => $cust_main->get($pre.'state'), +% 'country' => $cust_main->get($pre.'country'), +% 'prefix' => $pre, +% 'onchange' => $onchange, +% 'disabled' => $disabled, +%); +% +%my $daytime_label = FS::Msgcat::_gettext('daytime') || 'Day Phone'; +%my $night_label = FS::Msgcat::_gettext('night') || 'Night Phone'; +% +%my $r = qq!* !; +% +% + + +<% &ntable("#cccccc") %> - <%=$r%>Contact name
(last, first) + <%$r%>Contact name
(last, first) - > , - > + > , + > +% if ( $conf->exists('show_ss') && !$pre ) { -<% if ( $conf->exists('show_ss') && !$pre ) { %> SS# - -<% } elsif ( !$pre ) { %> - -<% } %> + +% } elsif ( !$pre ) { + + +% } + Company - > + > - <%=$r%>Address + <%$r%>Address - > + >   - > + > - <%=$r%>City + <%$r%>City - > + > - <%=$r%>State + <%$r%>State - <%= include('select-county.html', %select_hash ) %> - <%= include('select-state.html', %select_hash ) %> + <% include('select-county.html', %select_hash ) %> + <% include('select-state.html', %select_hash ) %> - <%=$r%>Zip + <%$r%>Zip - > + > - <%=$r%>Country - <%= include('select-country.html', %select_hash ) %> + <%$r%>Country + <% include('select-country.html', %select_hash ) %> - <%= $daytime_label %> + <% $daytime_label %> - > + > - <%= $night_label %> + <% $night_label %> - > + > Fax - > + > -<%=$r%>required fields
+<%$r%>required fields