Implemented logic to assign reservations for new sales orders according to the priority given by the ship before date.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@644637 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@@ -29,6 +29,9 @@ under the License.
|
||||
<condition field-name="orderTypeId" operator="equals" value="SALES_ORDER"/>
|
||||
<action service="checkCreateDropShipPurchaseOrders" mode="sync" run-as-user="system"/>
|
||||
</eca>
|
||||
<eca service="storeOrder" event="return">
|
||||
<action service="balanceOrderItemsWithNegativeReservations" mode="sync"/>
|
||||
</eca>
|
||||
<eca service="changeOrderItemStatus" event="commit">
|
||||
<condition field-name="statusId" operator="equals" value="ITEM_CANCELLED"/>
|
||||
<action service="cancelOrderInventoryReservation" mode="sync"/>
|
||||
|
||||
@@ -447,6 +447,10 @@ under the License.
|
||||
<simple-method method-name="reserveOrderItemInventory" short-description="Reserve Order Item Inventory">
|
||||
<entity-one entity-name="OrderItemShipGrpInvRes" value-name="checkOisgirEntity"/>
|
||||
|
||||
<entity-one entity-name="OrderItem" value-name="orderItem"/>
|
||||
<set field="parameters.promisedDatetime" from-field="orderItem.shipBeforeDate"/>
|
||||
<set field="parameters.currentPromisedDate" from-field="orderItem.shipBeforeDate"/>
|
||||
|
||||
<if-empty field-name="checkOisgirEntity">
|
||||
<!-- create OrderItemShipGrpInvRes record -->
|
||||
<make-value entity-name="OrderItemShipGrpInvRes" value-name="newOisgirEntity"/>
|
||||
|
||||
@@ -248,7 +248,8 @@ under the License.
|
||||
<description>Balance inventory reservations for a given product/facility, considering all the reservations with promised date greater than fromDate.</description>
|
||||
<attribute name="productId" type="String" mode="IN" optional="false"/>
|
||||
<attribute name="facilityId" type="String" mode="IN" optional="false"/>
|
||||
<attribute name="fromDate" type="String" mode="IN" optional="true"/>
|
||||
<attribute name="fromDate" type="Timestamp" mode="IN" optional="true"/>
|
||||
<attribute name="noLongerOnBackOrderIdSet" type="Set" mode="OUT" optional="true"/>
|
||||
</service>
|
||||
<service name="balanceOrderItemsWithNegativeReservations" engine="simple"
|
||||
location="org/ofbiz/product/inventory/InventoryServices.xml" invoke="balanceOrderItemsWithNegativeReservations">
|
||||
|
||||
Reference in New Issue
Block a user