Author: jleroux
Date: Sat Jan 31 11:51:42 2015
New Revision: 1656187
URL:
http://svn.apache.org/r1656187Log:
A patch from Youssef Khaye to finally fix "Incorrect quantityNotAvailable for OrderItemShipGrpInvRes when issuing items to shipments"
https://issues.apache.org/jira/browse/OFBIZ-5364
This patch fixes the problem from a functional point of view and consequently the JUnit test in question.
In fact, functionally speaking, The previous patch is not good in measure or it does not take into account that an OrderItem might use several lines of stock InventoryItem.
orderId orderItemSeqId orderItemShipGrpSeqId InvetoryItemId
10000 000001 10000 000001
10000 000001 10001 000001
So by making a stock exit (ItemIssuance) we can afford to cancel the reservation lines for the line of stock in question but not all the lines of stock.
That's why I added the lines in the inventoryItemId research question and then cancel a reservation!
While at it I reverted r1653056 since testMultipleInventoryItemIssuance now passes
Modified:
ofbiz/branches/release14.12/ (props changed)
ofbiz/branches/release14.12/applications/product/script/org/ofbiz/shipment/issuance/IssuanceServices.xml
Propchange: ofbiz/branches/release14.12/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Sat Jan 31 11:51:42 2015
@@ -8,4 +8,4 @@
/ofbiz/branches/json-integration-refactoring:1634077-1635900
/ofbiz/branches/multitenant20100310:921280-927264
/ofbiz/branches/release13.07:1547657
-/ofbiz/trunk:1649393,1649742,1650240,1650583,1650642,1650678,1650882,1650887,1650938,1651593,1652361,1652706,1652725,1652731,1652739,1653248,1653456,1654175,1654273,1655046,1655668,1655979
+/ofbiz/trunk:1649393,1649742,1650240,1650583,1650642,1650678,1650882,1650887,1650938,1651593,1652361,1652706,1652725,1652731,1652739,1653248,1653456,1654175,1654273,1655046,1655668,1655979,1656185
Modified: ofbiz/branches/release14.12/applications/product/script/org/ofbiz/shipment/issuance/IssuanceServices.xml
URL:
http://svn.apache.org/viewvc/ofbiz/branches/release14.12/applications/product/script/org/ofbiz/shipment/issuance/IssuanceServices.xml?rev=1656187&r1=1656186&r2=1656187&view=diff==============================================================================
--- ofbiz/branches/release14.12/applications/product/script/org/ofbiz/shipment/issuance/IssuanceServices.xml (original)
+++ ofbiz/branches/release14.12/applications/product/script/org/ofbiz/shipment/issuance/IssuanceServices.xml Sat Jan 31 11:51:42 2015
@@ -273,6 +273,7 @@ under the License.
<entity-and list="oisgirs" entity-name="OrderItemShipGrpInvRes">
<field-map field-name="orderId" from-field="orderItemShipGrpInvRes.orderId"/>
<field-map field-name="orderItemSeqId" from-field="orderItemShipGrpInvRes.orderItemSeqId"/>
+ <field-map field-name="inventoryItemId" from-field="orderItemShipGrpInvRes.inventoryItemId"/>
</entity-and>
</simple-method>