vxe-table 4.1.9 → 4.1.11

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
@@ -8458,7 +8458,7 @@ var GlobalConfig = {
8458
8458
  // storage: false,
8459
8459
  // checkMethod () {}
8460
8460
  // },
8461
- // rowId: '_XID', // 行数据的唯一主键字段名
8461
+ // rowId: '_X_ID', // 行数据的唯一主键字段名
8462
8462
  sortConfig: {
8463
8463
  // remote: false,
8464
8464
  // trigger: 'default',
@@ -8476,6 +8476,7 @@ var GlobalConfig = {
8476
8476
  parentField: 'parentId',
8477
8477
  children: 'children',
8478
8478
  hasChild: 'hasChild',
8479
+ mapChildren: '_X_CHILD',
8479
8480
  indent: 20,
8480
8481
  showIcon: true
8481
8482
  },
@@ -8930,6 +8931,9 @@ var es_regexp_exec = __webpack_require__("ac1f");
8930
8931
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.replace.js
8931
8932
  var es_string_replace = __webpack_require__("5319");
8932
8933
 
8934
+ // EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.assign.js
8935
+ var es_object_assign = __webpack_require__("cca6");
8936
+
8933
8937
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.concat.js
8934
8938
  var es_array_concat = __webpack_require__("99af");
8935
8939
 
@@ -8974,6 +8978,7 @@ var es_string_fixed = __webpack_require__("c7cd");
8974
8978
 
8975
8979
 
8976
8980
 
8981
+
8977
8982
  var columnInfo_ColumnInfo = /*#__PURE__*/function () {
8978
8983
  /* eslint-disable @typescript-eslint/no-use-before-define */
8979
8984
  function ColumnInfo($xetable, _vm) {
@@ -9379,7 +9384,7 @@ function getRowUniqueId() {
9379
9384
  function getRowkey($xetable) {
9380
9385
  var props = $xetable.props;
9381
9386
  var rowId = props.rowId;
9382
- return rowId || '_XID';
9387
+ return rowId || '_X_ID';
9383
9388
  } // 行主键 value
9384
9389
 
9385
9390
  function util_getRowid($xetable, row) {
@@ -9732,6 +9737,7 @@ function getOnName(type) {
9732
9737
 
9733
9738
 
9734
9739
 
9740
+
9735
9741
  var componentDefaultModelProp = 'modelValue';
9736
9742
  var defaultCompProps = {
9737
9743
  transfer: true
@@ -10521,6 +10527,7 @@ var renderer = {
10521
10527
 
10522
10528
 
10523
10529
 
10530
+
10524
10531
  /**
10525
10532
  * 创建数据仓库
10526
10533
  */
@@ -10578,6 +10585,7 @@ var store_Store = /*#__PURE__*/function () {
10578
10585
  /* harmony default export */ var store = (store_Store);
10579
10586
  // CONCATENATED MODULE: ./packages/v-x-e-table/src/commands.ts
10580
10587
 
10588
+
10581
10589
  var commands = new store();
10582
10590
 
10583
10591
  if (true) {
@@ -10587,6 +10595,7 @@ if (true) {
10587
10595
  }
10588
10596
  // CONCATENATED MODULE: ./packages/v-x-e-table/src/menus.ts
10589
10597
 
10598
+
10590
10599
  var menus = new store();
10591
10600
 
10592
10601
  if (true) {
@@ -10596,6 +10605,7 @@ if (true) {
10596
10605
  }
10597
10606
  // CONCATENATED MODULE: ./packages/v-x-e-table/src/formats.ts
10598
10607
 
10608
+
10599
10609
  var formats = new store();
10600
10610
 
10601
10611
  if (true) {
@@ -10745,6 +10755,7 @@ var Icon = {
10745
10755
 
10746
10756
 
10747
10757
 
10758
+
10748
10759
  /* harmony default export */ var panel = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
10749
10760
  name: 'VxeTableFilter',
10750
10761
  props: {
@@ -10956,9 +10967,6 @@ var Icon = {
10956
10967
  return renderVN;
10957
10968
  }
10958
10969
  }));
10959
- // EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.assign.js
10960
- var es_object_assign = __webpack_require__("cca6");
10961
-
10962
10970
  // CONCATENATED MODULE: ./packages/filter/src/hook.ts
10963
10971
 
10964
10972
 
@@ -11076,7 +11084,7 @@ var tableFilterHook = {
11076
11084
  var maxHeight = null;
11077
11085
 
11078
11086
  if (filterHeight >= bodyElem.clientHeight) {
11079
- maxHeight = Math.max(40, bodyElem.clientHeight - (filterFootElem ? filterFootElem.offsetHeight : 0) - (filterHeadElem ? filterHeadElem.offsetHeight : 0));
11087
+ maxHeight = Math.max(60, bodyElem.clientHeight - (filterFootElem ? filterFootElem.offsetHeight : 0) - (filterHeadElem ? filterHeadElem.offsetHeight : 0));
11080
11088
  }
11081
11089
 
11082
11090
  if (column.fixed === 'left') {
@@ -11578,6 +11586,7 @@ if (browse.isDoc) {
11578
11586
 
11579
11587
 
11580
11588
 
11589
+
11581
11590
  var tableMenuMethodKeys = ['closeMenu'];
11582
11591
  var tableMenuHook = {
11583
11592
  setupTable: function setupTable($xetable) {
@@ -12002,6 +12011,9 @@ var es_symbol_description = __webpack_require__("e01a");
12002
12011
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.iterator.js
12003
12012
  var es_symbol_iterator = __webpack_require__("d28b");
12004
12013
 
12014
+ // EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.iterator.js
12015
+ var es_array_iterator = __webpack_require__("e260");
12016
+
12005
12017
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.iterator.js
12006
12018
  var es_string_iterator = __webpack_require__("3ca3");
12007
12019
 
@@ -12019,6 +12031,7 @@ var es_array_from = __webpack_require__("a630");
12019
12031
 
12020
12032
 
12021
12033
 
12034
+
12022
12035
  function _iterableToArray(iter) {
12023
12036
  if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
12024
12037
  }
@@ -12081,7 +12094,6 @@ var editHook = {
12081
12094
  computeMouseOpts = _$xetable$getComputeM.computeMouseOpts,
12082
12095
  computeEditOpts = _$xetable$getComputeM.computeEditOpts,
12083
12096
  computeCheckboxOpts = _$xetable$getComputeM.computeCheckboxOpts,
12084
- computeSYOpts = _$xetable$getComputeM.computeSYOpts,
12085
12097
  computeTreeOpts = _$xetable$getComputeM.computeTreeOpts;
12086
12098
 
12087
12099
  var editMethods = {};
@@ -12140,7 +12152,7 @@ var editHook = {
12140
12152
  }
12141
12153
 
12142
12154
  function insertTreeRow(newRecords, isAppend) {
12143
- var treeFullData = internalData.treeFullData,
12155
+ var tableFullTreeData = internalData.tableFullTreeData,
12144
12156
  afterFullData = internalData.afterFullData,
12145
12157
  fullDataRowIdData = internalData.fullDataRowIdData,
12146
12158
  fullAllDataRowIdData = internalData.fullAllDataRowIdData;
@@ -12149,7 +12161,7 @@ var editHook = {
12149
12161
  newRecords.forEach(function (item) {
12150
12162
  var parentRowId = item[treeOpts.parentField];
12151
12163
  var rowid = util_getRowid($xetable, item);
12152
- var matchObj = parentRowId ? external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.findTree(treeFullData, function (item) {
12164
+ var matchObj = parentRowId ? external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.findTree(tableFullTreeData, function (item) {
12153
12165
  return parentRowId === item[treeOpts.rowField];
12154
12166
  }, treeOpts) : null;
12155
12167
 
@@ -12185,7 +12197,7 @@ var editHook = {
12185
12197
  }
12186
12198
 
12187
12199
  afterFullData[funcName](item);
12188
- treeFullData[funcName](item);
12200
+ tableFullTreeData[funcName](item);
12189
12201
  var _rest = {
12190
12202
  row: item,
12191
12203
  rowid: rowid,
@@ -12193,7 +12205,7 @@ var editHook = {
12193
12205
  index: -1,
12194
12206
  _index: -1,
12195
12207
  $index: -1,
12196
- items: treeFullData,
12208
+ items: tableFullTreeData,
12197
12209
  parent: null,
12198
12210
  level: 0
12199
12211
  };
@@ -12201,7 +12213,6 @@ var editHook = {
12201
12213
  fullAllDataRowIdData[rowid] = _rest;
12202
12214
  }
12203
12215
  });
12204
- $xetable.updateVirtualTreeData();
12205
12216
  }
12206
12217
 
12207
12218
  editMethods = {
@@ -12227,14 +12238,12 @@ var editHook = {
12227
12238
 
12228
12239
  var treeConfig = props.treeConfig;
12229
12240
  var mergeList = reactData.mergeList,
12230
- editStore = reactData.editStore,
12231
- scrollYLoad = reactData.scrollYLoad;
12232
- var treeFullData = internalData.treeFullData,
12241
+ editStore = reactData.editStore;
12242
+ var tableFullTreeData = internalData.tableFullTreeData,
12233
12243
  afterFullData = internalData.afterFullData,
12234
12244
  tableFullData = internalData.tableFullData,
12235
12245
  fullDataRowIdData = internalData.fullDataRowIdData,
12236
12246
  fullAllDataRowIdData = internalData.fullAllDataRowIdData;
12237
- var sYOpts = computeSYOpts.value;
12238
12247
  var treeOpts = computeTreeOpts.value;
12239
12248
  var transform = treeOpts.transform;
12240
12249
 
@@ -12283,7 +12292,7 @@ var editHook = {
12283
12292
  } else {
12284
12293
  // 如果为虚拟树
12285
12294
  if (treeConfig && transform) {
12286
- var matchObj = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.findTree(treeFullData, function (item) {
12295
+ var matchObj = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.findTree(tableFullTreeData, function (item) {
12287
12296
  return row[treeOpts.rowField] === item[treeOpts.rowField];
12288
12297
  }, treeOpts);
12289
12298
 
@@ -12322,7 +12331,6 @@ var editHook = {
12322
12331
  fullDataRowIdData[rowid] = rest;
12323
12332
  fullAllDataRowIdData[rowid] = rest;
12324
12333
  });
12325
- $xetable.updateVirtualTreeData();
12326
12334
  } else {
12327
12335
  if (true) {
12328
12336
  warnLog('vxe.error.unableInsert');
@@ -12360,14 +12368,12 @@ var editHook = {
12360
12368
 
12361
12369
  (_editStore$insertList = editStore.insertList).unshift.apply(_editStore$insertList, _toConsumableArray(newRecords));
12362
12370
 
12363
- reactData.scrollYLoad = !treeConfig && sYOpts.gt > -1 && sYOpts.gt < tableFullData.length;
12364
12371
  $xetable.updateFooter();
12365
12372
  $xetable.cacheRowMap();
12366
- $xetable.handleTableData(transform);
12367
- $xetable.updateAfterDataIndex();
12373
+ $xetable.handleTableData(treeConfig && treeOpts.transform);
12368
12374
  $xetable.checkSelectionStatus();
12369
12375
 
12370
- if (scrollYLoad) {
12376
+ if (reactData.scrollYLoad) {
12371
12377
  $xetable.updateScrollYSpace();
12372
12378
  }
12373
12379
 
@@ -12392,13 +12398,11 @@ var editHook = {
12392
12398
  var treeConfig = props.treeConfig;
12393
12399
  var mergeList = reactData.mergeList,
12394
12400
  editStore = reactData.editStore,
12395
- selection = reactData.selection,
12396
- scrollYLoad = reactData.scrollYLoad;
12397
- var treeFullData = internalData.treeFullData,
12401
+ selection = reactData.selection;
12402
+ var tableFullTreeData = internalData.tableFullTreeData,
12398
12403
  afterFullData = internalData.afterFullData,
12399
12404
  tableFullData = internalData.tableFullData;
12400
12405
  var checkboxOpts = computeCheckboxOpts.value;
12401
- var sYOpts = computeSYOpts.value;
12402
12406
  var treeOpts = computeTreeOpts.value;
12403
12407
  var transform = treeOpts.transform;
12404
12408
  var actived = editStore.actived,
@@ -12441,7 +12445,7 @@ var editHook = {
12441
12445
  if (treeConfig && transform) {
12442
12446
  rows.forEach(function (row) {
12443
12447
  var rowid = util_getRowid($xetable, row);
12444
- var matchObj = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.findTree(treeFullData, function (item) {
12448
+ var matchObj = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.findTree(tableFullTreeData, function (item) {
12445
12449
  return rowid === util_getRowid($xetable, item);
12446
12450
  }, treeOpts);
12447
12451
 
@@ -12455,8 +12459,6 @@ var editHook = {
12455
12459
  if (afIndex > -1) {
12456
12460
  afterFullData.splice(afIndex, 1);
12457
12461
  }
12458
-
12459
- $xetable.updateVirtualTreeData();
12460
12462
  });
12461
12463
  } else {
12462
12464
  rows.forEach(function (row) {
@@ -12500,14 +12502,12 @@ var editHook = {
12500
12502
  insertList.splice(iIndex, 1);
12501
12503
  }
12502
12504
  });
12503
- reactData.scrollYLoad = !treeConfig && sYOpts.gt > -1 && sYOpts.gt < tableFullData.length;
12504
12505
  $xetable.updateFooter();
12505
12506
  $xetable.cacheRowMap();
12506
- $xetable.handleTableData(transform);
12507
- $xetable.updateAfterDataIndex();
12507
+ $xetable.handleTableData(treeConfig && treeOpts.transform);
12508
12508
  $xetable.checkSelectionStatus();
12509
12509
 
12510
- if (scrollYLoad) {
12510
+ if (reactData.scrollYLoad) {
12511
12511
  $xetable.updateScrollYSpace();
12512
12512
  }
12513
12513
 
@@ -12571,7 +12571,7 @@ var editHook = {
12571
12571
  getInsertRecords: function getInsertRecords() {
12572
12572
  var treeConfig = props.treeConfig;
12573
12573
  var editStore = reactData.editStore;
12574
- var treeFullData = internalData.treeFullData,
12574
+ var tableFullTreeData = internalData.tableFullTreeData,
12575
12575
  tableFullData = internalData.tableFullData;
12576
12576
  var treeOpts = computeTreeOpts.value;
12577
12577
  var insertList = editStore.insertList;
@@ -12582,7 +12582,7 @@ var editHook = {
12582
12582
  if (treeConfig && treeOpts.transform) {
12583
12583
  insertList.forEach(function (row) {
12584
12584
  var rowid = util_getRowid($xetable, row);
12585
- var matchObj = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.findTree(treeFullData, function (item) {
12585
+ var matchObj = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.findTree(tableFullTreeData, function (item) {
12586
12586
  return rowid === util_getRowid($xetable, item);
12587
12587
  }, treeOpts);
12588
12588
 
@@ -13016,6 +13016,7 @@ function _arrayWithHoles(arr) {
13016
13016
 
13017
13017
 
13018
13018
 
13019
+
13019
13020
  function _iterableToArrayLimit(arr, i) {
13020
13021
  var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
13021
13022
 
@@ -13561,6 +13562,8 @@ function useSize(props) {
13561
13562
 
13562
13563
 
13563
13564
 
13565
+
13566
+
13564
13567
 
13565
13568
  var allActivedModals = [];
13566
13569
  var msgQueue = [];
@@ -14777,6 +14780,7 @@ var es_string_pad_start = __webpack_require__("4d90");
14777
14780
 
14778
14781
 
14779
14782
 
14783
+
14780
14784
  var yearSize = 20;
14781
14785
  var monthSize = 20;
14782
14786
  var quarterSize = 8;
@@ -17235,6 +17239,7 @@ var es_string_includes = __webpack_require__("2532");
17235
17239
 
17236
17240
 
17237
17241
 
17242
+
17238
17243
  /* harmony default export */ var src_checkbox = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
17239
17244
  name: 'VxeCheckbox',
17240
17245
  props: {
@@ -17360,6 +17365,7 @@ var es_string_includes = __webpack_require__("2532");
17360
17365
 
17361
17366
 
17362
17367
 
17368
+
17363
17369
  function isOptionVisible(option) {
17364
17370
  return option.visible !== false;
17365
17371
  }
@@ -17548,7 +17554,7 @@ function getOptUniqueId() {
17548
17554
  });
17549
17555
 
17550
17556
  var getOptkey = function getOptkey() {
17551
- return props.optionId || '_XID';
17557
+ return props.optionId || '_X_ID';
17552
17558
  };
17553
17559
 
17554
17560
  var getOptid = function getOptid(option) {
@@ -18299,6 +18305,7 @@ function getOptUniqueId() {
18299
18305
 
18300
18306
 
18301
18307
 
18308
+
18302
18309
  /* harmony default export */ var export_panel = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
18303
18310
  name: 'VxeExportPanel',
18304
18311
  props: {
@@ -18669,6 +18676,7 @@ function getOptUniqueId() {
18669
18676
 
18670
18677
 
18671
18678
 
18679
+
18672
18680
  /* harmony default export */ var src_group = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
18673
18681
  name: 'VxeRadioGroup',
18674
18682
  props: {
@@ -18732,6 +18740,7 @@ function getOptUniqueId() {
18732
18740
 
18733
18741
 
18734
18742
 
18743
+
18735
18744
  /* harmony default export */ var src_radio = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
18736
18745
  name: 'VxeRadio',
18737
18746
  props: {
@@ -18848,6 +18857,7 @@ function getOptUniqueId() {
18848
18857
 
18849
18858
 
18850
18859
 
18860
+
18851
18861
  /* harmony default export */ var import_panel = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
18852
18862
  name: 'VxeImportPanel',
18853
18863
  props: {
@@ -19015,9 +19025,6 @@ var es_string_repeat = __webpack_require__("38cf");
19015
19025
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.trim.js
19016
19026
  var es_string_trim = __webpack_require__("498a");
19017
19027
 
19018
- // EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.iterator.js
19019
- var es_array_iterator = __webpack_require__("e260");
19020
-
19021
19028
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.map.js
19022
19029
  var es_map = __webpack_require__("4ec9");
19023
19030
 
@@ -19042,6 +19049,9 @@ var web_url_search_params = __webpack_require__("9861");
19042
19049
 
19043
19050
 
19044
19051
 
19052
+
19053
+
19054
+
19045
19055
  // 导入
19046
19056
 
19047
19057
  var fileForm;
@@ -21006,6 +21016,7 @@ var tableExportHook = {
21006
21016
 
21007
21017
 
21008
21018
 
21019
+
21009
21020
  var export_print = function print(options) {
21010
21021
  var opts = Object.assign({}, options, {
21011
21022
  type: 'html'
@@ -21044,6 +21055,7 @@ var Export = {
21044
21055
 
21045
21056
 
21046
21057
 
21058
+
21047
21059
  function getTargetOffset(target, container) {
21048
21060
  var offsetTop = 0;
21049
21061
  var offsetLeft = 0;
@@ -21550,6 +21562,9 @@ var Keyboard = {
21550
21562
 
21551
21563
 
21552
21564
 
21565
+
21566
+
21567
+
21553
21568
  /**
21554
21569
  * 校验规则
21555
21570
  */
@@ -22465,6 +22480,7 @@ var renderType = 'header';
22465
22480
 
22466
22481
 
22467
22482
 
22483
+
22468
22484
  var Header = Object.assign(header, {
22469
22485
  install: function install(app) {
22470
22486
  dynamicApp.component(header.name, header);
@@ -22482,6 +22498,7 @@ var Header = Object.assign(header, {
22482
22498
 
22483
22499
 
22484
22500
 
22501
+
22485
22502
  var footer_renderType = 'footer';
22486
22503
 
22487
22504
  function mergeFooterMethod(mergeFooterList, _rowIndex, _columnIndex) {
@@ -22841,6 +22858,7 @@ function mergeFooterMethod(mergeFooterList, _rowIndex, _columnIndex) {
22841
22858
 
22842
22859
 
22843
22860
 
22861
+
22844
22862
  var Footer = Object.assign(footer, {
22845
22863
  install: function install(app) {
22846
22864
  dynamicApp.component(footer.name, footer);
@@ -23959,6 +23977,7 @@ var columnProps = {
23959
23977
 
23960
23978
 
23961
23979
 
23980
+
23962
23981
  var Column = Object.assign(src_column, {
23963
23982
  install: function install(app) {
23964
23983
  dynamicApp.component(src_column.name, src_column);
@@ -24017,6 +24036,7 @@ var Column = Object.assign(src_column, {
24017
24036
 
24018
24037
 
24019
24038
 
24039
+
24020
24040
  var Colgroup = Object.assign(table_src_group, {
24021
24041
  install: function install(app) {
24022
24042
  dynamicApp.component(table_src_group.name, table_src_group);
@@ -25723,6 +25743,7 @@ var gridComponentEmits = [].concat(_toConsumableArray(emits), ['page-change', 'f
25723
25743
 
25724
25744
 
25725
25745
 
25746
+
25726
25747
  var Grid = Object.assign(grid, {
25727
25748
  install: function install(app) {
25728
25749
  dynamicApp.component(grid.name, grid);
@@ -25745,6 +25766,8 @@ var Grid = Object.assign(grid, {
25745
25766
 
25746
25767
 
25747
25768
 
25769
+
25770
+
25748
25771
  /* harmony default export */ var toolbar = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
25749
25772
  name: 'VxeToolbar',
25750
25773
  props: {
@@ -26495,6 +26518,7 @@ var Grid = Object.assign(grid, {
26495
26518
 
26496
26519
 
26497
26520
 
26521
+
26498
26522
  var Toolbar = Object.assign(toolbar, {
26499
26523
  install: function install(app) {
26500
26524
  dynamicApp.component(toolbar.name, toolbar);
@@ -26513,6 +26537,7 @@ var Toolbar = Object.assign(toolbar, {
26513
26537
 
26514
26538
 
26515
26539
 
26540
+
26516
26541
  /* harmony default export */ var pager = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
26517
26542
  name: 'VxePager',
26518
26543
  props: {
@@ -27075,6 +27100,7 @@ var Toolbar = Object.assign(toolbar, {
27075
27100
 
27076
27101
 
27077
27102
 
27103
+
27078
27104
  var Pager = Object.assign(pager, {
27079
27105
  install: function install(app) {
27080
27106
  dynamicApp.component(pager.name, pager);
@@ -27086,6 +27112,7 @@ var Pager = Object.assign(pager, {
27086
27112
 
27087
27113
 
27088
27114
 
27115
+
27089
27116
  var Checkbox = Object.assign(src_checkbox, {
27090
27117
  install: function install(app) {
27091
27118
  dynamicApp.component(src_checkbox.name, src_checkbox);
@@ -27099,6 +27126,7 @@ var Checkbox = Object.assign(src_checkbox, {
27099
27126
 
27100
27127
 
27101
27128
 
27129
+
27102
27130
  /* harmony default export */ var checkbox_src_group = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
27103
27131
  name: 'VxeCheckboxGroup',
27104
27132
  props: {
@@ -27168,6 +27196,7 @@ var Checkbox = Object.assign(src_checkbox, {
27168
27196
 
27169
27197
 
27170
27198
 
27199
+
27171
27200
  var CheckboxGroup = Object.assign(checkbox_src_group, {
27172
27201
  install: function install(app) {
27173
27202
  dynamicApp.component(checkbox_src_group.name, checkbox_src_group);
@@ -27179,6 +27208,7 @@ var CheckboxGroup = Object.assign(checkbox_src_group, {
27179
27208
 
27180
27209
 
27181
27210
 
27211
+
27182
27212
  var Radio = Object.assign(src_radio, {
27183
27213
  install: function install(app) {
27184
27214
  dynamicApp.component(src_radio.name, src_radio);
@@ -27190,6 +27220,7 @@ var Radio = Object.assign(src_radio, {
27190
27220
 
27191
27221
 
27192
27222
 
27223
+
27193
27224
  var RadioGroup = Object.assign(src_group, {
27194
27225
  install: function install(app) {
27195
27226
  dynamicApp.component(src_group.name, src_group);
@@ -27206,6 +27237,7 @@ var RadioGroup = Object.assign(src_group, {
27206
27237
 
27207
27238
 
27208
27239
 
27240
+
27209
27241
  /* harmony default export */ var radio_src_button = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
27210
27242
  name: 'VxeRadioButton',
27211
27243
  props: {
@@ -27309,6 +27341,7 @@ var RadioGroup = Object.assign(src_group, {
27309
27341
 
27310
27342
 
27311
27343
 
27344
+
27312
27345
  var RadioButton = Object.assign(radio_src_button, {
27313
27346
  install: function install(app) {
27314
27347
  dynamicApp.component(radio_src_button.name, radio_src_button);
@@ -27320,6 +27353,7 @@ var RadioButton = Object.assign(radio_src_button, {
27320
27353
 
27321
27354
 
27322
27355
 
27356
+
27323
27357
  var Input = Object.assign(input, {
27324
27358
  install: function install(app) {
27325
27359
  dynamicApp.component(input.name, input);
@@ -27340,6 +27374,7 @@ var Input = Object.assign(input, {
27340
27374
 
27341
27375
 
27342
27376
 
27377
+
27343
27378
  var autoTxtElem;
27344
27379
  /* harmony default export */ var src_textarea = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
27345
27380
  name: 'VxeTextarea',
@@ -27623,6 +27658,7 @@ var autoTxtElem;
27623
27658
 
27624
27659
 
27625
27660
 
27661
+
27626
27662
  var Textarea = Object.assign(src_textarea, {
27627
27663
  install: function install(app) {
27628
27664
  dynamicApp.component(src_textarea.name, src_textarea);
@@ -27634,6 +27670,7 @@ var Textarea = Object.assign(src_textarea, {
27634
27670
 
27635
27671
 
27636
27672
 
27673
+
27637
27674
  var Button = Object.assign(src_button, {
27638
27675
  install: function install(app) {
27639
27676
  dynamicApp.component(src_button.name, src_button);
@@ -27655,6 +27692,9 @@ var Button = Object.assign(src_button, {
27655
27692
 
27656
27693
 
27657
27694
 
27695
+
27696
+
27697
+
27658
27698
  function modal_openModal(options) {
27659
27699
  // 使用动态组件渲染动态弹框
27660
27700
  checkDynamic();
@@ -27776,6 +27816,7 @@ var Modal = Object.assign(modal, {
27776
27816
 
27777
27817
 
27778
27818
 
27819
+
27779
27820
  /* harmony default export */ var tooltip = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
27780
27821
  name: 'VxeTooltip',
27781
27822
  props: {
@@ -28143,6 +28184,7 @@ var Modal = Object.assign(modal, {
28143
28184
 
28144
28185
 
28145
28186
 
28187
+
28146
28188
  var Tooltip = Object.assign(tooltip, {
28147
28189
  install: function install(app) {
28148
28190
  VXETable.tooltip = true;
@@ -28155,6 +28197,7 @@ var Tooltip = Object.assign(tooltip, {
28155
28197
 
28156
28198
 
28157
28199
 
28200
+
28158
28201
  var itemInfo_ItemInfo = /*#__PURE__*/function () {
28159
28202
  function ItemInfo($xeform, item) {
28160
28203
  _classCallCheck(this, ItemInfo);
@@ -28345,6 +28388,9 @@ function renderTitle($xeform, item) {
28345
28388
 
28346
28389
 
28347
28390
 
28391
+
28392
+
28393
+
28348
28394
 
28349
28395
 
28350
28396
 
@@ -29242,6 +29288,7 @@ function getResetValue(value, resetValue) {
29242
29288
 
29243
29289
 
29244
29290
 
29291
+
29245
29292
  var Form = Object.assign(src_form, {
29246
29293
  install: function install(app) {
29247
29294
  dynamicApp.component(src_form.name, src_form);
@@ -29437,6 +29484,7 @@ var formItemProps = {
29437
29484
 
29438
29485
 
29439
29486
 
29487
+
29440
29488
  var FormItem = Object.assign(form_item, {
29441
29489
  install: function install(app) {
29442
29490
  dynamicApp.component(form_item.name, form_item);
@@ -29493,6 +29541,7 @@ var FormItem = Object.assign(form_item, {
29493
29541
 
29494
29542
 
29495
29543
 
29544
+
29496
29545
  var FormGather = Object.assign(form_gather, {
29497
29546
  install: function install(app) {
29498
29547
  dynamicApp.component(form_gather.name, form_gather);
@@ -29504,6 +29553,7 @@ var FormGather = Object.assign(form_gather, {
29504
29553
 
29505
29554
 
29506
29555
 
29556
+
29507
29557
  var Select = Object.assign(src_select, {
29508
29558
  install: function install(app) {
29509
29559
  dynamicApp.component(src_select.name, src_select);
@@ -29515,6 +29565,7 @@ var Select = Object.assign(src_select, {
29515
29565
 
29516
29566
 
29517
29567
 
29568
+
29518
29569
  var optionInfo_OptionInfo = /*#__PURE__*/function () {
29519
29570
  function OptionInfo($xeselect, _vm) {
29520
29571
  _classCallCheck(this, OptionInfo);
@@ -29634,6 +29685,7 @@ function destroyOption($xeselect, option) {
29634
29685
 
29635
29686
 
29636
29687
 
29688
+
29637
29689
  var Optgroup = Object.assign(src_optgroup, {
29638
29690
  install: function install(app) {
29639
29691
  dynamicApp.component(src_optgroup.name, src_optgroup);
@@ -29685,6 +29737,7 @@ var Optgroup = Object.assign(src_optgroup, {
29685
29737
 
29686
29738
 
29687
29739
 
29740
+
29688
29741
  var Option = Object.assign(src_option, {
29689
29742
  install: function install(app) {
29690
29743
  dynamicApp.component(src_option.name, src_option);
@@ -29700,6 +29753,7 @@ var Option = Object.assign(src_option, {
29700
29753
 
29701
29754
 
29702
29755
 
29756
+
29703
29757
  /* harmony default export */ var src_switch = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
29704
29758
  name: 'VxeSwitch',
29705
29759
  props: {
@@ -29850,6 +29904,7 @@ var Option = Object.assign(src_option, {
29850
29904
 
29851
29905
 
29852
29906
 
29907
+
29853
29908
  var Switch = Object.assign(src_switch, {
29854
29909
  install: function install(app) {
29855
29910
  dynamicApp.component(src_switch.name, src_switch);
@@ -29986,6 +30041,8 @@ function createResizeEvent(callback) {
29986
30041
 
29987
30042
 
29988
30043
 
30044
+
30045
+
29989
30046
  /* harmony default export */ var src_list = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
29990
30047
  name: 'VxeList',
29991
30048
  props: {
@@ -30385,6 +30442,7 @@ function createResizeEvent(callback) {
30385
30442
 
30386
30443
 
30387
30444
 
30445
+
30388
30446
  var List = Object.assign(src_list, {
30389
30447
  install: function install(app) {
30390
30448
  dynamicApp.component(src_list.name, src_list);
@@ -30402,6 +30460,8 @@ var List = Object.assign(src_list, {
30402
30460
 
30403
30461
 
30404
30462
 
30463
+
30464
+
30405
30465
  /* harmony default export */ var pulldown = (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["defineComponent"])({
30406
30466
  name: 'VxePulldown',
30407
30467
  props: {
@@ -30723,6 +30783,7 @@ var List = Object.assign(src_list, {
30723
30783
 
30724
30784
 
30725
30785
 
30786
+
30726
30787
  var Pulldown = Object.assign(pulldown, {
30727
30788
  install: function install(app) {
30728
30789
  dynamicApp.component(pulldown.name, pulldown);
@@ -31139,6 +31200,7 @@ var lineOffsetSizes = {
31139
31200
  var treeOpts = computeTreeOpts.value;
31140
31201
  var editOpts = computeEditOpts.value;
31141
31202
  var rowOpts = computeRowOpts.value;
31203
+ var transform = treeOpts.transform;
31142
31204
  var rows = [];
31143
31205
  tableData.forEach(function (row, $rowIndex) {
31144
31206
  var trOn = {};
@@ -31172,8 +31234,14 @@ var lineOffsetSizes = {
31172
31234
 
31173
31235
  var rowid = util_getRowid($xetable, row);
31174
31236
  var rest = fullDataRowIdData[rowid];
31175
- var rowLevel = rest ? rest.level : 0;
31176
- var seq = rest ? rest.seq : -1;
31237
+ var rowLevel = 0;
31238
+ var seq = -1;
31239
+
31240
+ if (rest) {
31241
+ rowLevel = rest.level;
31242
+ seq = rest.seq;
31243
+ }
31244
+
31177
31245
  var params = {
31178
31246
  $table: $xetable,
31179
31247
  seq: seq,
@@ -31185,7 +31253,8 @@ var lineOffsetSizes = {
31185
31253
  rowIndex: rowIndex,
31186
31254
  $rowIndex: $rowIndex,
31187
31255
  _rowIndex: _rowIndex
31188
- };
31256
+ }; // 处理新增状态
31257
+
31189
31258
  var isNewRow = false;
31190
31259
 
31191
31260
  if (editConfig) {
@@ -31247,7 +31316,7 @@ var lineOffsetSizes = {
31247
31316
  } // 如果是树形表格
31248
31317
 
31249
31318
 
31250
- if (treeConfig && !scrollYLoad && treeExpandeds.length) {
31319
+ if (treeConfig && !scrollYLoad && !transform && treeExpandeds.length) {
31251
31320
  var rowChildren = row[treeOpts.children];
31252
31321
 
31253
31322
  if (rowChildren && rowChildren.length && $xetable.findRowIndexOf(treeExpandeds, row) > -1) {
@@ -31924,10 +31993,12 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
31924
31993
  rowExpandedReserveRowMap: {},
31925
31994
  // 树结构数据,已展开保留的行
31926
31995
  treeExpandedReserveRowMap: {},
31927
- // 完整数据、条件处理后
31996
+ // 列表完整数据、条件处理后
31928
31997
  tableFullData: [],
31929
- treeFullData: [],
31930
31998
  afterFullData: [],
31999
+ // 树结构完整数据、条件处理后
32000
+ tableFullTreeData: [],
32001
+ afterTreeFullData: [],
31931
32002
  tableSynchData: [],
31932
32003
  tableSourceData: [],
31933
32004
  // 收集的列配置(带分组)
@@ -32930,11 +33001,11 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
32930
33001
  var afterFullData = internalData.afterFullData,
32931
33002
  fullDataRowIdData = internalData.fullDataRowIdData,
32932
33003
  fullAllDataRowIdData = internalData.fullAllDataRowIdData;
32933
- var treeFullData = internalData.treeFullData;
33004
+ var afterTreeFullData = internalData.afterTreeFullData;
32934
33005
  var treeOpts = computeTreeOpts.value;
32935
33006
 
32936
33007
  if (treeConfig) {
32937
- external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.eachTree(treeFullData, function (row, index, items, path) {
33008
+ external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.eachTree(afterTreeFullData, function (row, index, items, path) {
32938
33009
  var rowid = util_getRowid($xetable, row);
32939
33010
 
32940
33011
  var allrest = fullAllDataRowIdData[rowid];
@@ -32945,10 +33016,12 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
32945
33016
 
32946
33017
  if (allrest) {
32947
33018
  allrest.seq = seq;
33019
+ allrest._index = index;
32948
33020
  }
32949
33021
 
32950
33022
  if (fullrest) {
32951
33023
  fullrest.seq = seq;
33024
+ fullrest._index = index;
32952
33025
  } else {
32953
33026
  fullAllDataRowIdData[rowid] = {
32954
33027
  row: row,
@@ -32973,7 +33046,9 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
32973
33046
  level: 0
32974
33047
  };
32975
33048
  }
32976
- }, treeOpts);
33049
+ }, {
33050
+ children: treeOpts.mapChildren
33051
+ });
32977
33052
  } else {
32978
33053
  afterFullData.forEach(function (row, index) {
32979
33054
  var rowid = util_getRowid($xetable, row);
@@ -32984,6 +33059,7 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
32984
33059
 
32985
33060
  if (allrest) {
32986
33061
  allrest.seq = seq;
33062
+ allrest._index = index;
32987
33063
  }
32988
33064
 
32989
33065
  if (fullrest) {
@@ -33023,15 +33099,20 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
33023
33099
 
33024
33100
 
33025
33101
  var updateAfterFullData = function updateAfterFullData() {
33102
+ var treeConfig = props.treeConfig;
33026
33103
  var tableFullColumn = internalData.tableFullColumn,
33027
- tableFullData = internalData.tableFullData;
33104
+ tableFullData = internalData.tableFullData,
33105
+ tableFullTreeData = internalData.tableFullTreeData;
33028
33106
  var filterOpts = computeFilterOpts.value;
33029
33107
  var sortOpts = computeSortOpts.value;
33108
+ var treeOpts = computeTreeOpts.value;
33109
+ var transform = treeOpts.transform;
33030
33110
  var allRemoteFilter = filterOpts.remote,
33031
33111
  allFilterMethod = filterOpts.filterMethod;
33032
33112
  var allRemoteSort = sortOpts.remote,
33033
33113
  allSortMethod = sortOpts.sortMethod;
33034
- var tableData = tableFullData.slice(0);
33114
+ var tableData = [];
33115
+ var tableTree = []; // 处理列
33035
33116
 
33036
33117
  if (!allRemoteFilter || !allRemoteSort) {
33037
33118
  var filterColumns = [];
@@ -33071,7 +33152,7 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
33071
33152
  // 支持单列、多列、组合筛选
33072
33153
 
33073
33154
  if (!allRemoteFilter && filterColumns.length) {
33074
- tableData = tableData.filter(function (row) {
33155
+ var handleFilter = function handleFilter(row) {
33075
33156
  return filterColumns.every(function (_ref2) {
33076
33157
  var column = _ref2.column,
33077
33158
  valueList = _ref2.valueList,
@@ -33128,32 +33209,79 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
33128
33209
 
33129
33210
  return valueList.indexOf(external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.get(row, column.property)) > -1;
33130
33211
  });
33131
- });
33132
- } // 处理排序
33212
+ };
33213
+
33214
+ if (treeConfig && transform) {
33215
+ // 筛选虚拟树
33216
+ tableTree = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.searchTree(tableFullTreeData, handleFilter, _objectSpread2(_objectSpread2({}, treeOpts), {}, {
33217
+ original: true
33218
+ }));
33219
+ tableData = tableTree;
33220
+ } else {
33221
+ tableData = treeConfig ? tableFullTreeData.filter(handleFilter) : tableFullData.filter(handleFilter);
33222
+ tableTree = tableData;
33223
+ }
33224
+ } else {
33225
+ if (treeConfig && transform) {
33226
+ // 还原虚拟树
33227
+ tableTree = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.searchTree(tableFullTreeData, function () {
33228
+ return true;
33229
+ }, _objectSpread2(_objectSpread2({}, treeOpts), {}, {
33230
+ original: true
33231
+ }));
33232
+ tableData = tableTree;
33233
+ } else {
33234
+ tableData = treeConfig ? tableFullTreeData.slice(0) : tableFullData.slice(0);
33235
+ tableTree = tableData;
33236
+ }
33237
+ } // 处理排序(不能用于树形结构)
33133
33238
  // 支持单列、多列、组合排序
33134
33239
 
33135
33240
 
33136
33241
  if (!allRemoteSort && orderColumns.length) {
33137
- if (allSortMethod) {
33138
- var sortRests = allSortMethod({
33139
- data: tableData,
33140
- sortList: orderColumns,
33141
- $table: $xetable
33142
- });
33143
- tableData = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.isArray(sortRests) ? sortRests : tableData;
33242
+ if (treeConfig && transform) {
33243
+ // 虚拟树和列表一样,只能排序根级节点
33244
+ if (allSortMethod) {
33245
+ var sortRests = allSortMethod({
33246
+ data: tableTree,
33247
+ sortList: orderColumns,
33248
+ $table: $xetable
33249
+ });
33250
+ tableTree = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.isArray(sortRests) ? sortRests : tableTree;
33251
+ } else {
33252
+ tableTree = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.orderBy(tableTree, orderColumns.map(function (_ref3) {
33253
+ var column = _ref3.column,
33254
+ order = _ref3.order;
33255
+ return [getOrderField(column), order];
33256
+ }));
33257
+ }
33258
+
33259
+ tableData = tableTree;
33144
33260
  } else {
33145
- tableData = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.orderBy(tableData, orderColumns.map(function (_ref3) {
33146
- var column = _ref3.column,
33147
- order = _ref3.order;
33148
- return [getOrderField(column), order];
33149
- }));
33261
+ if (allSortMethod) {
33262
+ var _sortRests = allSortMethod({
33263
+ data: tableData,
33264
+ sortList: orderColumns,
33265
+ $table: $xetable
33266
+ });
33267
+
33268
+ tableData = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.isArray(_sortRests) ? _sortRests : tableData;
33269
+ } else {
33270
+ tableData = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.orderBy(tableData, orderColumns.map(function (_ref4) {
33271
+ var column = _ref4.column,
33272
+ order = _ref4.order;
33273
+ return [getOrderField(column), order];
33274
+ }));
33275
+ }
33276
+
33277
+ tableTree = tableData;
33150
33278
  }
33151
33279
  }
33152
33280
  }
33153
33281
 
33154
33282
  internalData.afterFullData = tableData;
33283
+ internalData.afterTreeFullData = tableTree;
33155
33284
  updateAfterDataIndex();
33156
- return tableData;
33157
33285
  };
33158
33286
 
33159
33287
  var updateStyle = function updateStyle() {
@@ -33286,6 +33414,8 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
33286
33414
  }
33287
33415
 
33288
33416
  childWidth += item.renderWidth;
33417
+ }, {
33418
+ children: 'children'
33289
33419
  });
33290
33420
  }
33291
33421
 
@@ -33728,7 +33858,8 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
33728
33858
  var fullAllDataRowIdData = internalData.fullAllDataRowIdData;
33729
33859
  var treeOpts = computeTreeOpts.value;
33730
33860
  var checkboxOpts = computeCheckboxOpts.value;
33731
- var loadMethod = treeOpts.loadMethod;
33861
+ var transform = treeOpts.transform,
33862
+ loadMethod = treeOpts.loadMethod;
33732
33863
  var checkStrictly = checkboxOpts.checkStrictly;
33733
33864
 
33734
33865
  var rest = fullAllDataRowIdData[util_getRowid($xetable, row)];
@@ -33761,12 +33892,24 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
33761
33892
  if (!checkStrictly && tableMethods.isCheckedByCheckboxRow(row)) {
33762
33893
  tableMethods.setCheckboxRow(childRows, true);
33763
33894
  }
33895
+
33896
+ Object(external_commonjs_vue_commonjs2_vue_root_Vue_["nextTick"])().then(function () {
33897
+ if (transform) {
33898
+ return tablePrivateMethods.handleTableData();
33899
+ }
33900
+ }).then(function () {
33901
+ return tableMethods.recalculate();
33902
+ }).then(function () {
33903
+ return resolve();
33904
+ });
33905
+ });
33906
+ } else {
33907
+ Object(external_commonjs_vue_commonjs2_vue_root_Vue_["nextTick"])().then(function () {
33908
+ return tableMethods.recalculate();
33909
+ }).then(function () {
33910
+ return resolve();
33764
33911
  });
33765
33912
  }
33766
-
33767
- resolve(Object(external_commonjs_vue_commonjs2_vue_root_Vue_["nextTick"])().then(function () {
33768
- return tableMethods.recalculate();
33769
- }));
33770
33913
  });
33771
33914
  } else {
33772
33915
  resolve();
@@ -33936,6 +34079,14 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
33936
34079
  errLog('vxe.error.reqProp', ['tree-config.children']);
33937
34080
  }
33938
34081
 
34082
+ if (!treeOpts.mapChildren) {
34083
+ errLog('vxe.error.reqProp', ['tree-config.mapChildren']);
34084
+ }
34085
+
34086
+ if (treeOpts.children === treeOpts.mapChildren) {
34087
+ errLog('vxe.error.errConflicts', ['tree-config.children', 'tree-config.mapChildren']);
34088
+ }
34089
+
33939
34090
  fullData.forEach(function (row) {
33940
34091
  if (row[treeOpts.children] && row[treeOpts.children].length) {
33941
34092
  warnLog('vxe.error.errConflicts', ['tree-config.transform', "row.".concat(treeOpts.children)]);
@@ -33946,7 +34097,8 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
33946
34097
  treeData = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.toArrayTree(fullData, {
33947
34098
  key: treeOpts.rowField,
33948
34099
  parentKey: treeOpts.parentField,
33949
- children: treeOpts.children
34100
+ children: treeOpts.children,
34101
+ mapChildren: treeOpts.mapChildren
33950
34102
  });
33951
34103
  fullData = treeData.slice(0);
33952
34104
  } else {
@@ -33964,7 +34116,7 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
33964
34116
  reactData.scrollYLoad = sYLoad; // 全量数据
33965
34117
 
33966
34118
  internalData.tableFullData = fullData;
33967
- internalData.treeFullData = treeData; // 缓存数据
34119
+ internalData.tableFullTreeData = treeData; // 缓存数据
33968
34120
 
33969
34121
  tablePrivateMethods.cacheRowMap(true); // 原始数据
33970
34122
 
@@ -34296,31 +34448,6 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
34296
34448
  reactData.scrollYLoad = scrollYLoad;
34297
34449
  return scrollYLoad;
34298
34450
  };
34299
-
34300
- var updateVirtualTreeData = function updateVirtualTreeData() {
34301
- var oldScrollYLoad = reactData.scrollYLoad,
34302
- treeExpandeds = reactData.treeExpandeds;
34303
- var treeFullData = internalData.treeFullData;
34304
- var treeOpts = computeTreeOpts.value;
34305
- var fullData = [];
34306
- var expandMaps = new Map();
34307
- external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.eachTree(treeFullData, function (row, index, items, path, parent) {
34308
- if (!parent || expandMaps.has(parent) && $xetable.findRowIndexOf(treeExpandeds, parent) > -1) {
34309
- expandMaps.set(row, 1);
34310
- fullData.push(row);
34311
- }
34312
- }, treeOpts);
34313
- var scrollYLoad = updateScrollYStatus(fullData);
34314
- internalData.tableFullData = scrollYLoad ? fullData : treeFullData;
34315
-
34316
- if (scrollYLoad || oldScrollYLoad !== scrollYLoad) {
34317
- return tablePrivateMethods.handleTableData(true).then(function () {
34318
- return tableMethods.recalculate();
34319
- });
34320
- }
34321
-
34322
- return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["nextTick"])();
34323
- };
34324
34451
  /**
34325
34452
  * 展开与收起树节点
34326
34453
  * @param rows
@@ -34412,7 +34539,7 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
34412
34539
 
34413
34540
  var handleVirtualTreeExpand = function handleVirtualTreeExpand(rows, expanded) {
34414
34541
  return handleBaseTreeExpand(rows, expanded).then(function () {
34415
- return updateVirtualTreeData();
34542
+ return tablePrivateMethods.handleTableData();
34416
34543
  }).then(function () {
34417
34544
  return tableMethods.recalculate();
34418
34545
  });
@@ -34507,7 +34634,7 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
34507
34634
  },
34508
34635
 
34509
34636
  /**
34510
- * 同步 data 数据
34637
+ * 同步 data 数据(即将废弃)
34511
34638
  * 如果用了该方法,那么组件将不再记录增删改的状态,只能自行实现对应逻辑
34512
34639
  * 对于某些特殊的场景,比如深层树节点元素发生变动时可能会用到
34513
34640
  */
@@ -34619,7 +34746,9 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
34619
34746
  fullDataRowIdData = internalData.fullDataRowIdData,
34620
34747
  fullAllDataRowIdData = internalData.fullAllDataRowIdData;
34621
34748
  var treeOpts = computeTreeOpts.value;
34622
- var children = treeOpts.children;
34749
+ var transform = treeOpts.transform,
34750
+ children = treeOpts.children,
34751
+ mapChildren = treeOpts.mapChildren;
34623
34752
 
34624
34753
  var parentRest = fullAllDataRowIdData[util_getRowid($xetable, row)];
34625
34754
 
@@ -34655,6 +34784,11 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
34655
34784
  fullAllDataRowIdData[rowid] = rest;
34656
34785
  }, treeOpts);
34657
34786
  row[children] = rows;
34787
+
34788
+ if (transform) {
34789
+ row[mapChildren] = rows;
34790
+ }
34791
+
34658
34792
  return rows;
34659
34793
  });
34660
34794
  },
@@ -36134,7 +36268,7 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
36134
36268
  return handleAsyncTreeExpandChilds(row);
36135
36269
  }).then(function () {
36136
36270
  if (transform) {
36137
- return updateVirtualTreeData();
36271
+ return tablePrivateMethods.handleTableData();
36138
36272
  }
36139
36273
  }).then(function () {
36140
36274
  return tableMethods.recalculate();
@@ -36222,19 +36356,19 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
36222
36356
  */
36223
36357
  clearTreeExpand: function clearTreeExpand() {
36224
36358
  var treeExpandeds = reactData.treeExpandeds;
36225
- var treeFullData = internalData.treeFullData;
36359
+ var tableFullTreeData = internalData.tableFullTreeData;
36226
36360
  var treeOpts = computeTreeOpts.value;
36227
36361
  var reserve = treeOpts.reserve;
36228
36362
  var isExists = treeExpandeds.length;
36229
36363
  reactData.treeExpandeds = [];
36230
36364
 
36231
36365
  if (reserve) {
36232
- external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.eachTree(treeFullData, function (row) {
36366
+ external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.eachTree(tableFullTreeData, function (row) {
36233
36367
  return handleTreeExpandReserve(row, false);
36234
36368
  }, treeOpts);
36235
36369
  }
36236
36370
 
36237
- return updateVirtualTreeData().then(function () {
36371
+ return tablePrivateMethods.handleTableData().then(function () {
36238
36372
  if (isExists) {
36239
36373
  tableMethods.recalculate();
36240
36374
  }
@@ -36412,8 +36546,8 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
36412
36546
  }
36413
36547
 
36414
36548
  $xetable.clearValidate();
36415
- }).catch(function (_ref4) {
36416
- var rule = _ref4.rule;
36549
+ }).catch(function (_ref5) {
36550
+ var rule = _ref5.rule;
36417
36551
 
36418
36552
  if (customVal) {
36419
36553
  setCellValue(row, column, cellValue);
@@ -37206,11 +37340,34 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
37206
37340
  return record;
37207
37341
  },
37208
37342
  handleTableData: function handleTableData(force) {
37343
+ var treeConfig = props.treeConfig;
37209
37344
  var scrollYLoad = reactData.scrollYLoad;
37210
37345
  var scrollYStore = internalData.scrollYStore,
37211
37346
  fullDataRowIdData = internalData.fullDataRowIdData;
37212
- var fullData = force ? updateAfterFullData() : internalData.afterFullData;
37213
- var tableData = scrollYLoad ? fullData.slice(scrollYStore.startIndex, scrollYStore.endIndex) : fullData.slice(0);
37347
+ var treeExpandeds = reactData.treeExpandeds;
37348
+ var treeOpts = computeTreeOpts.value;
37349
+ var fullList = []; // 是否进行数据处理
37350
+
37351
+ if (force) {
37352
+ updateAfterFullData();
37353
+ } // 如果为虚拟树,将树结构拍平
37354
+
37355
+
37356
+ if (treeConfig && treeOpts.transform) {
37357
+ var expandMaps = new Map();
37358
+ external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.eachTree(internalData.afterTreeFullData, function (row, index, items, path, parent) {
37359
+ if (!parent || expandMaps.has(parent) && $xetable.findRowIndexOf(treeExpandeds, parent) > -1) {
37360
+ expandMaps.set(row, 1);
37361
+ fullList.push(row);
37362
+ }
37363
+ }, {
37364
+ children: treeOpts.mapChildren
37365
+ });
37366
+ } else {
37367
+ fullList = internalData.afterFullData;
37368
+ }
37369
+
37370
+ var tableData = scrollYLoad ? fullList.slice(scrollYStore.startIndex, scrollYStore.endIndex) : fullList.slice(0);
37214
37371
  tableData.forEach(function (row, $index) {
37215
37372
  var rowid = util_getRowid($xetable, row);
37216
37373
 
@@ -37234,7 +37391,7 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
37234
37391
  var fullDataRowIdData = internalData.fullDataRowIdData,
37235
37392
  fullAllDataRowIdData = internalData.fullAllDataRowIdData,
37236
37393
  tableFullData = internalData.tableFullData,
37237
- treeFullData = internalData.treeFullData;
37394
+ tableFullTreeData = internalData.tableFullTreeData;
37238
37395
  var rowkey = getRowkey($xetable);
37239
37396
  var isLazy = treeConfig && treeOpts.lazy;
37240
37397
 
@@ -37279,7 +37436,7 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
37279
37436
  fullAllDataRowIdData = internalData.fullAllDataRowIdData = {};
37280
37437
 
37281
37438
  if (treeConfig) {
37282
- external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.eachTree(treeFullData, handleCache, treeOpts);
37439
+ external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default.a.eachTree(tableFullTreeData, handleCache, treeOpts);
37283
37440
  } else {
37284
37441
  tableFullData.forEach(handleCache);
37285
37442
  }
@@ -37510,8 +37667,8 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
37510
37667
  * 多选,行选中事件
37511
37668
  * value 选中true 不选false 半选-1
37512
37669
  */
37513
- handleSelectRow: function handleSelectRow(_ref5, value) {
37514
- var row = _ref5.row;
37670
+ handleSelectRow: function handleSelectRow(_ref6, value) {
37671
+ var row = _ref6.row;
37515
37672
  var treeConfig = props.treeConfig;
37516
37673
  var selection = reactData.selection,
37517
37674
  treeIndeterminates = reactData.treeIndeterminates;
@@ -38248,7 +38405,6 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
38248
38405
  tablePrivateMethods.handleTableData();
38249
38406
  tablePrivateMethods.updateScrollYSpace();
38250
38407
  },
38251
- updateVirtualTreeData: updateVirtualTreeData,
38252
38408
 
38253
38409
  /**
38254
38410
  * 处理固定列的显示状态
@@ -38296,8 +38452,8 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
38296
38452
  /**
38297
38453
  * 行 hover 事件
38298
38454
  */
38299
- triggerHoverEvent: function triggerHoverEvent(evnt, _ref6) {
38300
- var row = _ref6.row;
38455
+ triggerHoverEvent: function triggerHoverEvent(evnt, _ref7) {
38456
+ var row = _ref7.row;
38301
38457
  tablePrivateMethods.setHoverRow(row);
38302
38458
  },
38303
38459
  setHoverRow: function setHoverRow(row) {
@@ -38428,7 +38584,7 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
38428
38584
 
38429
38585
  return false;
38430
38586
  }
38431
- };
38587
+ }; // 检测对应模块是否安装
38432
38588
 
38433
38589
  if (true) {
38434
38590
  'openExport,openPrint,exportData,openImport,importData,saveFile,readFile,importByFile,print'.split(',').forEach(function (name) {
@@ -38853,7 +39009,7 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
38853
39009
  });
38854
39010
 
38855
39011
  var renderVN = function renderVN() {
38856
- var _ref7;
39012
+ var _ref8;
38857
39013
 
38858
39014
  var loading = props.loading,
38859
39015
  stripe = props.stripe,
@@ -38893,7 +39049,7 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
38893
39049
  var isMenu = computeIsMenu.value;
38894
39050
  return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["h"])('div', {
38895
39051
  ref: refElem,
38896
- class: ['vxe-table', 'vxe-table--render-default', "tid_".concat(xID), "border--".concat(tableBorder), (_ref7 = {}, _defineProperty(_ref7, "size--".concat(vSize), vSize), _defineProperty(_ref7, 'vxe-editable', !!editConfig), _defineProperty(_ref7, 'cell--highlight', highlightCell), _defineProperty(_ref7, 'cell--selected', mouseConfig && mouseOpts.selected), _defineProperty(_ref7, 'cell--area', mouseConfig && mouseOpts.area), _defineProperty(_ref7, 'row--highlight', rowOpts.isHover || highlightHoverRow), _defineProperty(_ref7, 'column--highlight', columnOpts.isHover || highlightHoverColumn), _defineProperty(_ref7, 'is--header', showHeader), _defineProperty(_ref7, 'is--footer', showFooter), _defineProperty(_ref7, 'is--group', isGroup), _defineProperty(_ref7, 'is--tree-line', treeConfig && treeOpts.line), _defineProperty(_ref7, 'is--fixed-left', leftList.length), _defineProperty(_ref7, 'is--fixed-right', rightList.length), _defineProperty(_ref7, 'is--animat', !!props.animat), _defineProperty(_ref7, 'is--round', props.round), _defineProperty(_ref7, 'is--stripe', !treeConfig && stripe), _defineProperty(_ref7, 'is--loading', loading), _defineProperty(_ref7, 'is--empty', !loading && !tableData.length), _defineProperty(_ref7, 'is--scroll-y', overflowY), _defineProperty(_ref7, 'is--scroll-x', overflowX), _defineProperty(_ref7, 'is--virtual-x', scrollXLoad), _defineProperty(_ref7, 'is--virtual-y', scrollYLoad), _ref7)],
39052
+ class: ['vxe-table', 'vxe-table--render-default', "tid_".concat(xID), "border--".concat(tableBorder), (_ref8 = {}, _defineProperty(_ref8, "size--".concat(vSize), vSize), _defineProperty(_ref8, 'vxe-editable', !!editConfig), _defineProperty(_ref8, 'cell--highlight', highlightCell), _defineProperty(_ref8, 'cell--selected', mouseConfig && mouseOpts.selected), _defineProperty(_ref8, 'cell--area', mouseConfig && mouseOpts.area), _defineProperty(_ref8, 'row--highlight', rowOpts.isHover || highlightHoverRow), _defineProperty(_ref8, 'column--highlight', columnOpts.isHover || highlightHoverColumn), _defineProperty(_ref8, 'is--header', showHeader), _defineProperty(_ref8, 'is--footer', showFooter), _defineProperty(_ref8, 'is--group', isGroup), _defineProperty(_ref8, 'is--tree-line', treeConfig && treeOpts.line), _defineProperty(_ref8, 'is--fixed-left', leftList.length), _defineProperty(_ref8, 'is--fixed-right', rightList.length), _defineProperty(_ref8, 'is--animat', !!props.animat), _defineProperty(_ref8, 'is--round', props.round), _defineProperty(_ref8, 'is--stripe', !treeConfig && stripe), _defineProperty(_ref8, 'is--loading', loading), _defineProperty(_ref8, 'is--empty', !loading && !tableData.length), _defineProperty(_ref8, 'is--scroll-y', overflowY), _defineProperty(_ref8, 'is--scroll-x', overflowX), _defineProperty(_ref8, 'is--virtual-x', scrollXLoad), _defineProperty(_ref8, 'is--virtual-y', scrollYLoad), _ref8)],
38897
39053
  onKeydown: keydownEvent
38898
39054
  }, [
38899
39055
  /**
@@ -39039,6 +39195,7 @@ var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE';
39039
39195
 
39040
39196
 
39041
39197
 
39198
+
39042
39199
  var Table = Object.assign(table, {
39043
39200
  install: function install(app) {
39044
39201
  dynamicApp.component(table.name, table);