Author: jacopoc
Date: Thu Jun 25 00:08:14 2009
New Revision: 788217
URL:
http://svn.apache.org/viewvc?rev=788217&view=revLog:
Fix for bug that was preventing the copy/revert accounting transaction to work properly. OFBIZ-2638
Modified:
ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml
Modified: ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml
URL:
http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml?rev=788217&r1=788216&r2=788217&view=diff==============================================================================
--- ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml (original)
+++ ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml Thu Jun 25 00:08:14 2009
@@ -2198,6 +2198,7 @@
</entity-one>
<!--Cloning AcctgTrans-->
<clone-value value-field="acctgTrans" new-value-field="newAcctgTrans"/>
+ <clear-field field="newAcctgTrans.acctgTransId"/>
<set-service-fields to-map="createAcctgTransInMap" service-name="createAcctgTrans" map="newAcctgTrans"/>
<now-timestamp field="nowTimestamp"/>
<set field="createAcctgTransInMap.transactionDate" from-field="nowTimestamp"/>
@@ -2205,14 +2206,14 @@
<set field="originalAcctgTransId" from-field="parameters.fromAcctgTransId"/>
<field-to-result field="originalAcctgTransId" result-name="acctgTransId"/>
- <clear-field field="newAcctgTrans.acctgTransId"/>
<call-service service-name="createAcctgTrans" in-map-name="createAcctgTransInMap">
- <result-to-field result-name="newAcctgTrans.acctgTransId"/>
+ <result-to-field result-name="acctgTransId" field="newAcctgTrans.acctgTransId"/>
</call-service>
<get-related list="acctgTransEntries" relation-name="AcctgTransEntry" value-field="acctgTrans"/>
<iterate list="acctgTransEntries" entry="acctgTransEntry">
<!--Cloning AcctgTransEntry-->
<clone-value value-field="acctgTransEntry" new-value-field="newAcctgTransEntry"/>
+ <clear-field field="newAcctgTransEntry.acctgTransId"/>
<set-service-fields to-map="createAcctgTransAndEntryInMap" service-name="createAcctgTransEntry" map="newAcctgTransEntry"/>
<set field="createAcctgTransAndEntryInMap.acctgTransId" from-field="newAcctgTrans.acctgTransId"/>
<if-compare field="parameters.revert" operator="equals" value="Y">