Question
Last activity: 19 Apr 2016 5:19 EDT
How do I make sure a collapsed header stays collapsed after refresh?
I have section A which is in a row-repeat layout. I have 2 sections (B & C) embedded in section A wherein both are using collapsible header types. Section B stays collapsed but section C gets expanded when I add a new row and the screen gets refreshed. Any ideas?
Pega v6.2 SP2
Message was edited by: Lochan to add Category
-
Like (0)
-
Share this page Facebook Twitter LinkedIn Email Copying... Copied!
Pegasystems Inc.
IN
Hi Rachel,
Adding a new row makes previous row embedded section C gets expanded or in the new row itself?
If in new row then check Section C configuration, layout is default in collapsed or expanded form, any expand when condition configured?
If possible please share snapshot of the issue.
Hi Shibani,
Thanks for the reply.
Section C gets expanded in the previous row where I collapsed it. Default is to have it expanded for new rows which is rendering correctly. I don't have any expand when condition set up.
The configuration in embedding and setting it as collapsible is the same for sections B and C. Only difference is the content.
So basically in design time both Section B and Section C layout headers are kept collapsed by default. But during run time, as and when rows are added, Section B remains collapsed whereas Section C is expanded.
Is my observation correct ?
Hi Sathish,
By default, sections B and C are expanded. After the user input details into the sections, the user collapsed the 2 sections and then clicked on add. A new row is then added. So I now have 2 section As.
Section A1 has section B1 collapsed and section C1 expanded. Section A2 has section B2 expanded and section C2 expanded.
My issue here is that section C1 should stay collapsed since the user set it to collapsed before adding a new row.
UnitedHealth Group
IN
Hi Prasad,
Thanks for that. However, I still want the section to be expanded when adding a new row. It's just that when I collapse the section, I want it to stay collapsed even after I refresh it.
I noticed just now that all the sections I have that are collapsible and in a row repeat expands when the screen gets refreshed.
Pegasystems Inc.
IN
Hi Rachel,
Do you have any action items configured in "Add Row" other than OOTB config?
Hi Shibani,
The adding of another row is in a button that's outside the section. We're not using the OOTB add row button in the row repeat.
Pegasystems Inc.
IN
Hi Rachel,
Is there any specific need not to use OOTB Add Row button.OOTB add row button does not have this issue.Seems like Add Row button outside the section has impact .If possible use OOTB button for Add Row.
And yes As Sathish suggested , modify the design to use Grid Layout.
Shibani,
Thing is in case of old row repeat layout, even though we use OOTB add row action, we still do refresh of the whole grid. Now to get the partial refresh functionality, the application developer has to check row reordering in the layout property panel. Basically with this option checked, we use grid generation logic to generate row repeat thereby enabling partial refresh.
And one more thing, Add row button has to be within the purview of either the row repeat layout / Grid layout (either in grid action top or bottom). We cannot target add action from outside of repeating structure (the only exception to this rule is Repeating Dynamic Layout). But we are actually planning to enhance this so that users can target Add row action using datasource. This will remove the tight coupling of Add row action with the layout.
Can you switch to Grid layout instread of Row Repeat layout ?
Using grid layout, you will be getting the OOTB partial refresh feature i.e. when you add a row, only the newly added row's markup will be brought back from then server and gets appended to the DOM. Since the exisitng rows are not getting refreshed, the collapsed / expanded state of the section will remain intact.
Hi Sathish,
I'll raise that with the client as it will change the way things look at the moment. Thanks!