You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by pr...@apache.org on 2015/04/24 16:28:01 UTC

svn commit: r1675869 - in /ofbiz/branches/release14.12/applications/accounting/servicedef: secas.xml secas_invoice.xml

Author: pranayp
Date: Fri Apr 24 14:28:01 2015
New Revision: 1675869

URL: http://svn.apache.org/r1675869
Log:
Applied fix from trunk for revision: 1675852
===========================================================
Fixed the order in which invoice and payment transactions are created.

Payment transactions were being created prior to invoice transactions, It causes confusion for accountants in real world.

It was a seca execution order which was causing the issue on setInvoiceStatus. Moved the trigger on setInvoiceStatus for checkInvoicePaymentApplications and capturePaymentsByInvoice from secas.xml to secas_invoice.xml, so that we do invoice transactions prior to payment.
=============================================================

Modified:
    ofbiz/branches/release14.12/applications/accounting/servicedef/secas.xml
    ofbiz/branches/release14.12/applications/accounting/servicedef/secas_invoice.xml

Modified: ofbiz/branches/release14.12/applications/accounting/servicedef/secas.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/release14.12/applications/accounting/servicedef/secas.xml?rev=1675869&r1=1675868&r2=1675869&view=diff
==============================================================================
--- ofbiz/branches/release14.12/applications/accounting/servicedef/secas.xml (original)
+++ ofbiz/branches/release14.12/applications/accounting/servicedef/secas.xml Fri Apr 24 14:28:01 2015
@@ -153,13 +153,4 @@ under the License.
         <condition field-name="productTypeId" operator="equals" value="ASSET_USAGE"/>
         <action service="createFixedAssetAndLinkToProduct" mode="sync"/>
     </eca>
-
-    <eca service="setInvoiceStatus" event="commit">
-        <condition field-name="invoiceId" operator="is-not-empty"/>
-        <condition field-name="statusId" operator="equals" value="INVOICE_READY"/>
-        <condition field-name="oldStatusId" operator="not-equals" value="INVOICE_READY"/>
-        <condition field-name="oldStatusId" operator="not-equals" value="INVOICE_PAID"/>
-        <action service="checkInvoicePaymentApplications" mode="sync"/>
-        <action service="capturePaymentsByInvoice" mode="sync"/>
-    </eca>
 </service-eca>

Modified: ofbiz/branches/release14.12/applications/accounting/servicedef/secas_invoice.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/release14.12/applications/accounting/servicedef/secas_invoice.xml?rev=1675869&r1=1675868&r2=1675869&view=diff
==============================================================================
--- ofbiz/branches/release14.12/applications/accounting/servicedef/secas_invoice.xml (original)
+++ ofbiz/branches/release14.12/applications/accounting/servicedef/secas_invoice.xml Fri Apr 24 14:28:01 2015
@@ -46,5 +46,12 @@ under the License.
         <condition operator="equals" field-name="oldStatusId" value="INVOICE_IN_PROCESS"/>
         <action service="createMatchingPaymentApplication" mode="sync"/>
     </eca>
-
+    <eca service="setInvoiceStatus" event="commit">
+        <condition field-name="invoiceId" operator="is-not-empty"/>
+        <condition field-name="statusId" operator="equals" value="INVOICE_READY"/>
+        <condition field-name="oldStatusId" operator="not-equals" value="INVOICE_READY"/>
+        <condition field-name="oldStatusId" operator="not-equals" value="INVOICE_PAID"/>
+        <action service="checkInvoicePaymentApplications" mode="sync"/>
+        <action service="capturePaymentsByInvoice" mode="sync"/>
+    </eca>
 </service-eca>