Author: doogie
Date: Mon May 14 21:02:59 2012 New Revision: 1338418 URL: http://svn.apache.org/viewvc?rev=1338418&view=rev Log: DEPRECATION: specialpurpose/googlecheckout: findByAnd variants replaced with findByAnd that takes a boolean useCache parameter. Modified: ofbiz/trunk/specialpurpose/googlecheckout/src/org/ofbiz/googlecheckout/GoogleCheckoutHelper.java ofbiz/trunk/specialpurpose/googlecheckout/src/org/ofbiz/googlecheckout/GoogleRequestServices.java Modified: ofbiz/trunk/specialpurpose/googlecheckout/src/org/ofbiz/googlecheckout/GoogleCheckoutHelper.java URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/googlecheckout/src/org/ofbiz/googlecheckout/GoogleCheckoutHelper.java?rev=1338418&r1=1338417&r2=1338418&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/googlecheckout/src/org/ofbiz/googlecheckout/GoogleCheckoutHelper.java (original) +++ ofbiz/trunk/specialpurpose/googlecheckout/src/org/ofbiz/googlecheckout/GoogleCheckoutHelper.java Mon May 14 21:02:59 2012 @@ -96,7 +96,7 @@ public class GoogleCheckoutHelper { String externalId = info.getGoogleOrderNumber(); GenericValue order = null; try { - List<GenericValue> orders = delegator.findByAnd("OrderHeader", UtilMisc.toMap("externalId", externalId, "salesChannelEnumId" , SALES_CHANNEL)); + List<GenericValue> orders = delegator.findByAnd("OrderHeader", UtilMisc.toMap("externalId", externalId, "salesChannelEnumId" , SALES_CHANNEL), null, false); order = EntityUtil.getFirst(orders); } catch (GenericEntityException e) { Debug.logError(e, module); @@ -142,7 +142,7 @@ public class GoogleCheckoutHelper { List<GenericValue> orders = null; GenericValue orderPaymentPreference = null; try { - orders = delegator.findByAnd("OrderHeader", UtilMisc.toMap("externalId", externalId, "salesChannelEnumId", SALES_CHANNEL)); + orders = delegator.findByAnd("OrderHeader", UtilMisc.toMap("externalId", externalId, "salesChannelEnumId", SALES_CHANNEL), null, false); } catch (GenericEntityException e) { Debug.logError(e, module); } @@ -171,7 +171,7 @@ public class GoogleCheckoutHelper { List<GenericValue> orders = null; GenericValue orderPaymentPreference = null; try { - orders = delegator.findByAnd("OrderHeader", UtilMisc.toMap("externalId", externalId, "salesChannelEnumId", SALES_CHANNEL)); + orders = delegator.findByAnd("OrderHeader", UtilMisc.toMap("externalId", externalId, "salesChannelEnumId", SALES_CHANNEL), null, false); } catch (GenericEntityException e) { Debug.logError(e, module); } @@ -201,7 +201,7 @@ public class GoogleCheckoutHelper { List<GenericValue> orders = null; GenericValue orderPaymentPreference = null; try { - orders = delegator.findByAnd("OrderHeader", UtilMisc.toMap("externalId", externalId, "salesChannelEnumId", SALES_CHANNEL)); + orders = delegator.findByAnd("OrderHeader", UtilMisc.toMap("externalId", externalId, "salesChannelEnumId", SALES_CHANNEL), null, false); } catch (GenericEntityException e) { Debug.logError(e, module); } @@ -236,7 +236,7 @@ public class GoogleCheckoutHelper { String externalId = info.getGoogleOrderNumber(); // check and make sure this order doesn't already exist - List<GenericValue> existingOrder = delegator.findByAnd("OrderHeader", UtilMisc.toMap("externalId", externalId)); + List<GenericValue> existingOrder = delegator.findByAnd("OrderHeader", UtilMisc.toMap("externalId", externalId), null, false); if (UtilValidate.isNotEmpty(existingOrder)) { //throw new GeneralException("Google order #" + externalId + " already exists."); Debug.logWarning("Google order #" + externalId + " already exists.", module); @@ -556,7 +556,7 @@ public class GoogleCheckoutHelper { // check to make sure the purpose doesn't already exist List<GenericValue> values = delegator.findByAnd("PartyContactMechPurpose", UtilMisc.toMap("partyId", partyId, - "contactMechId", contactMechId, "contactMechPurposeTypeId", contactMechPurposeTypeId)); + "contactMechId", contactMechId, "contactMechPurposeTypeId", contactMechPurposeTypeId), null, false); if (UtilValidate.isEmpty(values)) { Map<String, Object> addPurposeMap = FastMap.newInstance(); @@ -603,7 +603,7 @@ public class GoogleCheckoutHelper { List<GenericValue> cmLookup; try { - cmLookup = delegator.findByAnd(entityName, lookupMap, UtilMisc.toList("-fromDate")); + cmLookup = delegator.findByAnd(entityName, lookupMap, UtilMisc.toList("-fromDate"), false); cmLookup = EntityUtil.filterByDate(cmLookup); } catch (GenericEntityException e) { Debug.logError(e, module); @@ -656,7 +656,7 @@ public class GoogleCheckoutHelper { } List<GenericValue> geos = null; try { - geos = delegator.findByAnd("Geo", UtilMisc.toMap("geoCode", geoCode, "geoTypeId", "COUNTRY")); + geos = delegator.findByAnd("Geo", UtilMisc.toMap("geoCode", geoCode, "geoTypeId", "COUNTRY"), null, false); } catch (GenericEntityException e) { Debug.logError(e, module); } Modified: ofbiz/trunk/specialpurpose/googlecheckout/src/org/ofbiz/googlecheckout/GoogleRequestServices.java URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/googlecheckout/src/org/ofbiz/googlecheckout/GoogleRequestServices.java?rev=1338418&r1=1338417&r2=1338418&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/googlecheckout/src/org/ofbiz/googlecheckout/GoogleRequestServices.java (original) +++ ofbiz/trunk/specialpurpose/googlecheckout/src/org/ofbiz/googlecheckout/GoogleRequestServices.java Mon May 14 21:02:59 2012 @@ -130,7 +130,7 @@ public class GoogleRequestServices { // setup shipping options support List<GenericValue> shippingOptions = null; try { - shippingOptions = delegator.findByAnd("GoogleCoShippingMethod", UtilMisc.toMap("productStoreId", productStoreId)); + shippingOptions = delegator.findByAnd("GoogleCoShippingMethod", UtilMisc.toMap("productStoreId", productStoreId), null, false); } catch (GenericEntityException e) { Debug.logError(e, module); } @@ -302,7 +302,7 @@ public class GoogleRequestServices { List<GenericValue> returnItems = null; try { - returnItems = delegator.findByAnd("ReturnItem", UtilMisc.toMap("returnId", returnId)); + returnItems = delegator.findByAnd("ReturnItem", UtilMisc.toMap("returnId", returnId), null, false); } catch (GenericEntityException e) { Debug.logError(e, module); } @@ -511,7 +511,7 @@ public class GoogleRequestServices { } private static void sendItemsShipped(Delegator delegator, String shipmentId) throws GeneralException { - List<GenericValue> issued = delegator.findByAnd("ItemIssuance", UtilMisc.toMap("shipmentId", shipmentId)); + List<GenericValue> issued = delegator.findByAnd("ItemIssuance", UtilMisc.toMap("shipmentId", shipmentId), null, false); if (UtilValidate.isNotEmpty(issued)) { try { GenericValue googleOrder = null; @@ -534,7 +534,7 @@ public class GoogleRequestServices { } // locate the shipment package content record Map<String, ? extends Object> spcLup = UtilMisc.toMap("shipmentId", shipmentId, "shipmentItemSeqId", shipmentItemSeqId); - List<GenericValue> spc = delegator.findByAnd("ShipmentPackageContent", spcLup); + List<GenericValue> spc = delegator.findByAnd("ShipmentPackageContent", spcLup, null, false); GenericValue packageContent = EntityUtil.getFirst(spc); String carrier = null; if (UtilValidate.isNotEmpty(packageContent)) { |
Free forum by Nabble | Edit this page |