Skip to content

Commit 2531a52

Browse files
committed
chore(datagrid-web): revert reference set support for 9.24
1 parent 4c645f2 commit 2531a52

File tree

9 files changed

+19
-83
lines changed

9 files changed

+19
-83
lines changed

packages/modules/data-widgets/CHANGELOG.md

+4-54
Original file line numberDiff line numberDiff line change
@@ -6,57 +6,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66

77
## [Unreleased]
88

9-
## [2.26.0] DataWidgets - 2024-10-31
10-
11-
### [2.10.3] DatagridDateFilter
12-
13-
#### Fixed
14-
15-
- We fixed an issue with grid wide filters not resetting.
16-
17-
### [2.9.2] DatagridDropdownFilter
18-
19-
#### Fixed
20-
21-
- We fixed an issue where onChange events were not being triggered on dropdown filter.
22-
23-
- We fixed an issue with dropdown filters in some cases not setting or resetting.
24-
25-
### [2.8.3] DatagridNumberFilter
26-
27-
#### Fixed
28-
29-
- We fixed an issue with grid wide filters not resetting.
30-
31-
### [2.8.3] DatagridTextFilter
32-
33-
#### Fixed
34-
35-
- We fixed an issue with grid wide filters not resetting.
36-
37-
### [2.26.1] Datagrid
38-
39-
#### Changed
40-
41-
- We improved our drop-down filter integration - now the drop-down can store its value in the personalization config. For best results, the new 'Use lazy load' property should be set to false.
42-
43-
#### Added
44-
45-
- We added new 'Use lazy load' property that can be used to improve the end-user experience.
46-
47-
#### Fixed
48-
49-
- We fixed an issue with grid wide filters not resetting.
50-
51-
### [1.12.2] Gallery
52-
53-
#### Fixed
54-
55-
- We resolved an issue where the gallery filter was not being applied at first.
56-
57-
- We fixed an issue with grid wide filters not resetting.
58-
59-
## [2.24.1] DataWidgets - 2024-10-14
9+
## [2.23.2] DataWidgets - 2024-10-14
6010

6111
### Fixed
6212

@@ -74,7 +24,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
7424

7525
- We fixed an issue where filters wouldn't reset.
7626

77-
## [2.24.0] DataWidgets - 2024-09-23
27+
## [2.23.1] DataWidgets - 2024-09-25
7828

7929
### [2.10.2] DatagridDateFilter
8030

@@ -104,11 +54,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
10454

10555
- Widget maintenance.
10656

107-
### [2.24.0] Datagrid
57+
### [2.23.1] Datagrid
10858

10959
#### Added
11060

111-
- We have introduced support for reference set associations in the linked attribute property.
61+
- Widget maintenance.
11262

11363
### [1.2.1] DropdownSort
11464

packages/modules/data-widgets/package.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@mendix/data-widgets",
33
"moduleName": "Data Widgets",
4-
"version": "2.28.0",
4+
"version": "2.27.0",
55
"license": "Apache-2.0",
66
"copyright": "© Mendix Technology BV 2023. All rights reserved.",
77
"private": true,
@@ -27,13 +27,13 @@
2727
},
2828
"moduleFolderNameInModeler": "datawidgets",
2929
"marketplace": {
30-
"minimumMXVersion": "10.12.6.46815",
30+
"minimumMXVersion": "9.24.0.2965",
3131
"appNumber": 116540,
3232
"appName": "Data Widgets"
3333
},
3434
"testProject": {
3535
"githubUrl": "https://github.com/mendix/DataWidgets-module",
36-
"branchName": "main"
36+
"branchName": "data-widgets-backport-9-24"
3737
},
3838
"scripts": {
3939
"verify": "rui-verify-package-format",

packages/pluggableWidgets/datagrid-web/CHANGELOG.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
3232

3333
- We fixed an issue with grid wide filters not resetting.
3434

35-
## [2.24.0] - 2024-09-23
35+
## [2.23.1] - 2024-09-25
3636

37-
### Added
37+
### Changed
3838

39-
- We have introduced support for reference set associations in the linked attribute property.
39+
- Widget maintenance.
4040

4141
## [2.23.0] - 2024-09-20
4242

packages/pluggableWidgets/datagrid-web/package.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@mendix/datagrid-web",
33
"widgetName": "Datagrid",
4-
"version": "2.28.0",
4+
"version": "2.27.0",
55
"description": "",
66
"copyright": "© Mendix Technology BV 2023. All rights reserved.",
77
"private": true,
@@ -17,12 +17,12 @@
1717
"mpkName": "com.mendix.widget.web.Datagrid.mpk"
1818
},
1919
"marketplace": {
20-
"minimumMXVersion": "10.12.0",
20+
"minimumMXVersion": "9.24.0.2965",
2121
"appName": "Data Grid 2"
2222
},
2323
"testProject": {
2424
"githubUrl": "https://github.com/mendix/testProjects",
25-
"branchName": "datagrid-web-referenceSet"
25+
"branchName": "datagrid-web-next"
2626
},
2727
"packagePath": "com.mendix.widget.web",
2828
"scripts": {

packages/pluggableWidgets/datagrid-web/src/Datagrid.xml

-4
Original file line numberDiff line numberDiff line change
@@ -86,10 +86,6 @@
8686
<attributeType name="Integer" />
8787
<attributeType name="Long" />
8888
</attributeTypes>
89-
<associationTypes>
90-
<associationType name="Reference" />
91-
<associationType name="ReferenceSet" />
92-
</associationTypes>
9389
</property>
9490
<property key="content" type="widgets" dataSource="../datasource" required="false">
9591
<caption>Custom content</caption>

packages/pluggableWidgets/datagrid-web/src/helpers/state/column/ColumnFilterStore.tsx

+2-9
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import { StaticSelectFilterStore } from "@mendix/widget-plugin-filtering/stores/
44
import { InputFilterStore, attrgroupFilterStore } from "@mendix/widget-plugin-filtering/stores/store-utils";
55
import { ensure } from "@mendix/widget-plugin-platform/utils/ensure";
66
import { FilterCondition } from "mendix/filters";
7-
import { ListAttributeValue, ListAttributeListValue } from "mendix";
87
import { action, computed, makeObservable } from "mobx";
98
import { ReactNode, createElement } from "react";
109
import { ColumnsType } from "../../../../typings/DatagridProps";
@@ -50,7 +49,7 @@ export class ColumnFilterStore implements IColumnFilterStore {
5049

5150
if (store.type === "refselect") {
5251
store.updateProps(this.toRefselectProps(props));
53-
} else if (isListAttributeValue(props.attribute)) {
52+
} else if (props.attribute) {
5453
store.updateProps([props.attribute]);
5554
}
5655
}
@@ -69,7 +68,7 @@ export class ColumnFilterStore implements IColumnFilterStore {
6968
return new RefFilterStore(this.toRefselectProps(props), dsViewState);
7069
}
7170

72-
if (isListAttributeValue(props.attribute)) {
71+
if (props.attribute) {
7372
return attrgroupFilterStore(props.attribute.type, [props.attribute], dsViewState);
7473
}
7574

@@ -108,11 +107,5 @@ export class ColumnFilterStore implements IColumnFilterStore {
108107
}
109108
}
110109

111-
const isListAttributeValue = (
112-
attribute?: ListAttributeValue | ListAttributeListValue
113-
): attribute is ListAttributeValue => {
114-
return !!(attribute && attribute.isList === false);
115-
};
116-
117110
const errorMessage = (propName: string): string =>
118111
`Can't map ColumnsType to AssociationProperties: ${propName} is undefined`;

packages/pluggableWidgets/datagrid-web/src/helpers/state/column/ColumnStore.tsx

+1-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import {
22
DynamicValue,
33
ListAttributeValue,
4-
ListAttributeListValue,
54
ListExpressionValue,
65
ListWidgetValue,
76
ObjectItem,
@@ -35,9 +34,7 @@ export class ColumnStore implements GridColumn {
3534
private _header?: DynamicValue<string> = undefined; // can render when unavailable
3635
private _columnClass?: ListExpressionValue<string> = undefined; // can render when unavailable
3736
private _tooltip?: ListExpressionValue<string> = undefined; // part of attribute or dynamicText
38-
private _attribute?:
39-
| ListAttributeValue<string | Big | boolean | Date>
40-
| ListAttributeListValue<string | Big | boolean | Date> = undefined; // as "attribute"
37+
private _attribute?: ListAttributeValue<string | Big | boolean | Date> = undefined; // as "attribute"
4138
private _dynamicText?: ListExpressionValue<string> = undefined; // as "dynamicText"
4239
private _content?: ListWidgetValue = undefined; // as "customContent"
4340

packages/pluggableWidgets/datagrid-web/src/package.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8" ?>
22
<package xmlns="http://www.mendix.com/package/1.0/">
3-
<clientModule name="Datagrid" version="2.28.0" xmlns="http://www.mendix.com/clientModule/1.0/">
3+
<clientModule name="Datagrid" version="2.27.0" xmlns="http://www.mendix.com/clientModule/1.0/">
44
<widgetFiles>
55
<widgetFile path="Datagrid.xml" />
66
</widgetFiles>

packages/pluggableWidgets/datagrid-web/typings/DatagridProps.d.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* @author Mendix Widgets Framework Team
55
*/
66
import { ComponentType, CSSProperties, ReactNode } from "react";
7-
import { ActionValue, DynamicValue, EditableValue, ListValue, ListActionValue, ListAttributeValue, ListAttributeListValue, ListExpressionValue, ListReferenceValue, ListReferenceSetValue, ListWidgetValue, SelectionSingleValue, SelectionMultiValue } from "mendix";
7+
import { ActionValue, DynamicValue, EditableValue, ListValue, ListActionValue, ListAttributeValue, ListExpressionValue, ListReferenceValue, ListReferenceSetValue, ListWidgetValue, SelectionSingleValue, SelectionMultiValue } from "mendix";
88
import { Big } from "big.js";
99

1010
export type ItemSelectionMethodEnum = "checkbox" | "rowClick";
@@ -25,7 +25,7 @@ export type AlignmentEnum = "left" | "center" | "right";
2525

2626
export interface ColumnsType {
2727
showContentAs: ShowContentAsEnum;
28-
attribute?: ListAttributeValue<string | Big | boolean | Date> | ListAttributeListValue<string | Big | boolean | Date>;
28+
attribute?: ListAttributeValue<string | Big | boolean | Date>;
2929
content?: ListWidgetValue;
3030
dynamicText?: ListExpressionValue<string>;
3131
exportValue?: ListExpressionValue<string>;

0 commit comments

Comments
 (0)