diff --git a/applications/accounting/src/org/ofbiz/accounting/thirdparty/paypal/PayPalServices.java b/applications/accounting/src/org/ofbiz/accounting/thirdparty/paypal/PayPalServices.java index 4172df34c2..b0f40c063e 100644 --- a/applications/accounting/src/org/ofbiz/accounting/thirdparty/paypal/PayPalServices.java +++ b/applications/accounting/src/org/ofbiz/accounting/thirdparty/paypal/PayPalServices.java @@ -246,8 +246,8 @@ public class PayPalServices { if (estimate == null || estimate.compareTo(BigDecimal.ZERO) < 0) { continue; } - cart.setShipmentMethodTypeId(shipMethod.getString("shipmentMethodTypeId")); - cart.setCarrierPartyId(shipMethod.getString("partyId")); + cart.setAllShipmentMethodTypeId(shipMethod.getString("shipmentMethodTypeId")); + cart.setAllCarrierPartyId(shipMethod.getString("partyId")); try { coh.calcAndAddTax(); } catch (GeneralException e) { @@ -594,18 +594,18 @@ public class PayPalServices { // that was shown to the customer String shipMethod = decoder.get("SHIPPINGOPTIONNAME"); if ("Calculated Offline".equals(shipMethod)) { - cart.setCarrierPartyId("_NA_"); - cart.setShipmentMethodTypeId("NO_SHIPPING"); + cart.setAllCarrierPartyId("_NA_"); + cart.setAllShipmentMethodTypeId("NO_SHIPPING"); } else { String[] shipMethodSplit = shipMethod.split(" - "); - cart.setCarrierPartyId(shipMethodSplit[0]); + cart.setAllCarrierPartyId(shipMethodSplit[0]); String shippingMethodTypeDesc = StringUtils.join(shipMethodSplit, " - ", 1, shipMethodSplit.length); try { EntityCondition cond = EntityCondition.makeCondition( UtilMisc.toMap("productStoreId", cart.getProductStoreId(), "partyId", shipMethodSplit[0], "roleTypeId", "CARRIER", "description", shippingMethodTypeDesc) ); GenericValue shipmentMethod = EntityUtil.getFirst(delegator.findList("ProductStoreShipmentMethView", cond, null, null, null, false)); - cart.setShipmentMethodTypeId(shipmentMethod.getString("shipmentMethodTypeId")); + cart.setAllShipmentMethodTypeId(shipmentMethod.getString("shipmentMethodTypeId")); } catch (GenericEntityException e1) { Debug.logError(e1, module); } @@ -619,7 +619,7 @@ public class PayPalServices { } } cart.cleanUpShipGroups(); - cart.setShippingContactMechId(postalContactId); + cart.setAllShippingContactMechId(postalContactId); Map result = ShippingEvents.getShipGroupEstimate(dispatcher, delegator, cart, 0); if (result.get(ModelService.RESPONSE_MESSAGE).equals(ModelService.RESPOND_ERROR)) { return ServiceUtil.returnError((String) result.get(ModelService.ERROR_MESSAGE)); diff --git a/applications/order/src/org/ofbiz/order/order/OrderServices.java b/applications/order/src/org/ofbiz/order/order/OrderServices.java index c81e11df82..5c260ef53b 100644 --- a/applications/order/src/org/ofbiz/order/order/OrderServices.java +++ b/applications/order/src/org/ofbiz/order/order/OrderServices.java @@ -4874,7 +4874,7 @@ public class OrderServices { // set checkout options cart.setDefaultCheckoutOptions(dispatcher); // the shipping address is the one of the customer - cart.setShippingContactMechId(shipGroup.getString("contactMechId")); + cart.setAllShippingContactMechId(shipGroup.getString("contactMechId")); // associate ship groups of sales and purchase orders ShoppingCart.CartShipInfo cartShipInfo = cart.getShipGroups().get(0); cartShipInfo.setAssociatedShipGroupSeqId(shipGroup.getString("shipGroupSeqId")); diff --git a/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutEvents.java b/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutEvents.java index 377478fdf3..8303b2a72b 100644 --- a/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutEvents.java +++ b/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutEvents.java @@ -235,8 +235,8 @@ public class CheckOutEvents { // if no shipping applies, set the no shipment method and skip to payment if (!cart.shippingApplies()) { - cart.setShipmentMethodTypeId("NO_SHIPPING"); - cart.setCarrierPartyId("_NA_"); + cart.setAllShipmentMethodTypeId("NO_SHIPPING"); + cart.setAllCarrierPartyId("_NA_"); page = "payment"; } @@ -274,7 +274,7 @@ public class CheckOutEvents { ShoppingCart cart = (ShoppingCart) request.getSession().getAttribute("shoppingCart"); String shipToCustomerPartyId = request.getParameter("shipToCustomerPartyId"); cart.setShipToCustomerPartyId(shipToCustomerPartyId); - cart.setShippingContactMechId(null); + cart.setAllShippingContactMechId(null); return "success"; } diff --git a/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutHelper.java b/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutHelper.java index 7f2b81ff13..c69baf0cba 100644 --- a/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutHelper.java +++ b/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutHelper.java @@ -115,7 +115,7 @@ public class CheckOutHelper { // set the shipping address if (UtilValidate.isNotEmpty(shippingContactMechId)) { - this.cart.setShippingContactMechId(shippingContactMechId); + this.cart.setAllShippingContactMechId(shippingContactMechId); } else if (cart.shippingApplies()) { // only return an error if shipping is required for this purchase errMsg = UtilProperties.getMessage(resource_error,"checkhelper.select_shipping_destination", (cart != null ? cart.getLocale() : Locale.getDefault())); @@ -166,8 +166,8 @@ public class CheckOutHelper { carrierPartyId = shippingMethod.substring(delimiterPos + 1); } - this.cart.setShipmentMethodTypeId(shipmentMethodTypeId); - this.cart.setCarrierPartyId(carrierPartyId); + this.cart.setAllShipmentMethodTypeId(shipmentMethodTypeId); + this.cart.setAllCarrierPartyId(carrierPartyId); } else if (cart.shippingApplies()) { // only return an error if shipping is required for this purchase errMsg = UtilProperties.getMessage(resource_error,"checkhelper.select_shipping_method", (cart != null ? cart.getLocale() : Locale.getDefault())); @@ -175,20 +175,20 @@ public class CheckOutHelper { } // set the shipping instructions - this.cart.setShippingInstructions(shippingInstructions); + this.cart.setAllShippingInstructions(shippingInstructions); if (UtilValidate.isNotEmpty(maySplit)) { - cart.setMaySplit(Boolean.valueOf(maySplit)); + cart.setAllMaySplit(Boolean.valueOf(maySplit)); } else { errMsg = UtilProperties.getMessage(resource_error,"checkhelper.select_splitting_preference", (cart != null ? cart.getLocale() : Locale.getDefault())); errorMessages.add(errMsg); } // set the gift message - this.cart.setGiftMessage(giftMessage); + this.cart.setAllGiftMessage(giftMessage); if (UtilValidate.isNotEmpty(isGift)) { - cart.setIsGift(Boolean.valueOf(isGift)); + cart.setAllIsGift(Boolean.valueOf(isGift)); } else { errMsg = UtilProperties.getMessage(resource_error, "checkhelper.specify_if_order_is_gift", (cart != null ? cart.getLocale() : Locale.getDefault())); errorMessages.add(errMsg); diff --git a/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java b/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java index 367ecb42ea..6c8e61e5d6 100644 --- a/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java +++ b/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java @@ -18,10 +18,39 @@ *******************************************************************************/ package org.ofbiz.order.shoppingcart; +import java.io.Serializable; +import java.math.BigDecimal; +import java.math.MathContext; +import java.sql.Timestamp; +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.Comparator; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Iterator; +import java.util.LinkedHashMap; +import java.util.LinkedList; +import java.util.List; +import java.util.Locale; +import java.util.Map; +import java.util.Map.Entry; +import java.util.Set; +import java.util.TreeMap; + import javolution.util.FastList; import javolution.util.FastMap; -import org.ofbiz.base.util.*; +import org.ofbiz.base.util.Debug; +import org.ofbiz.base.util.GeneralException; +import org.ofbiz.base.util.GeneralRuntimeException; +import org.ofbiz.base.util.UtilDateTime; +import org.ofbiz.base.util.UtilFormatOut; +import org.ofbiz.base.util.UtilGenerics; +import org.ofbiz.base.util.UtilMisc; +import org.ofbiz.base.util.UtilNumber; +import org.ofbiz.base.util.UtilProperties; +import org.ofbiz.base.util.UtilValidate; import org.ofbiz.entity.Delegator; import org.ofbiz.entity.DelegatorFactory; import org.ofbiz.entity.GenericEntityException; @@ -46,13 +75,6 @@ import org.ofbiz.product.store.ProductStoreWorker; import org.ofbiz.service.LocalDispatcher; import org.ofbiz.service.ServiceUtil; -import java.io.Serializable; -import java.math.BigDecimal; -import java.math.MathContext; -import java.sql.Timestamp; -import java.util.*; -import java.util.Map.Entry; - /** * Shopping Cart Object */ @@ -2217,11 +2239,19 @@ public class ShoppingCart implements Iterable, Serializable { } csi.setContactMechId(shippingContactMechId); } - - public void setShippingContactMechId(String shippingContactMechId) { - this.setShippingContactMechId(0, shippingContactMechId); + + /** + * Sets @param shippingContactMechId in all ShipInfo(ShipGroups) associated + * with this ShoppingCart + *

+ * @param shippingContactMechId + */ + public void setAllShippingContactMechId(String shippingContactMechId) { + for(int x=0; x < shipInfo.size(); x++) { + this.setShippingContactMechId(x, shippingContactMechId); + } } - + /** Returns the shipping contact mech id. */ public String getShippingContactMechId(int idx) { CartShipInfo csi = this.getShipInfo(idx); @@ -2237,11 +2267,19 @@ public class ShoppingCart implements Iterable, Serializable { CartShipInfo csi = this.getShipInfo(idx); csi.shipmentMethodTypeId = shipmentMethodTypeId; } - - public void setShipmentMethodTypeId(String shipmentMethodTypeId) { - this.setShipmentMethodTypeId(0, shipmentMethodTypeId); + + /** + * Sets @param shipmentMethodTypeId in all ShipInfo(ShipGroups) associated + * with this ShoppingCart + *

+ * @param shipmentMethodTypeId + */ + public void setAllShipmentMethodTypeId(String shipmentMethodTypeId) { + for(int x=0; x < shipInfo.size(); x++) { + this.setShipmentMethodTypeId(x, shipmentMethodTypeId); + } } - + /** Returns the shipment method type ID */ public String getShipmentMethodTypeId(int idx) { CartShipInfo csi = this.getShipInfo(idx); @@ -2285,9 +2323,17 @@ public class ShoppingCart implements Iterable, Serializable { CartShipInfo csi = this.getShipInfo(idx); csi.shippingInstructions = shippingInstructions; } - - public void setShippingInstructions(String shippingInstructions) { - this.setShippingInstructions(0, shippingInstructions); + + /** + * Sets @param shippingInstructions in all ShipInfo(ShipGroups) associated + * with this ShoppingCart + *

+ * @param shippingInstructions + */ + public void setAllShippingInstructions(String shippingInstructions) { + for(int x=0; x < shipInfo.size(); x++) { + this.setShippingInstructions(x, shippingInstructions); + } } /** Returns the shipping instructions. */ @@ -2306,10 +2352,19 @@ public class ShoppingCart implements Iterable, Serializable { csi.setMaySplit(maySplit); } } - - public void setMaySplit(Boolean maySplit) { - this.setMaySplit(0, maySplit); + + /** + * Sets @param maySplit in all ShipInfo(ShipGroups) associated + * with this ShoppingCart + *

+ * @param maySplit + */ + public void setAllMaySplit(Boolean maySplit) { + for(int x=0; x < shipInfo.size(); x++) { + this.setMaySplit(x, maySplit); + } } + /** Returns Boolean.TRUE if the order may be split (null if unspecified) */ public String getMaySplit(int idx) { @@ -2326,10 +2381,18 @@ public class ShoppingCart implements Iterable, Serializable { csi.giftMessage = giftMessage; } - public void setGiftMessage(String giftMessage) { - this.setGiftMessage(0, giftMessage); + /** + * Sets @param giftMessage in all ShipInfo(ShipGroups) associated + * with this ShoppingCart + *

+ * @param giftMessage + */ + public void setAllGiftMessage(String giftMessage) { + for(int x=0; x < shipInfo.size(); x++) { + this.setGiftMessage(x, giftMessage); + } } - + public String getGiftMessage(int idx) { CartShipInfo csi = this.getShipInfo(idx); return csi.giftMessage; @@ -2346,10 +2409,18 @@ public class ShoppingCart implements Iterable, Serializable { } } - public void setIsGift(Boolean isGift) { - this.setIsGift(0, isGift); + /** + * Sets @param isGift in all ShipInfo(ShipGroups) associated + * with this ShoppingCart + *

+ * @param isGift + */ + public void setAllIsGift(Boolean isGift) { + for(int x=0; x < shipInfo.size(); x++) { + this.setIsGift(x, isGift); + } } - + public String getIsGift(int idx) { CartShipInfo csi = this.getShipInfo(idx); return csi.isGift; @@ -2363,11 +2434,19 @@ public class ShoppingCart implements Iterable, Serializable { CartShipInfo csi = this.getShipInfo(idx); csi.carrierPartyId = carrierPartyId; } - - public void setCarrierPartyId(String carrierPartyId) { - this.setCarrierPartyId(0, carrierPartyId); + + /** + * Sets @param carrierPartyId in all ShipInfo(ShipGroups) associated + * with this ShoppingCart + *

+ * @param carrierPartyId + */ + public void setAllCarrierPartyId(String carrierPartyId) { + for(int x=0; x < shipInfo.size(); x++) { + this.setCarrierPartyId(x, carrierPartyId); + } } - + public String getCarrierPartyId(int idx) { CartShipInfo csi = this.getShipInfo(idx); return csi.carrierPartyId; @@ -2390,9 +2469,17 @@ public class ShoppingCart implements Iterable, Serializable { CartShipInfo csi = this.getShipInfo(idx); csi.productStoreShipMethId = productStoreShipMethId; } - - public void setProductStoreShipMethId(String productStoreShipMethId) { - this.setProductStoreShipMethId(0, productStoreShipMethId); + + /** + * Sets @param productStoreShipMethId in all ShipInfo(ShipGroups) associated + * with this ShoppingCart + *

+ * @param productStoreShipMethId + */ + public void setAllProductStoreShipMethId(String productStoreShipMethId) { + for(int x=0; x < shipInfo.size(); x++) { + this.setProductStoreShipMethId(x, productStoreShipMethId); + } } public void setShipGroupFacilityId(int idx, String facilityId) { @@ -2490,7 +2577,7 @@ public class ShoppingCart implements Iterable, Serializable { Collection shippingContactMechList = ContactHelper.getContactMech(orderParty, "SHIPPING_LOCATION", "POSTAL_ADDRESS", false); if (UtilValidate.isNotEmpty(shippingContactMechList)) { GenericValue shippingContactMech = (shippingContactMechList.iterator()).next(); - this.setShippingContactMechId(shippingContactMech.getString("contactMechId")); + this.setAllShippingContactMechId(shippingContactMech.getString("contactMechId")); } } catch (GenericEntityException e) { Debug.logError(e, "Error setting shippingContactMechId in setDefaultCheckoutOptions() method.", module); @@ -2500,8 +2587,8 @@ public class ShoppingCart implements Iterable, Serializable { ShippingEstimateWrapper shipEstimateWrapper = org.ofbiz.order.shoppingcart.shipping.ShippingEstimateWrapper.getWrapper(dispatcher, this, 0); GenericValue carrierShipmentMethod = EntityUtil.getFirst(shipEstimateWrapper.getShippingMethods()); if (carrierShipmentMethod != null) { - this.setShipmentMethodTypeId(carrierShipmentMethod.getString("shipmentMethodTypeId")); - this.setCarrierPartyId(carrierShipmentMethod.getString("partyId")); + this.setAllShipmentMethodTypeId(carrierShipmentMethod.getString("shipmentMethodTypeId")); + this.setAllCarrierPartyId(carrierShipmentMethod.getString("partyId")); } } else { // checkout options for purchase orders @@ -2521,12 +2608,12 @@ public class ShoppingCart implements Iterable, Serializable { } } // shipping options - this.setShipmentMethodTypeId(0, "NO_SHIPPING"); - this.setCarrierPartyId(0, "_NA_"); - this.setShippingInstructions(0, ""); - this.setGiftMessage(0, ""); - this.setMaySplit(0, Boolean.TRUE); - this.setIsGift(0, Boolean.FALSE); + this.setAllShipmentMethodTypeId("NO_SHIPPING"); + this.setAllCarrierPartyId("_NA_"); + this.setAllShippingInstructions(""); + this.setAllGiftMessage(""); + this.setAllMaySplit(Boolean.TRUE); + this.setAllIsGift(Boolean.FALSE); //this.setInternalCode(internalCode); } } diff --git a/applications/order/src/org/ofbiz/order/shoppinglist/ShoppingListServices.java b/applications/order/src/org/ofbiz/order/shoppinglist/ShoppingListServices.java index 1e0c41fe07..edf9418e22 100644 --- a/applications/order/src/org/ofbiz/order/shoppinglist/ShoppingListServices.java +++ b/applications/order/src/org/ofbiz/order/shoppinglist/ShoppingListServices.java @@ -20,9 +20,9 @@ package org.ofbiz.order.shoppinglist; import java.math.BigDecimal; import java.sql.Timestamp; +import java.util.Date; import java.util.List; import java.util.Locale; -import java.util.Date; import java.util.Map; import javolution.util.FastMap; @@ -515,13 +515,13 @@ public class ShoppingListServices { listCart.addPayment(shoppingList.getString("paymentMethodId")); } if (UtilValidate.isNotEmpty(shoppingList.get("contactMechId"))) { - listCart.setShippingContactMechId(0, shoppingList.getString("contactMechId")); + listCart.setAllShippingContactMechId(shoppingList.getString("contactMechId")); } if (UtilValidate.isNotEmpty(shoppingList.get("shipmentMethodTypeId"))) { - listCart.setShipmentMethodTypeId(0, shoppingList.getString("shipmentMethodTypeId")); + listCart.setAllShipmentMethodTypeId(shoppingList.getString("shipmentMethodTypeId")); } if (UtilValidate.isNotEmpty(shoppingList.get("carrierPartyId"))) { - listCart.setCarrierPartyId(0, shoppingList.getString("carrierPartyId")); + listCart.setAllCarrierPartyId(shoppingList.getString("carrierPartyId")); } if (UtilValidate.isNotEmpty(shoppingList.getString("productPromoCodeId"))) { listCart.addProductPromoCode(shoppingList.getString("productPromoCodeId"), dispatcher); diff --git a/specialpurpose/ebay/src/org/ofbiz/ebay/EbayHelper.java b/specialpurpose/ebay/src/org/ofbiz/ebay/EbayHelper.java index d21a096f83..928a787dc3 100644 --- a/specialpurpose/ebay/src/org/ofbiz/ebay/EbayHelper.java +++ b/specialpurpose/ebay/src/org/ofbiz/ebay/EbayHelper.java @@ -187,8 +187,8 @@ public class EbayHelper { } catch (GenericEntityException e) { Debug.logInfo("Unable to find EbayShippingMethod", module); } - cart.setCarrierPartyId(partyId); - cart.setShipmentMethodTypeId(shipmentMethodTypeId); + cart.setAllCarrierPartyId(partyId); + cart.setAllShipmentMethodTypeId(shipmentMethodTypeId); } public static boolean createPaymentFromPaymentPreferences(Delegator delegator, LocalDispatcher dispatcher, GenericValue userLogin, diff --git a/specialpurpose/ebay/src/org/ofbiz/ebay/EbayOrderServices.java b/specialpurpose/ebay/src/org/ofbiz/ebay/EbayOrderServices.java index 79d7bd68c3..c1a74b5024 100644 --- a/specialpurpose/ebay/src/org/ofbiz/ebay/EbayOrderServices.java +++ b/specialpurpose/ebay/src/org/ofbiz/ebay/EbayOrderServices.java @@ -1201,8 +1201,8 @@ public class EbayOrderServices { cart.setEndUserCustomerPartyId(partyId); Debug.logInfo("Setting contact mech in cart: " + contactMechId, module); - cart.setShippingContactMechId(contactMechId); - cart.setMaySplit(Boolean.FALSE); + cart.setAllShippingContactMechId(contactMechId); + cart.setAllMaySplit(Boolean.FALSE); Debug.logInfo("Setting shipment method: " + (String) shippingServiceSelectedCtx.get("shippingService"), module); EbayHelper.setShipmentMethodType(cart, (String) shippingServiceSelectedCtx.get("shippingService"), productStoreId, delegator); diff --git a/specialpurpose/ebay/src/org/ofbiz/ebay/ImportOrdersFromEbay.java b/specialpurpose/ebay/src/org/ofbiz/ebay/ImportOrdersFromEbay.java index 3fd9b6c7cd..089847ef86 100755 --- a/specialpurpose/ebay/src/org/ofbiz/ebay/ImportOrdersFromEbay.java +++ b/specialpurpose/ebay/src/org/ofbiz/ebay/ImportOrdersFromEbay.java @@ -781,8 +781,8 @@ public class ImportOrdersFromEbay { cart.setEndUserCustomerPartyId(partyId); Debug.logInfo("Setting contact mech in cart: " + contactMechId, module); - cart.setShippingContactMechId(contactMechId); - cart.setMaySplit(Boolean.FALSE); + cart.setAllShippingContactMechId(contactMechId); + cart.setAllMaySplit(Boolean.FALSE); Debug.logInfo("Setting shipment method: " + (String) parameters.get("shippingService"), module); EbayHelper.setShipmentMethodType(cart, (String) parameters.get("shippingService"), productStoreId, delegator); diff --git a/specialpurpose/ebaystore/src/org/ofbiz/ebaystore/EbayStoreOrder.java b/specialpurpose/ebaystore/src/org/ofbiz/ebaystore/EbayStoreOrder.java index 71ba497631..4065de63ab 100644 --- a/specialpurpose/ebaystore/src/org/ofbiz/ebaystore/EbayStoreOrder.java +++ b/specialpurpose/ebaystore/src/org/ofbiz/ebaystore/EbayStoreOrder.java @@ -265,8 +265,8 @@ public class EbayStoreOrder { cart.setEndUserCustomerPartyId(partyId); Debug.logInfo("Setting contact mech in cart: " + contactMechId, module); - cart.setShippingContactMechId(contactMechId); - cart.setMaySplit(Boolean.FALSE); + cart.setAllShippingContactMechId(contactMechId); + cart.setAllMaySplit(Boolean.FALSE); Debug.logInfo("Setting shipment method: " + context.get("shippingService").toString(), module); EbayHelper.setShipmentMethodType(cart, context.get("shippingService").toString(), productStoreId, delegator); @@ -499,8 +499,8 @@ public class EbayStoreOrder { cart.setEndUserCustomerPartyId(partyId); Debug.logInfo("Setting contact mech in cart: " + contactMechId, module); - cart.setShippingContactMechId(contactMechId); - cart.setMaySplit(Boolean.FALSE); + cart.setAllShippingContactMechId(contactMechId); + cart.setAllMaySplit(Boolean.FALSE); Debug.logInfo("Setting shipment method: " + (String) shippingServiceSelectedCtx.get("shippingService"), module); EbayHelper.setShipmentMethodType(cart, (String) shippingServiceSelectedCtx.get("shippingService"), productStoreId, delegator); diff --git a/specialpurpose/googlecheckout/src/org/ofbiz/googlecheckout/GoogleCheckoutHelper.java b/specialpurpose/googlecheckout/src/org/ofbiz/googlecheckout/GoogleCheckoutHelper.java index badd22cf7a..3c6d0a8333 100644 --- a/specialpurpose/googlecheckout/src/org/ofbiz/googlecheckout/GoogleCheckoutHelper.java +++ b/specialpurpose/googlecheckout/src/org/ofbiz/googlecheckout/GoogleCheckoutHelper.java @@ -279,7 +279,7 @@ public class GoogleCheckoutHelper { cart.setOrderPartyId(partyInfo[0]); cart.setPlacingCustomerPartyId(partyInfo[0]); - cart.setShippingContactMechId(partyInfo[1]); + cart.setAllShippingContactMechId(partyInfo[1]); // contact info String shippingEmail = shippingAddress.getEmail(); @@ -418,10 +418,10 @@ public class GoogleCheckoutHelper { String carrierPartyId = googleShipping.getString("carrierPartyId"); Boolean maySplit = Boolean.FALSE; - cart.setShipmentMethodTypeId(shipmentMethodTypeId); - cart.setCarrierPartyId(carrierPartyId); - cart.setMaySplit(maySplit); - cart.setShippingContactMechId(shipContactMechId); + cart.setAllShipmentMethodTypeId(shipmentMethodTypeId); + cart.setAllCarrierPartyId(carrierPartyId); + cart.setAllMaySplit(maySplit); + cart.setAllShippingContactMechId(shipContactMechId); } else { Debug.logWarning("No valid fulfillment method found! No shipping info set!", module); } diff --git a/specialpurpose/pos/src/org/ofbiz/pos/PosTransaction.java b/specialpurpose/pos/src/org/ofbiz/pos/PosTransaction.java index 9e74f882f4..453b131a6a 100644 --- a/specialpurpose/pos/src/org/ofbiz/pos/PosTransaction.java +++ b/specialpurpose/pos/src/org/ofbiz/pos/PosTransaction.java @@ -820,8 +820,8 @@ public class PosTransaction implements Serializable { // attach the party ID to the cart cart.setOrderPartyId(partyId); // Set the shipping type - cart.setShipmentMethodTypeId("NO_SHIPPING"); - // cart.setCarrierPartyId(); + cart.setAllShipmentMethodTypeId("NO_SHIPPING"); + // cart.setAllCarrierPartyId(); // validate payment methods output.print(UtilProperties.getMessage(resource, "PosValidating", locale));