Creating Multiple MPMDocumentDescribeLinks
You can create MPMDocumentDescribeLinks between a DocumentManageables (Process Plan, Standard Procedure, Operation, or Sequence) object and single or multiple documents by specifying the document OIDs in the request body. To create MPMDocumentDescribeLinks, you must first checkout the DocumentManageables object.
|
To create an MPMDocumentDescribeLink, you cannot specify the document object of type Reference Document.
|
Example: Creating MPMDocumentDescribeLinks for a Specific Process Plan
This example shows you how to create two MPMDocumentDescribeLinks between a Process Plan specified in the request URI and two documents specified in the request body. Use the following POST URI with the request body.
URI
POST /Windchill/servlet/odata/MfgProcMgmt/DocumentManageables('OR:com.ptc.windchill.mpml.processplan.MPMProcessPlan:236331')/PTC.MfgProcMgmt.CreateMPMDocumentDescribeLinks
Request Header
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"DocumentDescribeLink": [
{
"DescribedBy@odata.bind": "Documents('OR:wt.doc.WTDocument:238234')"
},
{
"DescribedBy@odata.bind": "Documents('OR:wt.doc.WTDocument:238246')"
}
]
}
Similarly, you can create MPMDocumentDescribeLinks for a specific Standard Procedure by specifying its OID in the request URI.
Example: Creating MPMDocumentDescribeLinks for a Specific Operation
This example shows you how to create two MPMDocumentDescribeLinks between an Operation specified in the request URI and two documents specified in the request body. Use the following POST URI with the request body.
URI
POST /Windchill/servlet/odata/MfgProcMgmt/DocumentManageables('OR:com.ptc.windchill.mpml.processplan.operation.MPMOperation:366090')/PTC.MfgProcMgmt.CreateMPMDocumentDescribeLinks
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"DocumentDescribeLink": [
{
"DescribedBy@odata.bind": "Documents('OR:wt.doc.WTDocument:238234')"
},
{
"DescribedBy@odata.bind": "Documents('OR:wt.doc.WTDocument:238246')"
}
]
}
Example: Creating MPMDocumentDescribeLinks for a Specific Sequence
This example shows you how to create two MPMDocumentDescribeLinks between a Sequence specified in the request URI and two documents specified in the request body. Use the following POST URI with the request body.
URI
POST /Windchill/servlet/odata/MfgProcMgmt/DocumentManageables('OR:com.ptc.windchill.mpml.processplan.sequence.MPMSequence:366130')/PTC.MfgProcMgmt.CreateMPMDocumentDescribeLinks
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"DocumentDescribeLink": [
{
"DescribedBy@odata.bind": "Documents('OR:wt.doc.WTDocument:238234')"
},
{
"DescribedBy@odata.bind": "Documents('OR:wt.doc.WTDocument:238246')"
}
]
}