@sd-angular/core 1.1.35 → 1.1.38

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.
@@ -1669,28 +1669,25 @@
1669
1669
  return [2 /*return*/, value];
1670
1670
  }
1671
1671
  _f = column.option, items = _f.items, valueField = _f.valueField, displayField = _f.displayField;
1672
- if (!(typeof (items) === 'function')) return [3 /*break*/, 3];
1673
1672
  key = hash__namespace(Object.assign(Object.assign({ prefix: __classPrivateFieldGet(this, _prefix$1) }, column), { value: value }));
1673
+ if (!(typeof (items) === 'function')) return [3 /*break*/, 3];
1674
1674
  if (!!__classPrivateFieldGet(this, _cache$1)[key]) return [3 /*break*/, 2];
1675
1675
  return [4 /*yield*/, items(value, true)];
1676
1676
  case 1:
1677
1677
  values = _g.sent();
1678
1678
  __classPrivateFieldGet(this, _cache$1)[key] = {
1679
- items: values,
1680
- obj: Array.toObject(values, valueField)
1679
+ result: ((_d = values === null || values === void 0 ? void 0 : values.find(function (e) { return (e === null || e === void 0 ? void 0 : e[valueField]) === value; })) === null || _d === void 0 ? void 0 : _d[displayField]) || value
1681
1680
  };
1682
1681
  _g.label = 2;
1683
1682
  case 2: return [3 /*break*/, 4];
1684
1683
  case 3:
1685
- key = hash__namespace(Object.assign({ prefix: __classPrivateFieldGet(this, _prefix$1) }, column));
1686
1684
  if (!__classPrivateFieldGet(this, _cache$1)[key]) {
1687
1685
  __classPrivateFieldGet(this, _cache$1)[key] = {
1688
- items: items || [],
1689
- obj: Array.toObject(items, valueField)
1686
+ result: ((_e = items === null || items === void 0 ? void 0 : items.find(function (e) { return (e === null || e === void 0 ? void 0 : e[valueField]) === value; })) === null || _e === void 0 ? void 0 : _e[displayField]) || value
1690
1687
  };
1691
1688
  }
1692
1689
  _g.label = 4;
1693
- case 4: return [2 /*return*/, (_e = (_d = __classPrivateFieldGet(this, _cache$1)[key].obj[value]) === null || _d === void 0 ? void 0 : _d[displayField]) !== null && _e !== void 0 ? _e : value];
1690
+ case 4: return [2 /*return*/, __classPrivateFieldGet(this, _cache$1)[key].result];
1694
1691
  }
1695
1692
  });
1696
1693
  }); };
@@ -4027,8 +4024,9 @@
4027
4024
  item.editorHandlerRow = Object.assign(Object.assign({}, item.editorHandlerRow), { visible: false, editable: !status, removable: false, savable: false, cancelable: false });
4028
4025
  }
4029
4026
  // const { sdId, editorHandlerColumn, ...remain } = item;
4030
- var sdId = item.sdId, editorHandlerColumn = item.editorHandlerColumn, expandDetail = item.expandDetail, isExpanded = item.isExpanded, isExpanding = item.isExpanding, isSelected = item.isSelected, sdGroup = item.sdGroup, selectable = item.selectable, actions = item.actions, editorHandlerRow = item.editorHandlerRow, groupedActions = item.groupedActions, originItem = item.originItem, editorErrorMessage = item.editorErrorMessage, remain = __rest(item, ["sdId", "editorHandlerColumn", "expandDetail", "isExpanded", "isExpanding", "isSelected", "sdGroup", "selectable", "actions", "editorHandlerRow", "groupedActions", "originItem", "editorErrorMessage"]);
4027
+ var sdId = item.sdId, editorHandlerColumn = item.editorHandlerColumn, expandDetail = item.expandDetail, isExpanded = item.isExpanded, isExpanding = item.isExpanding, isSelected = item.isSelected, sdGroup = item.sdGroup, selectable = item.selectable, actions = item.actions, groupedActions = item.groupedActions, originItem = item.originItem, editorErrorMessage = item.editorErrorMessage, remain = __rest(item, ["sdId", "editorHandlerColumn", "expandDetail", "isExpanded", "isExpanding", "isSelected", "sdGroup", "selectable", "actions", "groupedActions", "originItem", "editorErrorMessage"]);
4031
4028
  item.sdId = hash__default['default'](remain);
4029
+ item.editorHandlerColumn = item.editorHandlerColumn || {};
4032
4030
  var columns = gridOption.columns;
4033
4031
  try {
4034
4032
  for (var columns_1 = __values(columns), columns_1_1 = columns_1.next(); !columns_1_1.done; columns_1_1 = columns_1.next()) {
@@ -4076,7 +4074,7 @@
4076
4074
  if (column.type === 'children' || column.type === 'children-col') {
4077
4075
  return;
4078
4076
  }
4079
- var sdId = item.sdId, editorHandlerColumn = item.editorHandlerColumn, expandDetail = item.expandDetail, isExpanded = item.isExpanded, isExpanding = item.isExpanding, isSelected = item.isSelected, sdGroup = item.sdGroup, selectable = item.selectable, actions = item.actions, editorHandlerRow = item.editorHandlerRow, groupedActions = item.groupedActions, originItem = item.originItem, editorErrorMessage = item.editorErrorMessage, remain = __rest(item, ["sdId", "editorHandlerColumn", "expandDetail", "isExpanded", "isExpanding", "isSelected", "sdGroup", "selectable", "actions", "editorHandlerRow", "groupedActions", "originItem", "editorErrorMessage"]);
4077
+ var sdId = item.sdId, editorHandlerColumn = item.editorHandlerColumn, expandDetail = item.expandDetail, isExpanded = item.isExpanded, isExpanding = item.isExpanding, isSelected = item.isSelected, sdGroup = item.sdGroup, selectable = item.selectable, actions = item.actions, groupedActions = item.groupedActions, originItem = item.originItem, editorErrorMessage = item.editorErrorMessage, remain = __rest(item, ["sdId", "editorHandlerColumn", "expandDetail", "isExpanded", "isExpanding", "isSelected", "sdGroup", "selectable", "actions", "groupedActions", "originItem", "editorErrorMessage"]);
4080
4078
  var key = hash__default['default'](remain);
4081
4079
  if (item.sdId === key && item.editorHandlerColumn) {
4082
4080
  return;