Author: sascharodekamp
Date: Thu Nov 17 09:48:49 2011 New Revision: 1203128 URL: http://svn.apache.org/viewvc?rev=1203128&view=rev Log: OnePageCheckout creates new billing/shipping phone number even if user selects the default values (https://issues.apache.org/jira/browse/OFBIZ-4446, https://issues.apache.org/jira/browse/OFBIZ-4447) A patch from Kiran Gawd. Modified: ofbiz/branches/release11.04/applications/order/script/org/ofbiz/order/order/CheckoutServices.xml ofbiz/branches/release11.04/specialpurpose/ecommerce/webapp/ecommerce/images/checkoutProcess.js ofbiz/branches/release11.04/specialpurpose/ecommerce/webapp/ecommerce/order/OnePageCheckoutProcess.ftl Modified: ofbiz/branches/release11.04/applications/order/script/org/ofbiz/order/order/CheckoutServices.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/release11.04/applications/order/script/org/ofbiz/order/order/CheckoutServices.xml?rev=1203128&r1=1203127&r2=1203128&view=diff ============================================================================== --- ofbiz/branches/release11.04/applications/order/script/org/ofbiz/order/order/CheckoutServices.xml (original) +++ ofbiz/branches/release11.04/applications/order/script/org/ofbiz/order/order/CheckoutServices.xml Thu Nov 17 09:48:49 2011 @@ -67,6 +67,7 @@ under the License. <set field="createUpdatePartyTelecomNumberCtx.partyId" from-field="partyId"/> <set field="createUpdatePartyTelecomNumberCtx.roleTypeId" value="CUSTOMER"/> <set field="createUpdatePartyTelecomNumberCtx.contactMechPurposeTypeId" value="PHONE_SHIPPING"/> + <set field="createUpdatePartyTelecomNumberCtx.contactMechId" from-field="parameters.shipToPhoneContactMechId" /> <call-service service-name="createUpdatePartyTelecomNumber" in-map-name="createUpdatePartyTelecomNumberCtx"> <result-to-field result-name="contactMechId" field="shipToPhoneContactMechId"/> <result-to-result result-name="contactMechId" service-result-name="shipToPhoneContactMechId"/> @@ -160,6 +161,7 @@ under the License. <set field="createUpdatePartyTelecomNumberCtx.partyId" from-field="partyId"/> <set field="createUpdatePartyTelecomNumberCtx.roleTypeId" value="CUSTOMER"/> <set field="createUpdatePartyTelecomNumberCtx.contactMechPurposeTypeId" value="PHONE_BILLING"/> + <set field="createUpdatePartyTelecomNumberCtx.contactMechId" from-field="parameters.billToPhoneContactMechId" /> <call-service service-name="createUpdatePartyTelecomNumber" in-map-name="createUpdatePartyTelecomNumberCtx"> <result-to-field result-name="contactMechId" field="billToPhoneContactMechId"/> <result-to-result result-name="contactMechId" service-result-name="billToPhoneContactMechId"/> Modified: ofbiz/branches/release11.04/specialpurpose/ecommerce/webapp/ecommerce/images/checkoutProcess.js URL: http://svn.apache.org/viewvc/ofbiz/branches/release11.04/specialpurpose/ecommerce/webapp/ecommerce/images/checkoutProcess.js?rev=1203128&r1=1203127&r2=1203128&view=diff ============================================================================== --- ofbiz/branches/release11.04/specialpurpose/ecommerce/webapp/ecommerce/images/checkoutProcess.js (original) +++ ofbiz/branches/release11.04/specialpurpose/ecommerce/webapp/ecommerce/images/checkoutProcess.js Thu Nov 17 09:48:49 2011 @@ -262,7 +262,7 @@ function createUpdateCustomerAndShipping jQuery('#shipToPartyId').val(json.partyId); jQuery('#billToPartyId').val(json.partyId); jQuery('#shipToContactMechId').val(json.contactMechId); - jQuery('#shipToPhoneContactMechId').val(json.phoneContactMechId); + jQuery('#shipToPhoneContactMechId').val(json.shipToPhoneContactMechId); jQuery('#emailContactMechId').val(json.emailContactMechId); //jQuery('#completedShippingMethod').html(json.shippingDescription); updateShippingSummary(); @@ -378,7 +378,7 @@ function processBillingAndPayment() { isBillStepValidate = true; jQuery('#billToContactMechId').val(json.contactMechId); jQuery('#paymentMethodId').val(json.paymentMethodId); - jQuery('#billToPhoneContactMechId').val(json.phoneContactMechId); + jQuery('#billToPhoneContactMechId').val(json.billToPhoneContactMechId); updateBillingSummary(); result = true; }, Modified: ofbiz/branches/release11.04/specialpurpose/ecommerce/webapp/ecommerce/order/OnePageCheckoutProcess.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/release11.04/specialpurpose/ecommerce/webapp/ecommerce/order/OnePageCheckoutProcess.ftl?rev=1203128&r1=1203127&r2=1203128&view=diff ============================================================================== --- ofbiz/branches/release11.04/specialpurpose/ecommerce/webapp/ecommerce/order/OnePageCheckoutProcess.ftl (original) +++ ofbiz/branches/release11.04/specialpurpose/ecommerce/webapp/ecommerce/order/OnePageCheckoutProcess.ftl Thu Nov 17 09:48:49 2011 @@ -226,8 +226,10 @@ under the License. <input type="hidden" id="shipToContactMechId" name="shipToContactMechId" value="${shipToContactMechId?if_exists}" /> <input type="hidden" id="billToContactMechIdInShipingForm" name="billToContactMechId" value="${billToContactMechId?if_exists}" /> <input type="hidden" id="shipToPartyId" name="partyId" value="${partyId?if_exists}" /> - <input type="hidden" id="shipToPhoneContactMechId" name="phoneContactMechId" value="${(shipToTelecomNumber.contactMechId)?if_exists}" /> + <input type="hidden" id="shipToPhoneContactMechId" name="shipToPhoneContactMechId" value="${(shipToTelecomNumber.contactMechId)?if_exists}" /> <input type="hidden" id="emailContactMechId" name="emailContactMechId" value="${emailContactMechId?if_exists}" /> + <input type="hidden" name="shipToName" value="${shipToName?if_exists}" /> + <input type="hidden" name="shipToAttnName" value="${shipToAttnName?if_exists}" /> <#if userLogin?exists> <input type="hidden" name="keepAddressBook" value="Y" /> <input type="hidden" name="setDefaultShipping" value="Y" /> @@ -451,7 +453,9 @@ under the License. <input type="hidden" id="paymentMethodTypeId" name="paymentMethodTypeId" value="${paymentMethodTypeId?default("CREDIT_CARD")}" /> <input type="hidden" id="billToPartyId" name="partyId" value="${parameters.partyId?if_exists}" /> <input type="hidden" name="expireDate" value="${expireDate?if_exists}" /> - <input type="hidden" id="billToPhoneContactMechId" name="phoneContactMechId" value="${(billToTelecomNumber.contactMechId)?if_exists}" /> + <input type="hidden" id="billToPhoneContactMechId" name="billToPhoneContactMechId" value="${(billToTelecomNumber.contactMechId)?if_exists}" /> + <input type="hidden" name="billToName" value="${billToName?if_exists}" /> + <input type="hidden" name="billToAttnName" value="${billToAttnName?if_exists}" /> <#if userLogin?exists> <input type="hidden" name="keepAddressBook" value="Y" /> <input type="hidden" name="setDefaultBilling" value="Y" /> |
Free forum by Nabble | Edit this page |