You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by jl...@apache.org on 2014/03/03 14:07:39 UTC
svn commit: r1573553 -
/ofbiz/trunk/applications/order/src/org/ofbiz/order/order/OrderServices.java
Author: jleroux
Date: Mon Mar 3 13:07:39 2014
New Revision: 1573553
URL: http://svn.apache.org/r1573553
Log:
Reverts r1573552
I have applied the wrong patch :/
Modified:
ofbiz/trunk/applications/order/src/org/ofbiz/order/order/OrderServices.java
Modified: ofbiz/trunk/applications/order/src/org/ofbiz/order/order/OrderServices.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/src/org/ofbiz/order/order/OrderServices.java?rev=1573553&r1=1573552&r2=1573553&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/src/org/ofbiz/order/order/OrderServices.java (original)
+++ ofbiz/trunk/applications/order/src/org/ofbiz/order/order/OrderServices.java Mon Mar 3 13:07:39 2014
@@ -2174,18 +2174,15 @@ public class OrderServices {
"OrderYouDoNotHavePermissionToChangeThisOrdersStatus",locale));
}
- List<EntityExpr> exprs = new ArrayList<EntityExpr>();
- exprs.add(EntityCondition.makeCondition("orderId", orderId));
+ Map<String, String> fields = UtilMisc.<String, String>toMap("orderId", orderId);
if (orderItemSeqId != null)
- exprs.add(EntityCondition.makeCondition("orderItemSeqId", orderItemSeqId));
+ fields.put("orderItemSeqId", orderItemSeqId);
if (fromStatusId != null)
- exprs.add(EntityCondition.makeCondition("statusId", fromStatusId));
- else
- exprs.add(EntityCondition.makeCondition("statusId", EntityOperator.NOT_IN, UtilMisc.toList("ITEM_COMPLETED", "ITEM_CANCELLED")));
+ fields.put("statusId", fromStatusId);
List<GenericValue> orderItems = null;
try {
- orderItems = delegator.findList("OrderItem", EntityCondition.makeCondition(exprs, EntityOperator.AND), null, null, null, false);
+ orderItems = delegator.findByAnd("OrderItem", fields, null, false);
} catch (GenericEntityException e) {
return ServiceUtil.returnError(UtilProperties.getMessage(resource_error,
"OrderErrorCannotGetOrderItemEntity",locale) + e.getMessage());