Configuring a record producer for request edit
Configure a record producer for editable workplace service requests.
The request edit feature in Workplace Service Delivery lets users modify the details of their submitted requests. Cases that are created with record producers on the Workplace Case or Workplace Case Extension tables can be edited, keeping records current and accurate.
To configure the edit functionality of a record producer, follow the steps in the following sections.
Creating a record producer
You must first create a record producer on the Workplace Case or Workplace Case Extension tables, then map it to the Record Producer field of a Workplace Service. For more information about creating a record producer, see Configure a Record producer.
If you want to integrate the record producer with Workplace Reservation Management, see Configuring a record producer for reservation.
Enabling the edit functionality
You can enable the button by selecting Case or Case and Reservation in the Available for field, then selecting the Allow request modifications field of the workplace service.
When the Allow request modifications option is enabled on a workplace service, users see the Edit request action in the request summary page for all the record producers associated with that service.
For more information about the fields of a workplace service, see Workplace Service form.
Redirecting to the Case Editor page
When users select the edit request option for their request, they’re redirected to the WSD Case Editor page, which looks like the record producer to provide a familiar interface for users.
After making their changes, users can save the updated case, which makes the following changes:
- The Workplace Case record is updated with the new values provided by the user.
- New service item requests are created based on the updated case information, if necessary.
Configuring the record producer for editing
- Handling variables with default values on load
- Condition
Variables that have default values on load can cause data inconsistency on the edit page. The edit page must fill variables based on the submitted request.
For example, the system tries to populate the logged-in user in the Requested for field instead of picking the data from the submitted request.
- Triggering an event on submission
-
For the edit page, you must trigger the wsd.serviceEditor.onSubmit.success event in the onSubmit catalog client script (last executable script) of the record producer with the parameter success: true. Ensure that the last executable client script has the UI type field set to All.
Triggering the event makes sure that all the onSubmit client scripts are validated and that the updated variable data can be used to update the case record.
For more information, refer to any record producers installed with Workplace Case Management, like Catering.
- Using custom widgets in the record producer
- Condition
To use custom widgets in the record producer, ensure that the widget can pre-fill data based on the submitted request. The reference for the widget can be taken from the Workplace Service widget.