53
Views
3
Comments
Solved
[OutSystems Data Grid] [Data Grid] Highlight rows OnInitialize
outsystems-data-grid
Reactive icon
Forge asset by OutSystems

I have a requirement where I found a solution but is not optimal.

I have a data grid with a list of Employees, where I can add to it more employees from a different page and when I return to the grid page I want to see the employees that were added, highlighting the rows where they are because I have a custom sort that is not by Id and was difficult to see where were the new ones placed.

My solution: Having a control attribute in the query where it finds all the records created in the last minute, and do a conditional format to apply background when that is true.

The issue is the user will always see this control column in the column picker menu even if is hidden and disabled.

Is there a way to change the row background accessing that value IsAddedRecently directly from the query, without creating the Control column?

Or remove it from the column picker menu so that only the devs can see it?

Or is there a better approach to this case?

Thank you.

Best regards.

2022-11-12 11-28-30
Gonçalo Martins
Staff
Solution

Hello @Gonçalo Aguiar 

Have you tried to use the client action SetColumnVisibility
This sets the visibility of the hidden columns (Visible = False and CanBeHidden = False) on the grid Column Picker and, by default, all columns are displayed in the Column Picker.
Hope it helps.

Cheers,
GM

2022-03-29 16-12-55
Gonçalo Aguiar

Thanks @Gonçalo Martins that worked perfectly, I didn't noticed that API, was reading the ones in https://outsystemsui.outsystems.com/OutSystemsDataGridSample/API and was not there.

As a side note, will there be a select all for the column picker?


Thanks.

Best Regards,

Gonçalo Aguiar

2022-11-12 11-28-30
Gonçalo Martins
Staff

Hi @Gonçalo Aguiar 

Nice to know it helped.
About not being on the documentation that is already on our backlog for the next release (to add all the ones related to ColumnPicker and Export).
About having a select all in the Column Picker, there's no plan for that and I'm not even checked if Wijmo offers that.

Cheers,
GM

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.