adjust default labelling
authorjeff <jeff>
Fri, 27 Apr 2007 22:54:50 +0000 (22:54 +0000)
committerjeff <jeff>
Fri, 27 Apr 2007 22:54:50 +0000 (22:54 +0000)
httemplate/edit/cust_main/contact.html

index 6efad44..58fee32 100644 (file)
@@ -151,10 +151,18 @@ my @counties = counties( $cust_main->get($pre.'state'),
                        );
 my $county_style = scalar(@counties) > 1 ? '' : 'STYLE="visibility:hidden"';
 
-my $daytime_label = FS::Msgcat::_gettext('daytime') || 'Day Phone';
-my $night_label = FS::Msgcat::_gettext('night') || 'Night Phone';
-my $stateid_label = FS::Msgcat::_gettext('stateid') || 'Driver&rsquo;s License';
-my $stateid_state_label = FS::Msgcat::_gettext('stateid_state') || 'Driver&rsquo;s License State';
+my $daytime_label = FS::Msgcat::_gettext('daytime') =~ /^(daytime)?$/
+                  ? 'Day Phone'
+                  : FS::Msgcat::_gettext('daytime');
+my $night_label = FS::Msgcat::_gettext('night') =~/^(night)?$/
+                ? 'Night Phone'
+                : FS::Msgcat::_gettext('night') || 'Night Phone';
+my $stateid_label = FS::Msgcat::_gettext('stateid') =~ /^(stateid)?$/
+                  ? 'Driver&rsquo;s License'
+                  : FS::Msgcat::_gettext('stateid') || 'Driver&rsquo;s License';
+my $stateid_state_label = FS::Msgcat::_gettext('stateid_state') =~ /^(stateid_state)?$/
+                        ? 'Driver&rsquo;s License State'
+                        : FS::Msgcat::_gettext('stateid_state') || 'Driver&rsquo;s License State';
 
 my $r = qq!<font color="#ff0000">*</font>&nbsp;!;