Author: lektran
Date: Fri Jan  9 10:44:15 2009
New Revision: 733109

URL: http://svn.apache.org/viewvc?rev=733109&view=rev
Log:
BigDecimal comparison fix

Modified:
    ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml

Modified: 
ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml
URL: 
http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml?rev=733109&r1=733108&r2=733109&view=diff
==============================================================================
--- ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml 
(original)
+++ ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml 
Fri Jan  9 10:44:15 2009
@@ -79,8 +79,8 @@
             <entity-one entity-name="GlAccount" value-name="glAccount">
                 <field-map field-name="glAccountId"/>
             </entity-one>
-            <set field="showDebit" value="${bsh:(postedBalance &gt;= 0 
&amp;&amp; org.ofbiz.accounting.util.UtilAccounting.isDebitAccount(glAccount)) 
|| (postedBalance &lt; 0 &amp;&amp; 
org.ofbiz.accounting.util.UtilAccounting.isCreditAccount(glAccount))}" 
type="Boolean"/>
-            <set field="showCredit" value="${bsh:(postedBalance &gt;= 0 
&amp;&amp; org.ofbiz.accounting.util.UtilAccounting.isCreditAccount(glAccount)) 
|| (postedBalance &lt; 0 &amp;&amp; 
org.ofbiz.accounting.util.UtilAccounting.isDebitAccount(glAccount))}" 
type="Boolean"/>
+            <set field="showDebit" 
value="${bsh:(postedBalance.compareTo(java.math.BigDecimal.ZERO) &gt;= 0 
&amp;&amp; org.ofbiz.accounting.util.UtilAccounting.isDebitAccount(glAccount)) 
|| (postedBalance.compareTo(java.math.BigDecimal.ZERO) &lt; 0 &amp;&amp; 
org.ofbiz.accounting.util.UtilAccounting.isCreditAccount(glAccount))}" 
type="Boolean"/>
+            <set field="showCredit" 
value="${bsh:(postedBalance.compareTo(java.math.BigDecimal.ZERO) &gt;= 0 
&amp;&amp; org.ofbiz.accounting.util.UtilAccounting.isCreditAccount(glAccount)) 
|| (postedBalance.compareTo(java.math.BigDecimal.ZERO) &lt; 0 &amp;&amp; 
org.ofbiz.accounting.util.UtilAccounting.isDebitAccount(glAccount))}" 
type="Boolean"/>
             <set field="absolutePostedBalance" 
value="${bsh:(postedBalance.abs())}" type="BigDecimal"/>
             <set field="showTotals" value="${bsh:(isLastRow != null &amp;&amp; 
isLastRow==true)}" type="Boolean"/>
             <set field="debitTotal" from-field="parameters.debitTotal" 
type="BigDecimal"/>


Reply via email to