summaryrefslogtreecommitdiff
path: root/httemplate/misc
diff options
context:
space:
mode:
authorivan <ivan>2011-04-11 01:24:50 +0000
committerivan <ivan>2011-04-11 01:24:50 +0000
commit4dfd652efeda65ee26be10d7941a25a4317f6d57 (patch)
treed5a014fb4b2066fbc333c64e5df92d8d664c7b0c /httemplate/misc
parent0b7d38278c191627a0e81eba16e894265fe9d300 (diff)
fix misfire of USPS address correction on non-new locations, RT#12183
Diffstat (limited to 'httemplate/misc')
-rw-r--r--httemplate/misc/order_pkg.html17
1 files changed, 16 insertions, 1 deletions
diff --git a/httemplate/misc/order_pkg.html b/httemplate/misc/order_pkg.html
index b232debd7..92ec095b7 100644
--- a/httemplate/misc/order_pkg.html
+++ b/httemplate/misc/order_pkg.html
@@ -107,7 +107,22 @@
%>
<BR>
-<INPUT NAME="submitButton" TYPE="button" VALUE="Order Package" onClick = "this.disabled=true; standardize_locations();" <% $pkgpart ? '' : 'DISABLED' %>>
+<INPUT NAME="submitButton" TYPE="button" VALUE="Order Package" onClick = "this.disabled=true; standardize_new_location();" <% $pkgpart ? '' : 'DISABLED' %>>
+
+<SCRIPT TYPE="text/javascript">
+
+ function standardize_new_location() {
+ var form = document.OrderPkgForm;
+ var loc = form.locationnum;
+ if (loc.type = 'select-one' && loc.options[loc.selectedIndex].value == -1) {
+ standardize_locations();
+ } else {
+ form.submit();
+ }
+ }
+
+</SCRIPT>
+
</FORM>
</BODY>