Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Get the inventsum and inventory dimension for a batch
Syntax
server public static InventSum findSumSameLot(
ItemId _itemId,
InventDim _inventDimCriteria,
InventDimParm _inventDimParm,
[InventSumFields _sumFields,
TransDate _expDate,
CustAccount _custAcct])
Run On
Server
Parameters
- _itemId
Type: ItemId Extended Data Type
The item to find the cumulative Inventsum values.
- _inventDimCriteria
Type: InventDim Table
The criteria to limit the batch search for
- _inventDimParm
Type: InventDimParm Table
The flags for the inventory dimension values
- _sumFields
Type: InventSumFields Enumeration
Which field groups to use for the summation.
- _expDate
Type: TransDate Extended Data Type
The Expiration date for which the batches for not exceed
- _custAcct
Type: CustAccount Extended Data Type
A specific customer for which to retreive batch attribute information.
Defaults to empty str or no customer.
Return Value
Type: InventSum Table
A cumulative InventSum Record
Exceptions
Exception | Condition |
---|---|
Error | If the _nventDimCriteria contains a serial number and the _inventDimParm record has the InventSerialIdFlag as active, an error will be return as this combination is not allowed. |
Remarks
The method goes through all inventSum record within the inventDim and InventDimParm combination and creates a cumulative InventSum record.
After the summation occurs, additional validation is done on the inventSum records within this range to see if they are either expired based on the _expdate value or if the batch has a disposition code that is does allow it to be included. The results of these two validations are subtracted from the cumulative amount.