vxe-table 3.4.7-beta.1 → 3.4.7-beta.2

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/lib/index.umd.js CHANGED
@@ -13609,7 +13609,9 @@ var Methods = {
13609
13609
  fullDataRowMap = this.fullDataRowMap,
13610
13610
  fullAllDataRowMap = this.fullAllDataRowMap,
13611
13611
  fullAllDataRowIdData = this.fullAllDataRowIdData;
13612
- var children = treeOpts.children;
13612
+ var transform = treeOpts.transform,
13613
+ children = treeOpts.children,
13614
+ mapChildren = treeOpts.mapChildren;
13613
13615
  var rest = fullAllDataRowIdData[methods_getRowid(this, row)];
13614
13616
  var parentLevel = rest ? rest.level : 0;
13615
13617
  return this.createData(childRecords).then(function (rows) {
@@ -13643,6 +13645,11 @@ var Methods = {
13643
13645
  fullAllDataRowMap.set(childRow, rest);
13644
13646
  }, treeOpts);
13645
13647
  row[children] = rows;
13648
+
13649
+ if (transform) {
13650
+ row[mapChildren] = rows;
13651
+ }
13652
+
13646
13653
  return rows;
13647
13654
  });
13648
13655
  },
@@ -18047,7 +18054,8 @@ var Methods = {
18047
18054
  treeOpts = this.treeOpts,
18048
18055
  treeLazyLoadeds = this.treeLazyLoadeds,
18049
18056
  checkboxOpts = this.checkboxOpts;
18050
- var loadMethod = treeOpts.loadMethod;
18057
+ var transform = treeOpts.transform,
18058
+ loadMethod = treeOpts.loadMethod;
18051
18059
  var checkStrictly = checkboxOpts.checkStrictly;
18052
18060
  var rest = fullAllDataRowMap.get(row);
18053
18061
  return new Promise(function (resolve) {
@@ -18077,10 +18085,24 @@ var Methods = {
18077
18085
  if (!checkStrictly && _this43.isCheckedByCheckboxRow(row)) {
18078
18086
  _this43.setCheckboxRow(childRows, true);
18079
18087
  }
18088
+
18089
+ _this43.$nextTick().then(function () {
18090
+ if (transform) {
18091
+ return _this43.handleTableData();
18092
+ }
18093
+ }).then(function () {
18094
+ return _this43.recalculate();
18095
+ }).then(function () {
18096
+ return resolve();
18097
+ });
18098
+ });
18099
+ } else {
18100
+ _this43.$nextTick().then(function () {
18101
+ return _this43.recalculate();
18102
+ }).then(function () {
18103
+ return resolve();
18080
18104
  });
18081
18105
  }
18082
-
18083
- resolve(_this43.$nextTick().then(_this43.recalculate));
18084
18106
  });
18085
18107
  });
18086
18108
  },