General InformationUsers can assign enterprise item numbers to products using the "Set Enterprise Item Number" command. As an Administrator, you can create a business rule that defines the enterprise item number. You create business rules using either the Data Model Customization app or the Data Setup app. The Data Model Customization app is available only on the On Premises environment. The Data Setup app is available on On Premises and Cloud.
Input ObjectsInput objects must be of the following types:
Context Object Parameters
PartNumber
/* ThisObject : VPMReference */
Let UniqueKey=""
Let ObjectCustoType=""
Let ExternalID=""
Let EnterpriseItemNumber=""
/* get counter */
ObjectCustoType = ThisObject.PrimaryType.Name
UniqueKey = GetUniqueKeyFromString( ObjectCustoType )
/* get PLMExternal_ID */
ExternalID= ThisObject->GetAttributeString("PLM_ExternalID")
/* generate Enterprise Item Number with schema */
EnterpriseItemNumber = "PN-" + ExternalID + "-" + UniqueKey
/* set value in parameters*/
Parameters->SetAttributeString("PartNumber", EnterpriseItemNumber)
Where In this example, the type of the object is used as the input
string in | |||||||||||||||||||||||||