When a request for change is submitted by a user via a service request with resource answers, then a change should be auto-created, resource answers copied to its description, and the change should be associated with the service request
Service requests are often used to allow the requester to log a request for change. The details for the change are captured using the resource questions section and FAFR is used to make the resource questions interactive. Therefore, when a request for a change-service request is submitted by a requester, it has to create a change with all the details and resource answers in its description and be associated with the service request.
Steps to configure:
1. Download the attached scripts. Copy the contents into Request custom functions.
2. Goto Admin > Request Custom Function > Global Function > New > Paste the global function contents and save it with a name.
Update the URL and integration/technician key in the script.
- For builds over 11300, you can get the integration key under Admin > Integrations > Integration Key > New
- Please use an integration key with admin privilege, as there wont be any role based permission issues.
- For builds prior to 11300, refer https://help.servicedeskplus.com/api/rest-api.html$key and update the technician key.
3. Goto Admin > Request Custom Function > Custom Function > New > Paste the addChangeWithResourceInfoInDesc.txt content and save it with a name
- Update the global function count according to your instance
- Update the Change template name as per your instance. In my case its "Additional Field" template.
4. Configure the created custom function in a trigger to get executed every time a request is approved.