3 % 'ship_' => 'Service',
5 % foreach my $which ( '', 'ship_' ) {
6 % my $pre = $cust_main->get("${which}last") ? $which : '';
8 <% $which{$which} %> address
9 <% ntable("#cccccc") %><TR><TD><% ntable("#cccccc",2) %>
11 <TD ALIGN="right">Contact name</TD>
12 <TD COLSPAN=5 BGCOLOR="#ffffff">
13 <% $cust_main->get("${pre}last"). ', '. $cust_main->get("${pre}first") %>
15 % if ( $which eq '' && $conf->exists('show_ss') ) {
16 <TD ALIGN="right">SS#</TD>
17 <TD BGCOLOR="#ffffff"><% $cust_main->masked('ss') || ' ' %></TD>
21 <TD ALIGN="right">Company</TD>
22 <TD COLSPAN=7 BGCOLOR="#ffffff"><% $cust_main->get("${pre}company") %></TD>
25 <TD ALIGN="right">Address</TD>
26 <TD COLSPAN=7 BGCOLOR="#ffffff"><% $cust_main->get("${pre}address1") %></TD>
28 % if ( $cust_main->get("${pre}address2") ) {
31 <TD ALIGN="right"> </TD>
32 <TD COLSPAN=7 BGCOLOR="#ffffff"><% $cust_main->get("${pre}address2") %></TD>
37 <TD ALIGN="right">City</TD>
38 <TD BGCOLOR="#ffffff"><% $cust_main->get("${pre}city") %></TD>
39 % if ( $cust_main->get("${pre}county") ) {
40 <TD ALIGN="right">County</TD>
41 <TD BGCOLOR="#ffffff"><% $cust_main->get("${pre}county") %></TD>
43 <TD ALIGN="right">State</TD>
44 <TD BGCOLOR="#ffffff"><% state_label( $cust_main->get("${pre}state"), $cust_main->get("${pre}country") ) %></TD>
45 <TD ALIGN="right">Zip</TD>
46 <TD BGCOLOR="#ffffff"><% $cust_main->get("${pre}zip") %></TD>
49 <TD ALIGN="right">Country</TD>
50 <TD BGCOLOR="#ffffff"><% code2country( $cust_main->get("${pre}country") ) %></TD>
53 <TD ALIGN="right"><% $daytime_label %></TD>
54 <TD COLSPAN=3 BGCOLOR="#ffffff">
55 <% include('/elements/phonenumber.html',
56 $cust_main->get("${pre}daytime"),
63 <TD ALIGN="right"><% $night_label %></TD>
64 <TD COLSPAN=3 BGCOLOR="#ffffff">
65 <% include('/elements/phonenumber.html',
66 $cust_main->get("${pre}night"),
73 <TD ALIGN="right">Fax</TD>
74 <TD COLSPAN=3 BGCOLOR="#ffffff">
75 <% $cust_main->get("${pre}fax") || ' ' %>
78 % if ( $which eq '' && $conf->exists('show_stateid') ) {
80 <TD ALIGN="right"><% $stateid_label %></TD>
81 <TD BGCOLOR="#ffffff"><% $cust_main->masked('stateid') || ' ' %></TD>
82 <TD ALIGN="right"><% $stateid_state_label %></TD>
83 <TD BGCOLOR="#ffffff"><% $cust_main->stateid_state || ' ' %></TD>
86 </TABLE></TD></TR></TABLE>
87 % if ( $which ne 'ship_' ) {
94 my $daytime_label = FS::Msgcat::_gettext('daytime') =~ /^(daytime)?$/
96 : FS::Msgcat::_gettext('daytime');
97 my $night_label = FS::Msgcat::_gettext('night') =~ /^(night)?$/
99 : FS::Msgcat::_gettext('night');
100 my $stateid_label = FS::Msgcat::_gettext('stateid') =~ /^(stateid)?$/
101 ? 'Driver’s License'
102 : FS::Msgcat::_gettext('stateid');
103 my $stateid_state_label = FS::Msgcat::_gettext('stateid_state') =~ /^(stateid_state)?$/
104 ? 'Driver’s License State'
105 : FS::Msgcat::_gettext('stateid_state');
110 my( $cust_main ) = @_;
111 my $conf = new FS::Conf;