LOG0209 Create Warehouse Requisitions for further execution (manual generation only)

Basic Information

Module Logistics.Inventory
Code LOG0209
Parent Document Store Order
Sub-document Warehouse Requisition
Full Name Create Warehouse Requisitions for further execution (manual generation only)
Status NEW
Deterministic YES
Supports Transitional Documents NO
Supports Single Execution No
Replaces -
Orphan Rows Ignore
Split Function -
Version Introduced: 2024.1
Date of Suspension -

Business Logic

This Generation is used to create Warehouse Requisitions from Store Orders for further execution.

This generation is intended to operate only in manual mode, where a responsible person assesses whether and when it is necessary to complete a previously incomplete Store Order.

Important

The generation procedure is Manual Only. That means you have to select Allowed Generation Types = Manually!!!
Do not set Allowed Generation Types = Auto or Allowed Generation Types = Both (Auto and Manually)!!!



The Warehouse Requisition’s header is created based on the Store Order’s header as follows:

WarehouseRequisition.DocumentDate = StoreOrder.DocumentDate

WarehouseRequisition.ManagedWarehouse = StoreOrder.Store.ManagedWarehouse

WarehouseRequisition.RequisitionType = if( StoreOrder.MovementType = Receipt) 

                                   , then Transaction.RequisitionType = Inbound

                                   , else Transaction.RequisitionType = Outbound

WarehouseRequisition.ExpectedDate = ISNULL(StoreOrder.PlannedReleaseDate, StoreOrder.DocumentDate)

WarehouseRequisition.ExpectedTime = null
Note

The attributes which are not specified here are filled in as described in Standard Document Attributes

If StoreOrder.Store.ManagedWarehouse = NULL, throw an error:

No Managed Warehouse is specified for store '{Store.StoreName}'.
Please check if the store is correct and if the field 'Managed Warehouse' in its definition has a value.
Note

The new Warehouse Requisition is saved then and only when there is at least one line in it.

Fulfillments

Fulfilment Name StoreOrderLineToWarehouseRequisitionLine
Fulfilment Tracking Type Fulfilment Table
Parent StoreOrderLine
Child DocumentFulfillments(where 'DocumentLineId = StoreOrderLineId' AND 'FulfillmentType = Completed' AND 'DestinationEntityName = Wms_Warehouse_Requisition_Lines')
Parent/ Child Relationship StoreOrderLine = ChildDocumentFulfillment

Metrics

Fulfilment Name Metric Name Measurement Unit Parent Value Fulfilment Table Value New Record
StoreOrderLineToWarehouseRequisitionLine MQuantityBase StoreOrderLine.Product.BaseMeasurementUnit StoreOrderLine.QuantityBase DocumentFulfillment.QuantityBase NO
StoreOrderLineToWarehouseRequisitionLine MStandardQuantity StoreOrderLine.Product.BaseMeasurementUnit StoreOrderLine.StandardQuantityBase DocumentFulfillment.StandardQuantity YES



The lines of the new document are created based on the data of StoreOrderLine AND the Fulfilled Part of quantities by the Warehouse Requisitions which have already been Completed. The generation creates a new line only if the remaining quantity is more than zero.

StoreOrder.StandardQuantity - ChildDocumentFulfillment.StandardQuantity

Note

Note that for the calculation of the Fulfilled Part are taken into account only the records whose Fulfillment Type is Completed.

Important

The generation will not create a new line if the remaining quantity that needs to be fulfilled is a negative number or zero (if StoreOrderLine.REMAINING(MStandardQuantity) <= 0).


The new Warehouse Requisition Line is created as follows:

WarehouseRequisitionLine.LineNo = Autonumber(10, 20 ...)

WarehouseRequisitionLine.Product = StoreOrderLine.Product

WarehouseRequisitionLine.Lot = StoreOrderLine.Lot

WarehouseRequisitionLine.SerialNumber = StoreOrderLine.SerialNumber

WarehouseRequisitionLine.ProductVariant = StoreOrderLine.ProductVariant

WarehouseRequisitionLine.QuantityBase = StoreOrderLine.REMAINING(MQuantityBase)

WarehouseRequisitionLine.StandardQuantity = StoreOrderLine.REMAINING(MStandardQuantity)

WarehouseRequisitionLine.QuantityUnit = StoreOrderLine.QuantityUnit

WarehouseRequisitionLine.Quantity = If there are no records in the Document Fulfillment table for the current StoreOrderLine

                                , then WarehouseRequisitionLine.Quantity = StoreOrderLine.Quantity

                                , else CONVERT(WarehouseRequisitionLine.StandardQuantity, WarehouseRequisitionLine.QuantityUnit)

WarehouseRequisitionLine.Notes = StoreOrderLine.Notes

WarehouseRequisitionLine.ParentDocument = StoreOrder

WarehouseRequisitionLine.ParentLineNo = StoreOrderLine.LineNo

After the line is created, the generation should NOT create records for Document Fulfillment table. This is because the generation is only for further execution, and the planned part won't change.