You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by ad...@apache.org on 2008/11/03 20:22:21 UTC

svn commit: r710135 - in /ofbiz/trunk/applications/accounting: servicedef/secas.xml servicedef/services_invoice.xml src/org/ofbiz/accounting/invoice/InvoiceServices.java

Author: adrianc
Date: Mon Nov  3 11:22:20 2008
New Revision: 710135

URL: http://svn.apache.org/viewvc?rev=710135&view=rev
Log:
Applied a patch from William Perng - https://issues.apache.org/jira/browse/OFBIZ-2025. This patch fixes a bug in PO receiving.

Modified:
    ofbiz/trunk/applications/accounting/servicedef/secas.xml
    ofbiz/trunk/applications/accounting/servicedef/services_invoice.xml
    ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/invoice/InvoiceServices.java

Modified: ofbiz/trunk/applications/accounting/servicedef/secas.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/servicedef/secas.xml?rev=710135&r1=710134&r2=710135&view=diff
==============================================================================
--- ofbiz/trunk/applications/accounting/servicedef/secas.xml (original)
+++ ofbiz/trunk/applications/accounting/servicedef/secas.xml Mon Nov  3 11:22:20 2008
@@ -22,6 +22,7 @@
         xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/service-eca.xsd">
     <eca service="createInvoiceForOrder" event="return">
         <condition field-name="invoiceId" operator="is-not-empty"/>
+        <condition field-name="invoiceTypeId" operator="equals" value="SALES_INVOICE"/>
         <action service="capturePaymentsByInvoice" mode="sync"/>
     </eca>        
     <eca service="createPaymentApplication" event="commit">

Modified: ofbiz/trunk/applications/accounting/servicedef/services_invoice.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/servicedef/services_invoice.xml?rev=710135&r1=710134&r2=710135&view=diff
==============================================================================
--- ofbiz/trunk/applications/accounting/servicedef/services_invoice.xml (original)
+++ ofbiz/trunk/applications/accounting/servicedef/services_invoice.xml Mon Nov  3 11:22:20 2008
@@ -153,6 +153,7 @@
         <attribute name="orderId" type="String" mode="IN" optional="false"/>
         <attribute name="billItems" type="List" mode="IN" optional="false"/>
         <attribute name="invoiceId" type="String" mode="OUT" optional="true"/>
+        <attribute name="invoiceTypeId" type="String" mode="OUT" optional="true"/>
     </service>
     <service name="createInvoiceFromReturn" engine="java"
         location="org.ofbiz.accounting.invoice.InvoiceServices" invoke="createInvoiceFromReturn">
@@ -280,4 +281,4 @@
         <auto-attributes mode="IN" include="pk" optional="false"/>
         <auto-attributes mode="IN" include="nonpk" optional="true"/>
     </service>
-</services>
\ No newline at end of file
+</services>

Modified: ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/invoice/InvoiceServices.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/invoice/InvoiceServices.java?rev=710135&r1=710134&r2=710135&view=diff
==============================================================================
--- ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/invoice/InvoiceServices.java (original)
+++ ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/invoice/InvoiceServices.java Mon Nov  3 11:22:20 2008
@@ -818,6 +818,7 @@
 
             Map resp = ServiceUtil.returnSuccess();
             resp.put("invoiceId", invoiceId);
+            resp.put("invoiceTypeId", invoiceType);
             return resp;
         } catch (GenericEntityException e) {
             String errMsg = UtilProperties.getMessage(resource,"AccountingEntityDataProblemCreatingInvoiceFromOrderItems",UtilMisc.toMap("reason",e.toString()),locale);