Update Formatted Description on Change Orders, Change Requests, Problem Reports, and Corrective Actions
This use case shows how to update the formatted description (CLOB attribute) on changes.
You can use the Product Change Orders V2 REST API to get and update the formatted description in any of the Change types.
A company needs to update the design of its existing product range, The product design engineer has created a change order to update the design of the product, and now needs to update the formatted description by providing the HTML link to the supporting document, To do this, the product design engineer needs to get the change order and has to update the formatted description details. Let's see how they would use the Product Change Orders V2 REST API resource for this.
-
Get the change ID of the change order using the change name.
-
Get the change order formatted description self-link for the change order.
- Update the formatted description attribute providing the HTML link details.
Update the Formatted Description Request
This example shows how to get the Change ID using the Change Name.
Example URL
Use this resource URL format:
GET
curl -u username:password -X GET -H "Content-Type:application/vnd.oracle.adf.action+json" -d "https://servername/fscmRestApi/resources/version/productChangeOrdersV2?q=ChangeName=REGCO0991"
Example Response Body
{ "items": [ { "ChangeId": 300100578182503, "ChangeTypeId": 300100578111346, "ChangeNotice": "REGCO0991", "ChangeName": "REGCO0991", "Description": null, "OrganizationId": 204, "PriorityCode": null, "ReasonCode": null, "ChangeTypeValue": "SS_CO_Type5", "OrganizationCode": "V1", "PriorityCodeValue": null, "ReasonCodeValue": null, "AssigneeId": "EE090FD91FAF33D2F3E424B67B06F902", "RequestorId": "EE090FD91FAF33D2F3E424B67B06F902", "AssignedTo": "PLM_AUTO", "RequestedBy": "PLM_AUTO", "StatusType": 0, "StatusCode": 0, "ApprovalStatus": 1, "StatusTypeValue": "Draft", "StatusCodeValue": "Draft", "ApprovalStatusValue": "Not submitted for approval", "EffectiveImmediatelyFlag": true, "EffectivityIncrementDays": 1, "CreatedBy": "PLM_AUTO", "LastUpdatedBy": "PLM_AUTO", "LastUpdateLogin": "FA08EE88D7776002E053F56115AC6632", "AssignedToRole": null, "ApprovalDateTime": null, "NeedByDateTime": null, "InitiationDateTime": "2023-05-04T00:00:00+00:00", "ImplementationDateTime": null, "CancellationDateTime": null, "ApprovalRequestDateTime": null, "CreationDateTime": "2023-05-04T12:13:20+00:00", "LastUpdateDateTime": "2023-05-04T12:13:59.420+00:00", "StatusComments": null, "CustomerId": null, "CustomerAccountNumber": null, "CustomerName": null, "SupplierId": null, "SupplierNumber": null, "SupplierName": null, "ManufacturerId": null, "ManufacturerRegistryId": null, "ManufacturerName": null, "SourceCode": null, "SourceName": null, "CategoryCode": "SS_CO_Type5", "links": [ { "rel": "self", "href": "https://servername/fscmRestApi/resources/version/productChangeOrdersV2/300100578182503", "name": "productChangeOrdersV2", "kind": "item", "properties": { "changeIndicator": "ACED0005737200136A6176612E7574696C2E41727261794C6973747881D21D99C7619D03000149000473697A6578700000000177040000000173 7200116A6176612E6C616E672E496E746567657212E2A0A4F781873802000149000576616C7565787200106A6176612E6C616E672E4E756D62657 286AC951D0B94E08B02000078700000000178" } }, { "rel": "canonical", "href": "https://servername/fscmRestApi/resources/version/productChangeOrdersV2/300100578182503", "name": "productChangeOrdersV2", "kind": "item" }, { "rel": "child", "href": "https://servername/fscmRestApi/resources/version/productChangeOrdersV2/300100578182503/child/changeOrderAffectedObject", "name": "changeOrderAffectedObject", "kind": "collection" }, { "rel": "child", "href": "https://servername/fscmRestApi/resources/version/productChangeOrdersV2/300100578182503/child/changeOrderAttachments", "name": "changeOrderAttachments", "kind": "collection" }, { "rel": "child", "href": "https://servername/fscmRestApi/resources/version/productChangeOrdersV2/300100578182503/child/changeOrderDFF", "name": "changeOrderDFF", "kind": "collection" }, { "rel": "child", "href": "https://servername/fscmRestApi/resources/version/productChangeOrdersV2/300100578182503/child/changeOrderEFF", "name": "changeOrderEFF", "kind": "collection" }, { "rel": "child", "href": "https://servername/fscmRestApi/resources/version/productChangeOrdersV2/300100578182503/child/changeOrderNextStatuses", "name": "changeOrderNextStatuses", "kind": "collection" }, { "rel": "child", "href": "https://servername/fscmRestApi/resources/version/productChangeOrdersV2/300100578182503/child/changeOrderParticipants", "name": "changeOrderParticipants", "kind": "collection" }, { "rel": "child", "href": "https://servername/fscmRestApi/resources/version/productChangeOrdersV2/300100578182503/child/changeOrderRelationships", "name": "changeOrderRelationships", "kind": "collection" }, { "rel": "child", "href": "https://servername/fscmRestApi/resources/version/productChangeOrdersV2/300100578182503/child/changeOrderTasks", "name": "changeOrderTasks", "kind": "collection" }, { "rel": "child", "href": "https://servername/fscmRestApi/resources/version/productChangeOrdersV2/300100578182503/child/changeOrderTeam", "name": "changeOrderTeam", "kind": "collection" } ] } ], "count": 1, "hasMore": false, "limit": 25, "offset": 0, "links": [ { "rel": "self", "href": "https://servername/fscmRestApi/resources/version/productChangeOrdersV2", "name": "productChangeOrdersV2", "kind": "collection" } ] }
Then use the PATCH action to update the formatted description.
Example URL
Use this resource URL format:
PATCH
curl -X PATCH -H 'REST-Framework-Version:8' u "username:password" -H "Content-Type: application/vnd.oracle.adf.resourceitem+json" -d 'request payload' "https://servername/fscmRestApi/resources/version/productChangeOrdersV2/300100578182503"
Example Request Body
Here's an example of the request body in JSON format you use the enclosure for formatted description.
{ "FormattedDescription": The Design needs to be updated as per the new standard and the link to the supporting document is in Oracle Help Center "https://docs.oracle.com/en/"}
Then use the GET action to verify the updated formatted description.
curl -u username:password -X GET -H 'REST-Framework-Version:8' -H "Content-Type: application/json" -d "https://servername/fscmRestApi/resources/version/productChangeOrdersV2/300100578182503/enclosure/FormattedDescription"
Example Response Body
The Design needs to be updated as per the new standard and the link to the supporting document is in Oracle Help Center https://docs.oracle.com/en/