2047
2047
$form->{title} = $locale->text('Shipping Address');
2049
2049
$form->{name} ||= "$form->{firstname} $form->{lastname}";
2051
CT->ship_to(\%myconfig, \%$form);
2054
address1 => { i => 2, label => $locale->text('Address') },
2055
address2 => { i => 3, label => '' },
2056
city => { i => 4, label => $locale->text('City') },
2057
state => { i => 5, label => $locale->text('State/Province') },
2058
zipcode => { i => 6, label => $locale->text('Zip/Postal Code') },
2059
country => { i => 7, label => $locale->text('Country') },
2060
contact => { i => 8, label => $locale->text('Contact') },
2061
phone => { i => 9, label => $locale->text('Phone') },
2062
fax => { i => 10, label => $locale->text('Fax') },
2063
email => { i => 11, label => $locale->text('E-mail') } );
2067
$vcname = $locale->text('Name');
2065
2081
<table width=100%>
2067
<th class=listheading colspan=2>$form->{name}</th>
2083
<th class=listheading colspan=3>$form->{name}</th>
2070
<th align=right nowrap>|.$locale->text('Name').qq|</th>
2087
<th align=right nowrap>$vcname</th>
2071
2088
<td><input name=shiptoname size=32 maxlength=64 value="|.$form->quote($form->{shiptoname}).qq|"></td>
2074
<th align=right nowrap>|.$locale->text('Address').qq|</th>
2092
<th align=right nowrap>$shipto{address1}{label}</th>
2075
2093
<td><input name=shiptoaddress1 size=32 maxlength=32 value="|.$form->quote($form->{shiptoaddress1}).qq|"></td>
2079
2098
<td><input name=shiptoaddress2 size=32 maxlength=32 value="|.$form->quote($form->{shiptoaddress2}).qq|"></td>
2082
<th align=right nowrap>|.$locale->text('City').qq|</th>
2102
<th align=right nowrap>$shipto{city}{label}</th>
2083
2103
<td><input name=shiptocity size=32 maxlength=32 value="|.$form->quote($form->{shiptocity}).qq|"></td>
2086
<th align=right nowrap>|.$locale->text('State/Province').qq|</th>
2107
<th align=right nowrap>$shipto{state}{label}</th>
2087
2108
<td><input name=shiptostate size=32 maxlength=32 value="|.$form->quote($form->{shiptostate}).qq|"></td>
2090
<th align=right nowrap>|.$locale->text('Zip/Postal Code').qq|</th>
2112
<th align=right nowrap>$shipto{zipcode}{label}</th>
2091
2113
<td><input name=shiptozipcode size=11 maxlength=10 value="|.$form->quote($form->{shiptozipcode}).qq|"></td>
2094
<th align=right nowrap>|.$locale->text('Country').qq|</th>
2117
<th align=right nowrap>$shipto{country}{label}</th>
2095
2118
<td><input name=shiptocountry size=32 maxlength=32 value="|.$form->quote($form->{shiptocountry}).qq|"></td>
2098
<th align=right nowrap>|.$locale->text('Contact').qq|</th>
2122
<th align=right nowrap>$shipto{contact}{label}</th>
2099
2123
<td><input name=shiptocontact size=35 maxlength=64 value="|.$form->quote($form->{shiptocontact}).qq|"></td>
2102
<th align=right nowrap>|.$locale->text('Phone').qq|</th>
2127
<th align=right nowrap>$shipto{phone}{label}</th>
2103
2128
<td><input name=shiptophone size=22 maxlength=20 value="$form->{shiptophone}"></td>
2106
<th align=right nowrap>|.$locale->text('Fax').qq|</th>
2132
<th align=right nowrap>$shipto{fax}{label}</th>
2107
2133
<td><input name=shiptofax size=22 maxlength=20 value="$form->{shiptofax}"></td>
2110
<th align=right nowrap>|.$locale->text('E-mail').qq|</th>
2137
<th align=right nowrap>$shipto{email}{label}</th>
2111
2138
<td><input name=shiptoemail size=32 value="$form->{shiptoemail}"></td>
2143
for $ref (@{ $form->{all_shipto} }) {
2148
<td><hr noshade></td>
2149
<td><hr noshade></td>
2153
<td><input name="ndx_$i" type=checkbox class=checkbox>
2154
<th align=right nowrap>$vcname</th>
2155
<td>$ref->{shiptoname}</td>
2159
for (sort { $shipto{$a}{i} <=> $shipto{$b}{i} } keys %shipto) {
2163
<th align=right nowrap>$shipto{$_}{label}</th>
2164
<td>$ref->{"shipto$_"}</td>
2169
for (keys %$ref) { $form->{"${_}_$i"} = $ref->{$_} }
2170
$form->hide_form(map { "${_}_$i" } keys %$ref);
2174
$form->{shipto_rows} = $i - 1;
2117
<td><hr size=3 noshade></td>
2122
for (map { "shipto$_" } qw(name address1 address2 city state zipcode country contact phone fax email)) { delete $form->{$_} }
2183
for (qw(name address1 address2 city state zipcode country contact phone fax email)) {
2184
delete $form->{"shipto$_"};
2185
$form->{flds} .= "$_ ";
2124
$form->{nextsub} = "update";
2189
$form->{nextsub} = "shipto_selected";
2125
2190
$form->{action} = $form->{nextsub};
2127
2192
$form->hide_form;
2130
<input type=submit class=submit name=action value="|.$locale->text('Continue').qq|">
2198
<input type=submit class=submit name=action value="|.$locale->text('Continue').qq|">