Author: ashish
Date: Wed Sep 9 05:24:43 2009 New Revision: 812777 URL: http://svn.apache.org/viewvc?rev=812777&view=rev Log: Improved the eBay code for OrderImport - as it was broken due to missing ShipmentMethodType values. Now I am able to import order successfully in ebay component. Thanks Jacopo for discussing things with me in this Ebay component(like workflow and many more) and providing useful notes in achieving the goals. My previous contribution in Ebay area was based on Jacopo's notes - more to come in a day or so. Modified: ofbiz/trunk/specialpurpose/ebay/src/org/ofbiz/ebay/ImportOrdersFromEbay.java ofbiz/trunk/specialpurpose/ecommerce/data/DemoShipping.xml Modified: ofbiz/trunk/specialpurpose/ebay/src/org/ofbiz/ebay/ImportOrdersFromEbay.java URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/ebay/src/org/ofbiz/ebay/ImportOrdersFromEbay.java?rev=812777&r1=812776&r2=812777&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/ebay/src/org/ofbiz/ebay/ImportOrdersFromEbay.java (original) +++ ofbiz/trunk/specialpurpose/ebay/src/org/ofbiz/ebay/ImportOrdersFromEbay.java Wed Sep 9 05:24:43 2009 @@ -1197,28 +1197,25 @@ if (shippingService != null) { if ("USPSPriority".equals(shippingService)) { partyId = "USPS"; - shipmentMethodTypeId = "PRIORITY"; + shipmentMethodTypeId = "STANDARD"; } else if ("UPSGround".equals(shippingService)) { partyId = "UPS"; shipmentMethodTypeId = "GROUND"; } else if ("UPS3rdDay".equals(shippingService)) { partyId = "UPS"; - shipmentMethodTypeId = "3DAY"; + shipmentMethodTypeId = "THIRD_DAY"; } else if ("UPS2ndDay".equals(shippingService)) { partyId = "UPS"; - shipmentMethodTypeId = "2DAY"; - } else if ("UPS2ndDay".equals(shippingService)) { - partyId = "UPS"; - shipmentMethodTypeId = "2DAY"; + shipmentMethodTypeId = "SECOND_DAY"; } else if ("USPSExpressMailInternational".equals(shippingService)) { partyId = "USPS"; shipmentMethodTypeId = "INT_EXPRESS"; } else if ("UPSNextDay".equals(shippingService)) { partyId = "UPS"; - shipmentMethodTypeId = "1DAY_SAVER"; + shipmentMethodTypeId = "NEXT_DAY"; } else if ("UPSNextDayAir".equals(shippingService)) { partyId = "UPS"; - shipmentMethodTypeId = "1DAY"; + shipmentMethodTypeId = "AIR"; } else if ("ShippingMethodStandard".equals(shippingService)) { partyId = "UPS"; shipmentMethodTypeId = "GROUND"; @@ -1227,10 +1224,9 @@ shipmentMethodTypeId = "INT_EXPRESS"; } else if ("LocalDelivery".equals(shippingService)) { partyId = "_NA_"; - shipmentMethodTypeId = "PICK_UP"; + shipmentMethodTypeId = "STANDARD"; } } - cart.setCarrierPartyId(partyId); cart.setShipmentMethodTypeId(shipmentMethodTypeId); } Modified: ofbiz/trunk/specialpurpose/ecommerce/data/DemoShipping.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/ecommerce/data/DemoShipping.xml?rev=812777&r1=812776&r2=812777&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/ecommerce/data/DemoShipping.xml (original) +++ ofbiz/trunk/specialpurpose/ecommerce/data/DemoShipping.xml Wed Sep 9 05:24:43 2009 @@ -42,6 +42,7 @@ <ShipmentMethodType description="Ground" shipmentMethodTypeId="GROUND"/> <ShipmentMethodType description="Standard" shipmentMethodTypeId="STANDARD"/> <ShipmentMethodType description="Air" shipmentMethodTypeId="AIR"/> + <ShipmentMethodType description="Third Day" shipmentMethodTypeId="THIRD_DAY"/> <ShipmentMethodType description="Second Day" shipmentMethodTypeId="SECOND_DAY"/> <ShipmentMethodType description="Guaranteed Next Day" shipmentMethodTypeId="NEXT_DAY"/> <ShipmentMethodType description="Next Afternoon" shipmentMethodTypeId="NEXT_PM"/> @@ -51,12 +52,15 @@ <ShipmentMethodType description="Priority Overnight" shipmentMethodTypeId="PR_OVERNIGHT"/> <ShipmentMethodType description="First Overnight" shipmentMethodTypeId="FI_OVERNIGHT"/> <ShipmentMethodType description="Same Day" shipmentMethodTypeId="SAME_DAY"/> + <ShipmentMethodType description="International Express" shipmentMethodTypeId="INT_EXPRESS"/> <CarrierShipmentMethod partyId="Company" roleTypeId="CARRIER" shipmentMethodTypeId="LOCAL_DELIVERY" sequenceNumber="4"/> <!-- For USPS, only certain container types are allowed for rate estimates of Priority or Express service codes --> <CarrierShipmentMethod partyId="USPS" roleTypeId="CARRIER" shipmentMethodTypeId="STANDARD" sequenceNumber="7" carrierServiceCode="Parcel"/> <CarrierShipmentMethod partyId="USPS" roleTypeId="CARRIER" shipmentMethodTypeId="EXPRESS" sequenceNumber="6" carrierServiceCode="Express"/> - <CarrierShipmentMethod partyId="UPS" roleTypeId="CARRIER" shipmentMethodTypeId="GROUND" sequenceNumber="3" carrierServiceCode="03"/> + <CarrierShipmentMethod partyId="USPS" roleTypeId="CARRIER" shipmentMethodTypeId="INT_EXPRESS" sequenceNumber="8" carrierServiceCode="INTEXPRESS"/> + <CarrierShipmentMethod partyId="UPS" roleTypeId="CARRIER" shipmentMethodTypeId="GROUND" sequenceNumber="4" carrierServiceCode="03"/> + <CarrierShipmentMethod partyId="UPS" roleTypeId="CARRIER" shipmentMethodTypeId="THIRD_DAY" sequenceNumber="3" carrierServiceCode="THIRDDAY"/> <CarrierShipmentMethod partyId="UPS" roleTypeId="CARRIER" shipmentMethodTypeId="SECOND_DAY" sequenceNumber="2" carrierServiceCode="02"/> <CarrierShipmentMethod partyId="UPS" roleTypeId="CARRIER" shipmentMethodTypeId="NEXT_DAY" sequenceNumber="1" carrierServiceCode="01"/> <CarrierShipmentMethod partyId="_NA_" roleTypeId="CARRIER" shipmentMethodTypeId="STANDARD" sequenceNumber="5"/> |
Free forum by Nabble | Edit this page |