Skip to content

Commit

Permalink
VCST-2300: remove empty objects from ui grid state (#2866)
Browse files Browse the repository at this point in the history
  • Loading branch information
basilkot authored Dec 18, 2024
1 parent b47aaa2 commit a80daee
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/VirtoCommerce.Platform.Web/wwwroot/js/common/uiGridUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,15 @@ angular.module('platformWebApp')

if (gridApi.saveState) {
if (savedState) {
//$timeout(function () {

Object.keys(savedState).forEach(function (key) {
const value = savedState[key];
if (_.isEmpty(value)) {
savedState[key] = undefined;
}
});

gridApi.saveState.restore($scope, savedState);
//}, 10);
}

if (gridApi.colResizable)
Expand Down

0 comments on commit a80daee

Please sign in to comment.