[OFBiz] SVN: r6767 - trunk/applications/product/script/org/ofbiz/product/inventory
jaz@svn.ofbiz.org
jaz at svn.ofbiz.org
Fri Feb 17 13:59:52 CST 2006
Author: jaz
Date: 2006-02-17 13:59:50 -0600 (Fri, 17 Feb 2006)
New Revision: 6767
Modified:
trunk/applications/product/script/org/ofbiz/product/inventory/InventoryServices.xml
Log:
updated inventory calc routine to only include available and promised serialized status in qoh calc
Modified: trunk/applications/product/script/org/ofbiz/product/inventory/InventoryServices.xml
===================================================================
--- trunk/applications/product/script/org/ofbiz/product/inventory/InventoryServices.xml 2006-02-17 18:51:20 UTC (rev 6766)
+++ trunk/applications/product/script/org/ofbiz/product/inventory/InventoryServices.xml 2006-02-17 19:59:50 UTC (rev 6767)
@@ -346,9 +346,19 @@
<set field="parameters.quantityOnHandTotal" value="0" type="Double"/>
<iterate entry-name="inventoryItem" list-name="inventoryItems">
<if-compare field-name="inventoryItem.inventoryItemTypeId" operator="equals" value="SERIALIZED_INV_ITEM">
- <calculate field-name="parameters.quantityOnHandTotal" type="Double">
- <calcop field-name="parameters.quantityOnHandTotal" operator="add"><number value="1.0"/></calcop>
- </calculate>
+ <if>
+ <condition>
+ <or>
+ <if-compare field-name="inventoryItem.statusId" value="INV_AVAILABLE" operator="equals"/>
+ <if-compare field-name="inventoryItem.statusId" value="INV_PROMISED" operator="equals"/>
+ </or>
+ </condition>
+ <then>
+ <calculate field-name="parameters.quantityOnHandTotal" type="Double">
+ <calcop field-name="parameters.quantityOnHandTotal" operator="add"><number value="1.0"/></calcop>
+ </calculate>
+ </then>
+ </if>
<if-compare value="INV_AVAILABLE" operator="equals" field-name="inventoryItem.statusId">
<calculate field-name="parameters.availableToPromiseTotal" type="Double">
<calcop field-name="parameters.availableToPromiseTotal" operator="add"><number value="1.0"/></calcop>
More information about the Svn
mailing list