Question
Pegasystems Inc.
GB
Last activity: 17 Jul 2017 15:43 EDT
Grid Repeat Layout: Select Multiple Rows
Hi Folks,
I wanted to ask if there are any plans to implement option to select multiple rows in a grid repeat layout.
My feeling is that we had this option in list view but I'd really like to stick with the latest controls. Would that be something we are working on? Is there any temporary workaround to archive this without messing up the configuration much?
The use case is pretty obvious - we want to edit / delete / action multiple items in a grid without having to go one by one.
Example from WordPress:
Thanks a lot for your help!
-Jiri
Hi Folks,
I wanted to ask if there are any plans to implement option to select multiple rows in a grid repeat layout.
My feeling is that we had this option in list view but I'd really like to stick with the latest controls. Would that be something we are working on? Is there any temporary workaround to archive this without messing up the configuration much?
The use case is pretty obvious - we want to edit / delete / action multiple items in a grid without having to go one by one.
Example from WordPress:
Thanks a lot for your help!
-Jiri
-
Like (0)
-
Share this page Facebook Twitter LinkedIn Email Copying... Copied!
Pegasystems Inc.
GB
Pegasystems Inc.
GB
Hi Marc,
Yes, we have that configured and functionality works fine.
Example:
This case is really confusing and that was the reason for me to open this topic. If we highlighted all selected rows, it would make sense. The issue I see is that Pega actually allows me to select only one row at a time - the fact that I can reference pySelected is fine but it's not linked to the grid layout.
To simplify it - is there any way to link checkbox to the grid layout so it's highlighting all selected rows?
Example (Gmail):
Let me know if you agree/disagree with what we're trying to do. For now, we turned off the highlighting completely to not confuse users.
Thanks
Jiri
Pegasystems Inc.
GB
Ah ok, so you are just talking about the highlighting rather than actual selection? The highlighting is currently only for row hovering as far as I can see.
I have tested using pySelected and can select multiple rows, I can see the pySelected values on the clipboard. I can also configure a button to run a data transform to check all the rows... but I guess this isn't actually what you are asking about.
Pegasystems Inc.
GB
Pegasystems Inc.
GB
Yes, you can configure this in the skin rule. It works fine for us - unfortunately, only for one item at a time (it's ignoring selected state of checkbox).
Pegasystems Inc.
GB
Exactly. It's about the fact if we are planning to introduce this selection somehow OOTB. If it was planned, I guess the highlighting would be built in (or at least Pega could add a CSS class... something like gridCellMultipleSelect).
We've got everything working fine as you have.
If there are no plans to support this and there is no clean way to configure highlighting, I will have to go without it for "Multiselect grid".
Thanks Marc.
Atos Information Technology GmbH
DE
Hi Jiri,
i am probably going crazy here... please talk to you LSA about this before proposing it to anyone else:
I was thinking about using the grid actions to set focus, set a style (selected or not), and run a data transform to check and uncheck the checkbox...
something like this:
i am not sure about how to do the switch or if this is possible at all... (maybe run script action? btw, i always wondered if we could use that for JS maybe you can find this out for me! ) ...anyhow it may be worth a try...
The set focus, should be the one that gives the active row color to the clicked row, that is why you only have one row with that style (my guess here is that focus style is taken out with js once we have focus somewhere else), it is not selected style, it is FOCUS style.
Hi Jiri,
i am probably going crazy here... please talk to you LSA about this before proposing it to anyone else:
I was thinking about using the grid actions to set focus, set a style (selected or not), and run a data transform to check and uncheck the checkbox...
something like this:
i am not sure about how to do the switch or if this is possible at all... (maybe run script action? btw, i always wondered if we could use that for JS maybe you can find this out for me! ) ...anyhow it may be worth a try...
The set focus, should be the one that gives the active row color to the clicked row, that is why you only have one row with that style (my guess here is that focus style is taken out with js once we have focus somewhere else), it is not selected style, it is FOCUS style.
Imho the way the skin treats focus and selected is confusing. It took me a while to figure out that focus works with the keyboard and on click (which is actually on the actions tab) and was thinking that click should actually be "selected". After a couple of tests I realized that selected is actually what happens on the focused row once you leave the grid (click outside)
To make it more confusing, in the rendered code (html&css) the class ".gridCellSelected" applies to both focus and selected skin styles. THE ONLY DIFFERENCE between both of them is that once you click out, the TR will get an extra css class "notFocused" that will overwrite the focus row style with the selected row style.
sample of skin "focus row" code>
div.gridDefault div.default div#gridBody_right td.gridCellSelected
sample of skin "selected row" code>
div.gridDefault div.default div#gridBody_right tr.notFocused td.gridCellSelected
You can delete the action~focus if you do not find any better way to achieve the multiple style with my crazy thoughts.
Good luck, and please tell me how it goes!
B.
Pegasystems Inc.
GB
Hi Bea,
Thanks for your comment.
I thought about the same solution as you (setting focus, class + data transform). The main issue with this customization would be when you need to refresh section. When this happens, this customization would create additional cases to handle.
On the JS solution - it's not a good idea because of the same reason - when Pega does a section refresh, you would have to re initiate the script again because Pega generates new HTML structure. Ideally, we should have access to events in Pega such as "onAjaxCallComplete" but this is not the case (as far as I'm aware). The only solution would then be to run the script in certain interval to make sure you script is applied even after the grid is refreshed. This is a really bad solution from many point of views... for example performance.
Knowing all that - I avoid to highlight anything now (for multi select tables). We are still in very early stage and this is not a priority but if it becomes priority and I find a solution, I will let you know.
PS: Not sure if I'm correct but you can run script in java only. There might be option to run JavaScript in java too but I don't see much benefit against running JS on harness level. It applies to the whole DOM anyway.
Many thanks, J.