Skip to content

Commit

Permalink
Merge pull request #102 from mendix/fix/sort-view-state
Browse files Browse the repository at this point in the history
Fix sort view state
  • Loading branch information
diego-antonelli committed Jun 28, 2021
2 parents f1d42a6 + 200c70b commit d1d1c99
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 3 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Expand Up @@ -6,6 +6,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

## [Unreleased]

## 1.3.15 - 2021-06-28

### Fixed

- We fixed a regression introduced in v1.3.10 which causes `Header Sort` and `Drop down Sort` to not keep the list view sorted when pressing back button.

## 1.3.14 - 2021-06-22

### Fixed
Expand Down
2 changes: 1 addition & 1 deletion package.json
@@ -1,7 +1,7 @@
{
"name": "list-view-controls",
"widgetName": "ListViewControls",
"version": "1.3.14",
"version": "1.3.15",
"description": "Search and filter Mendix list views",
"copyright": "Mendix BV",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion src/Shared/DataSourceHelper/DataSourceHelper.ts
Expand Up @@ -49,7 +49,7 @@ export class DataSourceHelper {
aspect.after(widget, "storeState", (store: (key: string, value: any) => void) => {
mx.logger.debug("after storeState");
if (widget.__customWidgetDataSourceHelper) {
const sorting = widget.__customWidgetDataSourceHelper.sorting && widget.__customWidgetDataSourceHelper.originalSort;
const sorting = widget.__customWidgetDataSourceHelper.sorting.length > 0 ? widget.__customWidgetDataSourceHelper.sorting : widget.__customWidgetDataSourceHelper.originalSort;
store("lvcSorting", sorting);
store("lvcConstraints", widget.__customWidgetDataSourceHelper.constraints);
store("lvcPaging", widget.__customWidgetDataSourceHelper.paging);
Expand Down
2 changes: 1 addition & 1 deletion src/package.xml
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8" ?>
<package xmlns="http://www.mendix.com/package/1.0/">
<clientModule name="ListViewControls" version="1.3.14" xmlns="http://www.mendix.com/clientModule/1.0/">
<clientModule name="ListViewControls" version="1.3.15" xmlns="http://www.mendix.com/clientModule/1.0/">
<widgetFiles>
<widgetFile path="CheckBoxFilter/CheckBoxFilter.xml"/>
<widgetFile path="DropDownFilter/DropDownFilter.xml"/>
Expand Down

0 comments on commit d1d1c99

Please sign in to comment.