Solution
As the workflow user task service, we use a service extension in order to add an output parameter that will contain the selected records.
The following article explains how to achieve this:
https://support.tibco.com/s/article/Extending-a-built-in-service-to-add-input-output-parameters Then we have implemented a service without display (UserServiceExtended) that will be launched from the user task that uses the default service extension.
When launched, this service:
- Retrieves selected records
- Puts their primary key values, separated by a ";" character, in a data context output variable
- Completes the interaction (displays the accept button)
This service is declared so it can only be displayed/executed in a workflow context.
In our solution, we chose to implement a toolbar so that it can be launched with a separate button.
Result
Before launching the service:
After launching the service:
Data context variable value: