The values are successfully populated immediately after the DT execution.
However, when the user clicks on any other field in the same page:
The populated values disappear from the UI
The values are also not persisted on the clipboard
Attempted Workaround
Stored integration response values in separate (non-UI-bound) properties.
Used a Declare Expression to set the values into the UI-bound properties.
However, this approach did not resolve the issue, and values still do not persist.
Concern: It appears that the values set during the refresh are not retained in the clipboard. And, as this fields are in middle of the UI so we cannot use Pre DT/Post DT as well.
Request
Has anyone encountered similar behavior with Form Refresh + Read-only fields in Constellation? Are there recommended patterns or best practices for this issue?
Any insights, especially around clipboard persistence, refresh strategy, or Constellation-specific behavior, would be highly appreciated.
This is the expected out-of-the-box behavior in Constellation.
Unlike Traditional APIs built on Server-Side rendering, Constellation relies completely on DX APIs. When a user interacts with a field and triggers a network request, Constellation only includes editable/user-input fields in the outbound API request payload. Read-only fields are completely excluded from this payload. You can verify this by inspecting the request payload in your browser’s Network tab during the event.
Because Constellation fetches the latest case state from the database for each subsequent API call and overlays only the modified payload data, any values assigned to read-only properties via a client-side form refresh or Data Transform are lost on the next interaction.
To persist these values, the properties must either be editable on the UI (even if styled differently) or populated via a backend process (like a Savable Data Page or Post-Data Transform during an actual assignment submission) rather than relying on standard Form Refresh settings for read-only fields.
Would need a little more on the data model here but I’ll make some assumptions.
Account is a Data Reference.
Data references have patterns to show more details or links to see more details
Event driven UI approach with action sets in Traditional was the right approach but in Constellation you want to show mode details about that Data Reference (even if those details come from an external SOR).
Examples
Based on selection of a data reference you can show additional views
Another version of this I’ve been working on this week
Another i created for a forums post last month (I think this was for another of your questions)
And a video with this working
Additional View
These require a little more configuration and visibility conditions that force server refreshes (when rule conditions not the “always” condition).Can share a video on this if needed.
Mixed data model
Where I am unsure on approach, from your image here.
This is clearly embedded data, as you are trying to capture details form the user (and help them by prefilling those details). I am unsure if there is a way to mix the UX as you have - data references and embedded data are separate views.
You can show data reference details inline, and choose what to display.
Use a dynamic text rule in Additional Information, Helper Text, Instructions etc. to show the required information to help guide the user input the correct information in the fields. A few screenshots as samples:
Could you help me understand the user interaction a bit more from an “expected outcome” perspective?
Which field triggers the form refresh? Account number? Or Service Type?
What is the use case for the user changing those values? Did they make a mistake in the selection and need to correct it? Or some other reason?
Which values from the screenshot are the user supplying (or changing)? Is the expectation that those values would then be saved back to the system of record from which the data was retrieved?
Which fields are read-only? Is that data required for the user to determine how to move forward in the workflow? Or is it just for reference?
However, two additional solutions I can add to the mix:
Calculations - these are read-only but the declare expression is what updates the values on screen, you could use that to show these fields.
This is my preferred solution (including the ones I previously gave in this thread)
Editable state - read-only when has value: I haven’t tested this, but from what I know of the DX API and Constellation this should work but worth testing:
Configure the field as editable
Use form refresh to set value
Conditionally read only:
Mark as disabled when it has a value (when rule, so it triggers a server side interaction and gets the value from the server) OR
conditionally show editable/read only versions based on the value
HI Marc, thank you for your quick response. Unfortunately, as i mentioned on my post we had tried using Declaration expression, but that workaround didn’t work. We had also tried marking Read-Only or Disabled (based on condition) but those workarounds didn’t worked as well.
Hi Marc, Account is neither a data reference nor an embedded data type. We are invoking the integration Data Page (D_Page) via the Form Refresh setting and directly mapping the values returned in the Data Page response to the corresponding UI properties. I will try to send more details on Data models that Di has requested for better understanding.
Hi Ramesh, apologies for late response. Actually, we went with another approach and now displaying data in a tabular format instead of fields. This tabular format sources data from a D_page which is getting data from integration D_page.
There’s a Solution for your requirement. Use "pyRefreshData - Data Transform" instead of Form Refresh Setting.
Write your logic using when conditions, so the disabled properties or Read only values will not get disappeared.