<& /elements/location.html,
object => $cust_main->bill_location,
prefix => 'bill_',
+ enable_coords => 1,
&>
<& cust_main/after_bill_location.html, $cust_main &>
</TABLE>
prefix => 'ship_',
enable_censustract => 1,
enable_district => 1,
+ enable_coords => 1,
&>
</TABLE>
<TABLE CLASS="fsinnerbox" ID="table_ship_location_blank"
'no_asterisks' => 0, #set true to disable the red asterisks next
#to required fields
'address1_label' => 'Address', #label for address
+ 'enable_coords' => 1, #show latitude/longitude fields
'enable_district' => 1, #show tax district field
'enable_censustract' => 1, #show censustract field
+
)
</%doc>
<TD COLSPAN=6><% include('/elements/select-country.html', %select_hash ) %></TD>
</TR>
+% if ( $opt{enable_coords} ) {
<TR>
<TD ALIGN="right"><% mt('Latitude') |h %></TH>
<TD COLSPAN=7>
>
</TD>
</TR>
+% } else {
+% foreach (qw(latitude longitude)) {
+<INPUT TYPE="hidden" NAME="<% $_ %>" VALUE="<% $object->get($_) |h%>">
+% }
+% }
<INPUT TYPE="hidden" NAME="<%$pre%>coord_auto" VALUE="<% $object->coord_auto %>">
<INPUT TYPE="hidden" NAME="<%$pre%>geocode" VALUE="<% $object->geocode %>">
'no_asterisks' => 1,
'no_bold' => $opt{'no_bold'},
'alt_format' => $opt{'alt_format'},
+ 'enable_coords'=> 1,
)
%>
<SCRIPT TYPE="text/javascript">
</TR>
<& /elements/location.html,
- 'object' => $cust_main, #XXX errors???
+ 'object' => $cust_main->bill_location,
'no_asterisks' => 1,
'address1_label' => emt('Card billing address'),
&>
my $cust_main = qsearchs( 'cust_main', { 'custnum'=>$custnum } );
die "unknown custnum $custnum" unless $cust_main;
+my $location = $cust_main->bill_location;
+# no proper error handling on this anyway, but when we have it,
+# remember to repopulate fields in $location
+
my $balance = $cust_main->balance;
my $payinfo = '';