Skip to content

Commit eafee27

Browse files
ROU-12515: Saved View filters don't show in UI since version 2.21.0 (#484)
* fix(layout, filter): fix issue with filter not being visually applied when usign SetViewLayout * fix(view): fix issue column not visible when using setViewLayout * chore(): update version to 2.21.2
1 parent d279b97 commit eafee27

File tree

4 files changed

+10
-13
lines changed

4 files changed

+10
-13
lines changed

gulp/DefaultSpecs.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ const constants = {
1919

2020
// Store the default project specifications
2121
const specs = {
22-
version: '2.21.1',
22+
version: '2.21.2',
2323
name: 'OutSystems DataGrid',
2424
description: '',
2525
url: 'Website:\n • ' + constants.websiteUrl,

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "outsystems-datagrid",
3-
"version": "2.21.1",
3+
"version": "2.21.2",
44
"description": "OutSystems Data Grid for Reactive Web",
55
"author": "UI Components Team",
66
"license": "BSD-3-Clause",

src/OSFramework/DataGrid/Constants.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// eslint-disable-next-line @typescript-eslint/no-unused-vars
22
namespace OSFramework.DataGrid.Constants {
33
/* OutSystems Data Grid Version */
4-
export const OSDataGridVersion = '2.21.1';
4+
export const OSDataGridVersion = '2.21.2';
55
/* OutSystems null values */
66
export const OSNullDate = '1900-01-01';
77
export const OSNullDateTime = '1900-01-01T00:00:00';

src/Providers/DataGrid/Wijmo/Features/View.ts

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -94,19 +94,16 @@ namespace Providers.DataGrid.Wijmo.Feature {
9494
*/
9595
private _setGroups(columns, config) {
9696
for (let i = 0; i < config.length; i++) {
97-
let colDef = columns.filter((x) => x.header === config[i].header);
97+
const colDef = columns.filter((x) => x.header === config[i].header);
9898
if (colDef.length > 0) {
99-
colDef = colDef[0];
99+
const colToUpdate = colDef[0];
100100
if (config[i].children && config[i].children.length > 0) {
101-
this._setGroups(colDef.columns, config[i].children[0]);
101+
this._setGroups(colToUpdate.columns, config[i].children[0]);
102102
}
103-
columns.remove(colDef);
104103
// due to Wijmo's breaking change, in case it is not defined, we need to assign an empty string to collapseTo property
105-
colDef.collapseTo = config[i].collapseTo ?? '';
106-
colDef.isCollapsed = config[i].isCollapsed || false; // in case it wasn't defined, set to false
107-
colDef.align = config[i].align || colDef.align;
108-
109-
columns.insert(i, colDef);
104+
colToUpdate.collapseTo = config[i].collapseTo ?? '';
105+
colToUpdate.isCollapsed = config[i].isCollapsed || false; // in case it wasn't defined, set to false
106+
colToUpdate.align = config[i].align || colToUpdate.align;
110107
}
111108
}
112109
}
@@ -139,12 +136,12 @@ namespace Providers.DataGrid.Wijmo.Feature {
139136

140137
const config = JSON.parse(state);
141138
this._grid.provider.deferUpdate(() => {
142-
this._reloadColumns(config);
143139
this._grid.features.filter.setViewLayout(config);
144140
this._grid.features.groupPanel.setViewLayout(config);
145141
this._grid.features.sort.setViewLayout(config);
146142
this._grid.features.columnFreeze.setViewLayout(config);
147143
this._setGroups(this._grid.provider.columnGroups, config.groupColumns);
144+
this._reloadColumns(config);
148145
});
149146
}
150147
}

0 commit comments

Comments
 (0)