mmhglobal-dynamicform 1.1.11 → 1.1.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -3,6 +3,8 @@
3
3
  This library was generated with [Angular CLI](https://github.com/angular/angular-cli) version 11.2.13.
4
4
 
5
5
  ## Changelog
6
+ `1.1.12`<br/>
7
+ zgrid fix save state.
6
8
 
7
9
  `1.1.11`<br/>
8
10
  ztreelist html fix.<br/>
@@ -239,7 +239,7 @@
239
239
  ar[i] = from[i];
240
240
  }
241
241
  }
242
- return to.concat(ar || Array.prototype.slice.call(from));
242
+ return to.concat(ar || from);
243
243
  }
244
244
  function __await(v) {
245
245
  return this instanceof __await ? (this.v = v, this) : new __await(v);
@@ -5357,17 +5357,25 @@
5357
5357
  var _columns = _zgridComponent.columns;
5358
5358
  // Keep existing grid column setting
5359
5359
  this.zGridStatePersistingService.set(_gridName, this.columns);
5360
+ var configValue = _columns.toArray().map(function (item) {
5361
+ var _zGridColumnSettings = Object.keys(item)
5362
+ .filter(function (propName) {
5363
+ return !propName.toLowerCase().includes('template');
5364
+ })
5365
+ .reduce(function (acc, curr) {
5366
+ var _a;
5367
+ return (Object.assign(Object.assign({}, acc), (_a = {}, _a[curr] = item[curr], _a)));
5368
+ }, {});
5369
+ return _zGridColumnSettings;
5370
+ });
5371
+ // remove extra element form array
5372
+ configValue.forEach(function (item) {
5373
+ delete item['headerStyle'];
5374
+ delete item['__ngContext__'];
5375
+ });
5360
5376
  var gridSetting = {
5361
5377
  // state: this.state,
5362
- columnsConfig: _columns.toArray().map(function (item) {
5363
- var _zGridColumnSettings = Object.keys(item)
5364
- .filter(function (propName) { return !propName.toLowerCase().includes('template'); })
5365
- .reduce(function (acc, curr) {
5366
- var _a;
5367
- return (Object.assign(Object.assign({}, acc), (_a = {}, _a[curr] = item[curr], _a)));
5368
- }, {});
5369
- return _zGridColumnSettings;
5370
- })
5378
+ columnsConfig: configValue
5371
5379
  };
5372
5380
  // Find any setting from localstorage and update, if not just add in.
5373
5381
  var _arrGridCaching = this.zGridStatePersistingService.get(_storageKey);