For one of our applications, we are using Pega 25.1 with constellation.
In this application, We have implemented search and select functionality. There are few input fields for this and the search is configured with a list data page which has connector as a source to call a REST service and we retrieve and list the results. This is all good so far.
However, we also want to add some errors on the input fields/ or the page to inform the users about the errors occurred in the web service call.
After some analysis, we have tried adding messages at both the fields and page through the response data transform of the data page, but they didn’t work.
In this regard, can you please shed some light on how can achieve this requirement. Appreciate any inputs.
From my understanding, this is expected in Constellation.
Messages added in the data page (response data transform) won’t show on the UI because Constellation only renders messages that come from the case layer (flow actions/assignments), not directly from data pages or connectors.
Flow action level validation and post processing works. However, The requirement is to display the web server response, even before submitting the flow action, when we receive the response from the web service call.
Also, when we map the value to a case property, the UI doesn’t refresh and the message is not shown.
I tried the same scenario and setup some error message in the response data transform of the data page where the external rest api is called and i am able to see the error message on the UI as shown below,
And as per the post shared by Marie, i am seeing an additional error message as well for which v26 will have a fix.
To summarize, if you external API returns an error, then set the custom error messages on your DPage context which then will automatically show up on the UI as shown above.
If you want the error messages to be shown in the search and select block itself, then i believe you should write the custom component as mentioned in the article by Laveesh.