Author: lektran
Date: Sat Jan 16 01:02:07 2010
New Revision: 899860
URL:
http://svn.apache.org/viewvc?rev=899860&view=revLog:
Applied partial patch from Bob Morley (OFBIZ-3371), removed currencyUomId condition from FinAccountTransSum lookup (the view doesn't have a currencyUomId field)
Modified:
ofbiz/trunk/applications/order/src/org/ofbiz/order/finaccount/FinAccountHelper.java
Modified: ofbiz/trunk/applications/order/src/org/ofbiz/order/finaccount/FinAccountHelper.java
URL:
http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/src/org/ofbiz/order/finaccount/FinAccountHelper.java?rev=899860&r1=899859&r2=899860&view=diff==============================================================================
--- ofbiz/trunk/applications/order/src/org/ofbiz/order/finaccount/FinAccountHelper.java (original)
+++ ofbiz/trunk/applications/order/src/org/ofbiz/order/finaccount/FinAccountHelper.java Sat Jan 16 01:02:07 2010
@@ -185,7 +185,6 @@
BigDecimal decrementTotal = ZERO; // decrease balance
GenericValue finAccount = delegator.findByPrimaryKeyCache("FinAccount", UtilMisc.toMap("finAccountId", finAccountId));
- String currencyUomId = finAccount.getString("currencyUomId");
// find the sum of all transactions which increase the value
EntityConditionList incrementConditions = EntityCondition.makeCondition(UtilMisc.toList(
@@ -203,7 +202,6 @@
EntityConditionList decrementConditions = EntityCondition.makeCondition(UtilMisc.toList(
EntityCondition.makeCondition("finAccountId", EntityOperator.EQUALS, finAccountId),
EntityCondition.makeCondition("transactionDate", EntityOperator.LESS_THAN_EQUAL_TO, asOfDateTime),
- EntityCondition.makeCondition("currencyUomId", EntityOperator.EQUALS, currencyUomId),
EntityCondition.makeCondition("finAccountTransTypeId", EntityOperator.EQUALS, "WITHDRAWAL")),
EntityOperator.AND);
transSums = delegator.findList("FinAccountTransSum", decrementConditions, UtilMisc.toSet("amount"), null, null, false);