2 % '' => emt('Billing'),
3 % 'ship_' => emt('Service'),
5 % foreach my $which ( '', 'ship_' ) {
6 % my $pre = $cust_main->get("${which}last") ? $which : '';
8 <% $which{$which} %> <% mt('address') |h %>
9 <% ntable("#cccccc") %><TR><TD><% ntable("#cccccc",2) %>
11 <TD ALIGN="right"><% mt('Contact name') |h %></TD>
12 <TD COLSPAN=5 BGCOLOR="#ffffff">
13 <% $cust_main->get("${pre}last"). ', '. $cust_main->get("${pre}first") |h %>
15 % if ( $which eq '' && $conf->exists('show_ss') ) {
16 <TD ALIGN="right"><% mt('SS#') |h %></TD>
17 <TD BGCOLOR="#ffffff"><% $cust_main->masked('ss') || ' ' %></TD>
20 % if ( $conf->exists('cust-email-high-visibility') && $which eq '') {
22 <TD ALIGN="right"><% mt('Email invoices') |h %></TD>
23 <TD BGCOLOR="#ffff00">
24 <% join(', ', grep { $_ !~ /^(POST|FAX)$/ } @invoicing_list ) || $no %>
29 <TD ALIGN="right"><% mt('Company') |h %></TD>
30 <TD COLSPAN=7 BGCOLOR="#ffffff"><% $cust_main->get("${pre}company") |h %></TD>
33 <TD ALIGN="right"><% mt('Address') |h %></TD>
34 <TD COLSPAN=7 BGCOLOR="#ffffff"><% $cust_main->get("${pre}address1") |h %></TD>
37 % if ( $cust_main->get("${pre}address2") ) {
38 % my $address2_label =
39 % ( $conf->exists('cust_main-require_address2')
40 % && ! ( $pre xor $cust_main->has_ship_address )
46 <TD ALIGN="right"><% $address2_label %></TD>
47 <TD COLSPAN=7 BGCOLOR="#ffffff"><% $cust_main->get("${pre}address2") |h %></TD>
53 <TD ALIGN="right"><% mt('City') |h %></TD>
54 <TD BGCOLOR="#ffffff"><% $cust_main->get("${pre}city") |h %></TD>
55 % if ( $cust_main->get("${pre}county") ) {
56 <TD ALIGN="right"><% mt('County') |h %></TD>
57 <TD BGCOLOR="#ffffff"><% $cust_main->get("${pre}county") |h %></TD>
59 <TD ALIGN="right"><% mt('State') |h %></TD>
60 <TD BGCOLOR="#ffffff"><% state_label( $cust_main->get("${pre}state"), $cust_main->get("${pre}country") ) |h %></TD>
61 <TD ALIGN="right"><% mt('Zip') |h %></TD>
62 <TD BGCOLOR="#ffffff"><% $cust_main->get("${pre}zip") %></TD>
65 <TD ALIGN="right"><% mt('Country') |h %></TD>
66 <TD BGCOLOR="#ffffff"><% code2country( $cust_main->get("${pre}country") ) %></TD>
69 <TD ALIGN="right"><% $daytime_label %></TD>
70 <TD COLSPAN=3 BGCOLOR="#ffffff">
71 <& /elements/phonenumber.html,
72 $cust_main->get("${pre}daytime"),
74 'calling_list_exempt'=>$cust_main->calling_list_exempt,
79 <TD ALIGN="right"><% $night_label %></TD>
80 <TD COLSPAN=3 BGCOLOR="#ffffff">
81 <& /elements/phonenumber.html,
82 $cust_main->get("${pre}night"),
84 'calling_list_exempt'=>$cust_main->calling_list_exempt,
89 <TD ALIGN="right"><% $mobile_label %></TD>
90 <TD COLSPAN=3 BGCOLOR="#ffffff">
91 <& /elements/phonenumber.html,
92 $cust_main->get("${pre}mobile"),
94 'calling_list_exempt'=>$cust_main->calling_list_exempt,
99 <TD ALIGN="right"><% mt('Fax') |h %></TD>
100 <TD COLSPAN=3 BGCOLOR="#ffffff">
101 <% $cust_main->get("${pre}fax") || ' ' %>
104 % if ( $which eq '' && $conf->exists('show_stateid') ) {
106 <TD ALIGN="right"><% $stateid_label %></TD>
107 <TD BGCOLOR="#ffffff"><% $cust_main->masked('stateid') || ' ' %></TD>
108 <TD ALIGN="right"><% $stateid_state_label %></TD>
109 <TD BGCOLOR="#ffffff"><% $cust_main->stateid_state || ' ' %></TD>
112 </TABLE></TD></TR></TABLE>
113 % if ( $which ne 'ship_' ) {
117 <& contacts_new.html, $cust_main &>
120 my $daytime_label = FS::Msgcat::_gettext('daytime') =~ /^(daytime)?$/
122 : FS::Msgcat::_gettext('daytime');
123 my $night_label = FS::Msgcat::_gettext('night') =~ /^(night)?$/
125 : FS::Msgcat::_gettext('night');
126 my $mobile_label = FS::Msgcat::_gettext('mobile') =~ /^(mobile)?$/
127 ? 'Mobile Phone'
128 : FS::Msgcat::_gettext('Mobile');
130 my $stateid_label = FS::Msgcat::_gettext('stateid') =~ /^(stateid)?$/
131 ? 'Driver’s License'
132 : FS::Msgcat::_gettext('stateid');
133 my $stateid_state_label = FS::Msgcat::_gettext('stateid_state') =~ /^(stateid_state)?$/
134 ? 'Driver’s License State'
135 : FS::Msgcat::_gettext('stateid_state');
140 my( $cust_main ) = @_;
141 my $conf = new FS::Conf;
142 my @invoicing_list = $cust_main->invoicing_list;