Codeunit WSB_STMItemStatusPublic
Exposes procedures to manage and perform tests specifically related to the statuses of items.
Properties
Methods
wgFncIsPurchInsertAllowed
Check if the item can be used in purchase documents/entities.
Parameters
| Type |
Name |
Description |
Record "Item" |
pRecItem |
The item. |
Enum "Purchase Document Type" |
pDocumentType |
The purchase document type. |
Returns
| Type |
Description |
Boolean |
If allowed to use the item. |
wgFncIsSalesInsertAllowed
Check if the item can be used in sales documents/entities.
Parameters
| Type |
Name |
Description |
Record "Item" |
pRecItem |
The item. |
Enum "Sales Document Type" |
pDocumentType |
The sales document type. |
Returns
| Type |
Description |
Boolean |
If allowed to use the item. |
wgFncIsServiceInsertAllowed
Check if the item can be used in service documents/entities.
Parameters
| Type |
Name |
Description |
Record "Item" |
pRecItem |
The item. |
Enum "Service Document Type" |
pDocumentType |
The service document type. |
Returns
| Type |
Description |
Boolean |
If allowed to use the item. |
wgFncTestForPurchInsert
Check if the item can be used in purchase documents/entities, and throw an error if that is not the case.
Parameters
| Type |
Name |
Description |
Record "Item" |
pRecItem |
The item. |
Enum "Purchase Document Type" |
pDocumentType |
The purchase document type. |
wgFncTestForSalesInsert
Check if the item can be used in sales documents/entities, and throw an error if that is not the case.
Parameters
| Type |
Name |
Description |
Record "Item" |
pRecItem |
The item. |
Enum "Sales Document Type" |
pDocumentType |
The sales document type. |
wgFncTestForServiceInsert
Check if the item can be used in service documents/entities, and throw an error if that is not the case.
Parameters
| Type |
Name |
Description |
Record "Item" |
pRecItem |
The item. |
Enum "Service Document Type" |
pDocumentType |
The service document type. |
wgEvpOnBeforeTestForEdit
An event publisher that allows to extend or override the checks that are being performed (via procedure wlFncTestForEdit) when a user tries to edit the record, based on its current status.
Parameters
| Type |
Name |
Description |
Record "Item" |
pRecItem |
The Item record |
Boolean |
vIsHandled |
Set this to true if your extension handles/overrides the checks that should be performed |