Use Case 6: Generate a Downstream Structure by Mapping Two Different Usage Attributes
Consider that the following structure is present in the BOM Transformer:
• An equivalent link exists between the Upstream Parent Part (Design) and Downstream Parent Part (Manufacturing).
To generate the downstream structure by mapping different usage attributes, you can specify the transformation and restructuring rules using rules file or properties file.
Using Rules File
{
"transformRules": [
{
"sourceType": "wt.part.WTPart",
"newAttributeMappings": [
[
"source.usage.Attribute1:String1",
"target.part.Attribute2:String1"
]
],
"targetType": "wt.part.WTPart",
"transformOption": "newPart"
}
]
}
Using Properties File
1. Access the associativity.properties.xconf file located in Windchill/codebase/com/ptc/core/foundation/associativity.
2. Add the following restructuring rules:
<Property name="com.ptc.windchill.associativity.reconciliation.addusage.wt.part.WTPart" multivalued="," default=""/>
<AddToProperty name="com.ptc.windchill.associativity.reconciliation.addusage.wt.part.WTPart" value="transformOption=newPart"/>
<AddToProperty name="com.ptc.windchill.associativity.reconciliation.addusage.wt.part.WTPart" value="targetType=wt.part.WTPart"/>
<AddToProperty name="com.ptc.windchill.associativity.reconciliation.addusage.wt.part.WTPart" value="attributeMapping.rule1=Attribute1:String1:Attribute2:String1"/>
After you initiate the
action on the selected part in the upstream, the Windchill system traverses the structure below the selected part. This configuration ensures that :
• If the Windchill system detects a part with the part usage attribute Attribute1 set to String1, then the detected part is added in downstream as a new part, under the part whose part type is wt.part.WTPart and part usage attribute Attribute2 is set to String1.
The following structure appears in the BOM Transformer:
Part C1 (Manufacturing) and Part C2 (Manufacturing) are added as new parts under Part T1 (Manufacturing).
Related information