vxe-table 4.12.0-beta.1 → 4.12.0-beta.3

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.
Files changed (57) hide show
  1. package/es/grid/src/grid.js +16 -32
  2. package/es/style.css +1 -1
  3. package/es/table/module/custom/panel.js +19 -21
  4. package/es/table/module/export/export-panel.js +17 -19
  5. package/es/table/module/export/hook.js +5 -11
  6. package/es/table/module/export/import-panel.js +11 -13
  7. package/es/table/module/validator/hook.js +1 -3
  8. package/es/table/render/index.js +81 -61
  9. package/es/table/src/columnInfo.js +26 -28
  10. package/es/table/src/table.js +115 -98
  11. package/es/toolbar/src/toolbar.js +16 -24
  12. package/es/ui/index.js +1 -1
  13. package/es/ui/src/log.js +1 -1
  14. package/lib/grid/src/grid.js +16 -32
  15. package/lib/grid/src/grid.min.js +1 -1
  16. package/lib/index.umd.js +332 -321
  17. package/lib/index.umd.min.js +1 -1
  18. package/lib/style.css +1 -1
  19. package/lib/table/module/custom/panel.js +21 -23
  20. package/lib/table/module/custom/panel.min.js +1 -1
  21. package/lib/table/module/export/export-panel.js +17 -19
  22. package/lib/table/module/export/export-panel.min.js +1 -1
  23. package/lib/table/module/export/hook.js +5 -11
  24. package/lib/table/module/export/hook.min.js +1 -1
  25. package/lib/table/module/export/import-panel.js +11 -13
  26. package/lib/table/module/export/import-panel.min.js +1 -1
  27. package/lib/table/module/validator/hook.js +1 -3
  28. package/lib/table/module/validator/hook.min.js +1 -1
  29. package/lib/table/render/index.js +87 -67
  30. package/lib/table/render/index.min.js +1 -1
  31. package/lib/table/src/columnInfo.js +30 -32
  32. package/lib/table/src/columnInfo.min.js +1 -1
  33. package/lib/table/src/table.js +122 -95
  34. package/lib/table/src/table.min.js +1 -1
  35. package/lib/toolbar/src/toolbar.js +16 -24
  36. package/lib/toolbar/src/toolbar.min.js +1 -1
  37. package/lib/ui/index.js +1 -1
  38. package/lib/ui/index.min.js +1 -1
  39. package/lib/ui/src/log.js +1 -1
  40. package/lib/ui/src/log.min.js +1 -1
  41. package/package.json +2 -2
  42. package/packages/grid/src/grid.ts +17 -32
  43. package/packages/table/module/custom/panel.ts +19 -21
  44. package/packages/table/module/export/export-panel.ts +17 -19
  45. package/packages/table/module/export/hook.ts +5 -11
  46. package/packages/table/module/export/import-panel.ts +11 -13
  47. package/packages/table/module/validator/hook.ts +1 -3
  48. package/packages/table/render/index.ts +80 -59
  49. package/packages/table/src/columnInfo.ts +26 -28
  50. package/packages/table/src/table.ts +113 -95
  51. package/packages/toolbar/src/toolbar.ts +16 -24
  52. /package/es/{iconfont.1741051902838.ttf → iconfont.1741160677181.ttf} +0 -0
  53. /package/es/{iconfont.1741051902838.woff → iconfont.1741160677181.woff} +0 -0
  54. /package/es/{iconfont.1741051902838.woff2 → iconfont.1741160677181.woff2} +0 -0
  55. /package/lib/{iconfont.1741051902838.ttf → iconfont.1741160677181.ttf} +0 -0
  56. /package/lib/{iconfont.1741051902838.woff → iconfont.1741160677181.woff} +0 -0
  57. /package/lib/{iconfont.1741051902838.woff2 → iconfont.1741160677181.woff2} +0 -0
package/lib/index.umd.js CHANGED
@@ -3138,7 +3138,7 @@ function eqEmptyValue(cellValue) {
3138
3138
  ;// ./packages/ui/index.ts
3139
3139
 
3140
3140
 
3141
- const version = "4.12.0-beta.1";
3141
+ const version = "4.12.0-beta.3";
3142
3142
  core_.VxeUI.version = version;
3143
3143
  core_.VxeUI.tableVersion = version;
3144
3144
  core_.VxeUI.setConfig({
@@ -3586,7 +3586,7 @@ var esnext_iterator_some = __webpack_require__(7550);
3586
3586
  const {
3587
3587
  log: log_log
3588
3588
  } = core_.VxeUI;
3589
- const log_version = `table v${"4.12.0-beta.1"}`;
3589
+ const log_version = `table v${"4.12.0-beta.3"}`;
3590
3590
  const warnLog = log_log.create('warn', log_version);
3591
3591
  const errLog = log_log.create('error', log_version);
3592
3592
  ;// ./packages/table/src/columnInfo.ts
@@ -3613,40 +3613,38 @@ class ColumnInfo {
3613
3613
  const {
3614
3614
  props: tableProps
3615
3615
  } = $xeTable;
3616
- if (true) {
3617
- const types = ['seq', 'checkbox', 'radio', 'expand', 'html'];
3618
- if (_vm.type && types.indexOf(_vm.type) === -1) {
3619
- warnLog('vxe.error.errProp', [`type=${_vm.type}`, types.join(', ')]);
3620
- }
3621
- if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isBoolean(_vm.cellRender) || _vm.cellRender && !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isObject(_vm.cellRender)) {
3622
- warnLog('vxe.error.errProp', [`column.cell-render=${_vm.cellRender}`, 'column.cell-render={}']);
3623
- }
3624
- if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isBoolean(_vm.editRender) || _vm.editRender && !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isObject(_vm.editRender)) {
3625
- warnLog('vxe.error.errProp', [`column.edit-render=${_vm.editRender}`, 'column.edit-render={}']);
3616
+ const types = ['seq', 'checkbox', 'radio', 'expand', 'html'];
3617
+ if (_vm.type && types.indexOf(_vm.type) === -1) {
3618
+ warnLog('vxe.error.errProp', [`type=${_vm.type}`, types.join(', ')]);
3619
+ }
3620
+ if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isBoolean(_vm.cellRender) || _vm.cellRender && !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isObject(_vm.cellRender)) {
3621
+ warnLog('vxe.error.errProp', [`column.cell-render=${_vm.cellRender}`, 'column.cell-render={}']);
3622
+ }
3623
+ if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isBoolean(_vm.editRender) || _vm.editRender && !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isObject(_vm.editRender)) {
3624
+ warnLog('vxe.error.errProp', [`column.edit-render=${_vm.editRender}`, 'column.edit-render={}']);
3625
+ }
3626
+ if (_vm.type === 'expand') {
3627
+ const {
3628
+ treeConfig
3629
+ } = tableProps;
3630
+ const {
3631
+ computeTreeOpts
3632
+ } = $xeTable.getComputeMaps();
3633
+ const treeOpts = computeTreeOpts.value;
3634
+ if (treeConfig && (treeOpts.showLine || treeOpts.line)) {
3635
+ errLog('vxe.error.errConflicts', ['tree-config.showLine', 'column.type=expand']);
3626
3636
  }
3627
- if (_vm.type === 'expand') {
3628
- const {
3629
- treeConfig
3630
- } = tableProps;
3631
- const {
3632
- computeTreeOpts
3633
- } = $xeTable.getComputeMaps();
3634
- const treeOpts = computeTreeOpts.value;
3635
- if (treeConfig && (treeOpts.showLine || treeOpts.line)) {
3636
- errLog('vxe.error.errConflicts', ['tree-config.showLine', 'column.type=expand']);
3637
+ }
3638
+ if (formatter) {
3639
+ if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isString(formatter)) {
3640
+ const gFormatOpts = columnInfo_formats.get(formatter) || (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default())[formatter];
3641
+ if (!gFormatOpts || !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(gFormatOpts.tableCellFormatMethod || gFormatOpts.cellFormatMethod)) {
3642
+ errLog('vxe.error.notFormats', [formatter]);
3637
3643
  }
3638
- }
3639
- if (formatter) {
3640
- if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isString(formatter)) {
3641
- const gFormatOpts = columnInfo_formats.get(formatter) || (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default())[formatter];
3642
- if (!gFormatOpts || !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(gFormatOpts.tableCellFormatMethod || gFormatOpts.cellFormatMethod)) {
3643
- errLog('vxe.error.notFormats', [formatter]);
3644
- }
3645
- } else if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(formatter)) {
3646
- const gFormatOpts = columnInfo_formats.get(formatter[0]) || (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default())[formatter[0]];
3647
- if (!gFormatOpts || !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(gFormatOpts.tableCellFormatMethod || gFormatOpts.cellFormatMethod)) {
3648
- errLog('vxe.error.notFormats', [formatter[0]]);
3649
- }
3644
+ } else if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(formatter)) {
3645
+ const gFormatOpts = columnInfo_formats.get(formatter[0]) || (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default())[formatter[0]];
3646
+ if (!gFormatOpts || !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(gFormatOpts.tableCellFormatMethod || gFormatOpts.cellFormatMethod)) {
3647
+ errLog('vxe.error.notFormats', [formatter[0]]);
3650
3648
  }
3651
3649
  }
3652
3650
  }
@@ -9250,29 +9248,27 @@ const {
9250
9248
  }
9251
9249
  return renderSimplePanel();
9252
9250
  };
9253
- if (true) {
9254
- (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
9255
- const customOpts = computeCustomOpts.value;
9256
- const {
9257
- mode
9258
- } = customOpts;
9259
- if (!VxeUIModalComponent) {
9260
- errLog('vxe.error.reqComp', ['vxe-modal']);
9261
- }
9262
- if (!VxeUIDrawerComponent && mode === 'drawer') {
9263
- errLog('vxe.error.reqComp', ['vxe-drawer']);
9264
- }
9265
- if (!VxeUIButtonComponent) {
9266
- errLog('vxe.error.reqComp', ['vxe-button']);
9267
- }
9268
- if (!VxeUINumberInputComponent) {
9269
- errLog('vxe.error.reqComp', ['vxe-number-input']);
9270
- }
9271
- if (!VxeUIRadioGroupComponent) {
9272
- errLog('vxe.error.reqComp', ['vxe-radio-group']);
9273
- }
9274
- });
9275
- }
9251
+ (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
9252
+ const customOpts = computeCustomOpts.value;
9253
+ const {
9254
+ mode
9255
+ } = customOpts;
9256
+ if (!VxeUIModalComponent) {
9257
+ errLog('vxe.error.reqComp', ['vxe-modal']);
9258
+ }
9259
+ if (!VxeUIDrawerComponent && mode === 'drawer') {
9260
+ errLog('vxe.error.reqComp', ['vxe-drawer']);
9261
+ }
9262
+ if (!VxeUIButtonComponent) {
9263
+ errLog('vxe.error.reqComp', ['vxe-button']);
9264
+ }
9265
+ if (!VxeUINumberInputComponent) {
9266
+ errLog('vxe.error.reqComp', ['vxe-number-input']);
9267
+ }
9268
+ if (!VxeUIRadioGroupComponent) {
9269
+ errLog('vxe.error.reqComp', ['vxe-radio-group']);
9270
+ }
9271
+ });
9276
9272
  return renderVN;
9277
9273
  }
9278
9274
  }));
@@ -9704,19 +9700,17 @@ const {
9704
9700
  }
9705
9701
  }) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)();
9706
9702
  };
9707
- if (true) {
9708
- (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
9709
- if (!VxeUIModalComponent) {
9710
- errLog('vxe.error.reqComp', ['vxe-modal']);
9711
- }
9712
- if (!VxeUIButtonComponent) {
9713
- errLog('vxe.error.reqComp', ['vxe-button']);
9714
- }
9715
- if (!VxeUISelectComponent) {
9716
- errLog('vxe.error.reqComp', ['vxe-select']);
9717
- }
9718
- });
9719
- }
9703
+ (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
9704
+ if (!VxeUIModalComponent) {
9705
+ errLog('vxe.error.reqComp', ['vxe-modal']);
9706
+ }
9707
+ if (!VxeUIButtonComponent) {
9708
+ errLog('vxe.error.reqComp', ['vxe-button']);
9709
+ }
9710
+ if (!VxeUISelectComponent) {
9711
+ errLog('vxe.error.reqComp', ['vxe-select']);
9712
+ }
9713
+ });
9720
9714
  return renderVN;
9721
9715
  }
9722
9716
  }));
@@ -10154,25 +10148,23 @@ const {
10154
10148
  }
10155
10149
  }) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)();
10156
10150
  };
10157
- if (true) {
10158
- (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
10159
- if (!VxeUIModalComponent) {
10160
- errLog('vxe.error.reqComp', ['vxe-modal']);
10161
- }
10162
- if (!VxeUIButtonComponent) {
10163
- errLog('vxe.error.reqComp', ['vxe-button']);
10164
- }
10165
- if (!VxeUISelectComponent) {
10166
- errLog('vxe.error.reqComp', ['vxe-select']);
10167
- }
10168
- if (!VxeUIInputComponent) {
10169
- errLog('vxe.error.reqComp', ['vxe-input']);
10170
- }
10171
- if (!VxeUICheckboxComponent) {
10172
- errLog('vxe.error.reqComp', ['vxe-checkbox']);
10173
- }
10174
- });
10175
- }
10151
+ (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
10152
+ if (!VxeUIModalComponent) {
10153
+ errLog('vxe.error.reqComp', ['vxe-modal']);
10154
+ }
10155
+ if (!VxeUIButtonComponent) {
10156
+ errLog('vxe.error.reqComp', ['vxe-button']);
10157
+ }
10158
+ if (!VxeUISelectComponent) {
10159
+ errLog('vxe.error.reqComp', ['vxe-select']);
10160
+ }
10161
+ if (!VxeUIInputComponent) {
10162
+ errLog('vxe.error.reqComp', ['vxe-input']);
10163
+ }
10164
+ if (!VxeUICheckboxComponent) {
10165
+ errLog('vxe.error.reqComp', ['vxe-checkbox']);
10166
+ }
10167
+ });
10176
10168
  return renderVN;
10177
10169
  }
10178
10170
  }));
@@ -11749,14 +11741,12 @@ const maxXWidth = 5e6;
11749
11741
  if (expandColumn && expandOpts.mode !== 'fixed' && mouseOpts.area) {
11750
11742
  errLog('vxe.error.errConflicts', ['mouse-config.area', 'column.type=expand']);
11751
11743
  }
11752
- if (true) {
11753
- if (htmlColumn) {
11754
- if (!columnOpts.useKey) {
11755
- errLog('vxe.error.reqProp', ['column-config.useKey & column.type=html']);
11756
- }
11757
- if (!rowOpts.useKey) {
11758
- errLog('vxe.error.reqProp', ['row-config.useKey & column.type=html']);
11759
- }
11744
+ if (htmlColumn) {
11745
+ if (!columnOpts.useKey) {
11746
+ errLog('vxe.error.reqProp', ['column-config.useKey & column.type=html']);
11747
+ }
11748
+ if (!rowOpts.useKey) {
11749
+ errLog('vxe.error.reqProp', ['row-config.useKey & column.type=html']);
11760
11750
  }
11761
11751
  }
11762
11752
  reactData.isGroup = isGroup;
@@ -13262,14 +13252,14 @@ const maxXWidth = 5e6;
13262
13252
  rowIndex: tableMethods.getRowIndex(row),
13263
13253
  $rowIndex: tableMethods.getVMRowIndex(row)
13264
13254
  }).then(() => {
13265
- const rExpandedMaps = {
13255
+ const rowTempExpandedMaps = {
13266
13256
  ...reactData.rowExpandedMaps
13267
13257
  };
13268
13258
  if (rowRest) {
13269
13259
  rowRest.expandLoaded = true;
13270
13260
  }
13271
- rExpandedMaps[rowid] = row;
13272
- reactData.rowExpandedMaps = rExpandedMaps;
13261
+ rowTempExpandedMaps[rowid] = row;
13262
+ reactData.rowExpandedMaps = rowTempExpandedMaps;
13273
13263
  }).catch(() => {
13274
13264
  if (rowRest) {
13275
13265
  rowRest.expandLoaded = false;
@@ -13442,28 +13432,26 @@ const maxXWidth = 5e6;
13442
13432
  if (treeConfig) {
13443
13433
  if (transform) {
13444
13434
  // 树结构自动转换
13445
- if (true) {
13446
- if (!treeOpts.rowField) {
13447
- errLog('vxe.error.reqProp', ['tree-config.rowField']);
13448
- }
13449
- if (!treeOpts.parentField) {
13450
- errLog('vxe.error.reqProp', ['tree-config.parentField']);
13451
- }
13452
- if (!childrenField) {
13453
- errLog('vxe.error.reqProp', ['tree-config.childrenField']);
13454
- }
13455
- if (!treeOpts.mapChildrenField) {
13456
- errLog('vxe.error.reqProp', ['tree-config.mapChildrenField']);
13457
- }
13458
- if (childrenField === treeOpts.mapChildrenField) {
13459
- errLog('vxe.error.errConflicts', ['tree-config.childrenField', 'tree-config.mapChildrenField']);
13460
- }
13461
- // fullData.forEach(row => {
13462
- // if (row[treeOpts.children] && row[treeOpts.children].length) {
13463
- // warnLog('vxe.error.errConflicts', ['tree-config.transform', `row.${treeOpts.children}`])
13464
- // }
13465
- // })
13435
+ if (!treeOpts.rowField) {
13436
+ errLog('vxe.error.reqProp', ['tree-config.rowField']);
13437
+ }
13438
+ if (!treeOpts.parentField) {
13439
+ errLog('vxe.error.reqProp', ['tree-config.parentField']);
13466
13440
  }
13441
+ if (!childrenField) {
13442
+ errLog('vxe.error.reqProp', ['tree-config.childrenField']);
13443
+ }
13444
+ if (!treeOpts.mapChildrenField) {
13445
+ errLog('vxe.error.reqProp', ['tree-config.mapChildrenField']);
13446
+ }
13447
+ if (childrenField === treeOpts.mapChildrenField) {
13448
+ errLog('vxe.error.errConflicts', ['tree-config.childrenField', 'tree-config.mapChildrenField']);
13449
+ }
13450
+ // fullData.forEach(row => {
13451
+ // if (row[treeOpts.children] && row[treeOpts.children].length) {
13452
+ // warnLog('vxe.error.errConflicts', ['tree-config.transform', `row.${treeOpts.children}`])
13453
+ // }
13454
+ // })
13467
13455
  treeData = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toArrayTree(fullData, {
13468
13456
  key: treeOpts.rowField,
13469
13457
  parentKey: treeOpts.parentField,
@@ -13527,16 +13515,14 @@ const maxXWidth = 5e6;
13527
13515
  // }
13528
13516
  // }
13529
13517
  // }
13530
- if (true) {
13531
- if (!(props.height || props.maxHeight)) {
13532
- errLog('vxe.error.reqProp', ['table.height | table.max-height | table.scroll-y={enabled: false}']);
13533
- }
13534
- // if (!props.showOverflow) {
13535
- // warnLog('vxe.error.reqProp', ['table.show-overflow'])
13536
- // }
13537
- if (props.spanMethod) {
13538
- warnLog('vxe.error.scrollErrProp', ['table.span-method']);
13539
- }
13518
+ if (!(props.height || props.maxHeight)) {
13519
+ errLog('vxe.error.reqProp', ['table.height | table.max-height | table.scroll-y={enabled: false}']);
13520
+ }
13521
+ // if (!props.showOverflow) {
13522
+ // warnLog('vxe.error.reqProp', ['table.show-overflow'])
13523
+ // }
13524
+ if (props.spanMethod) {
13525
+ errLog('vxe.error.scrollErrProp', ['table.span-method']);
13540
13526
  }
13541
13527
  }
13542
13528
  handleReserveStatus();
@@ -14676,23 +14662,6 @@ const maxXWidth = 5e6;
14676
14662
  }
14677
14663
  return tableMethods.createData(records).then(rows => isArr ? rows : rows[0]);
14678
14664
  },
14679
- // toOriginalRecords (rows: any[]) {
14680
- // const { treeConfig } = props
14681
- // const treeOpts = computeTreeOpts.value
14682
- // const { transform, mapChildrenField } = treeOpts
14683
- // const rowkey = getRowkey($xeTable)
14684
- // if (treeConfig) {
14685
- // if (transform) {
14686
- // return []
14687
- // }
14688
- // return []
14689
- // }
14690
- // return rows.map(item => {
14691
- // const obj = Object.assign({}, item)
14692
- // delete obj.rowkey
14693
- // return obj
14694
- // })
14695
- // },
14696
14665
  /**
14697
14666
  * 还原数据
14698
14667
  * 如果不传任何参数,则还原整个表格
@@ -14702,12 +14671,20 @@ const maxXWidth = 5e6;
14702
14671
  */
14703
14672
  revertData(rows, field) {
14704
14673
  const {
14705
- keepSource
14674
+ keepSource,
14675
+ treeConfig
14706
14676
  } = props;
14707
14677
  const {
14678
+ fullAllDataRowIdData,
14708
14679
  tableSourceData,
14709
- sourceDataRowIdData
14680
+ sourceDataRowIdData,
14681
+ tableFullData,
14682
+ afterFullData
14710
14683
  } = internalData;
14684
+ const treeOpts = computeTreeOpts.value;
14685
+ const {
14686
+ transform
14687
+ } = treeOpts;
14711
14688
  if (!keepSource) {
14712
14689
  if (true) {
14713
14690
  warnLog('vxe.error.reqProp', ['keep-source']);
@@ -14722,9 +14699,10 @@ const maxXWidth = 5e6;
14722
14699
  } else {
14723
14700
  targetRows = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toArray($xeTable.getUpdateRecords());
14724
14701
  }
14702
+ let reDelFlag = false;
14725
14703
  if (targetRows.length) {
14726
14704
  targetRows.forEach(row => {
14727
- if (!tableMethods.isInsertByRow(row)) {
14705
+ if (!$xeTable.isInsertByRow(row)) {
14728
14706
  const rowid = getRowid($xeTable, row);
14729
14707
  const oRow = sourceDataRowIdData[rowid];
14730
14708
  if (oRow && row) {
@@ -14733,14 +14711,38 @@ const maxXWidth = 5e6;
14733
14711
  } else {
14734
14712
  external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().destructuring(row, external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().clone(oRow, true));
14735
14713
  }
14714
+ if ($xeTable.isRemoveByRow(row)) {
14715
+ const rowRest = fullAllDataRowIdData[rowid];
14716
+ if (rowRest) {
14717
+ const reRow = rowRest.row;
14718
+ tableFullData.unshift(reRow);
14719
+ afterFullData.unshift(reRow);
14720
+ reDelFlag = true;
14721
+ }
14722
+ }
14736
14723
  }
14737
14724
  }
14738
14725
  });
14739
14726
  }
14740
14727
  if (rows) {
14741
- return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();
14728
+ if (reDelFlag) {
14729
+ $xeTable.updateFooter();
14730
+ $xeTable.cacheRowMap(false);
14731
+ $xeTable.handleTableData(treeConfig && transform);
14732
+ if (!(treeConfig && transform)) {
14733
+ $xeTable.updateAfterDataIndex();
14734
+ }
14735
+ $xeTable.checkSelectionStatus();
14736
+ if (reactData.scrollYLoad) {
14737
+ $xeTable.updateScrollYSpace();
14738
+ }
14739
+ }
14740
+ return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)().then(() => {
14741
+ $xeTable.updateCellAreas();
14742
+ return $xeTable.recalculate();
14743
+ });
14742
14744
  }
14743
- return tableMethods.reloadData(tableSourceData);
14745
+ return $xeTable.reloadData(tableSourceData);
14744
14746
  },
14745
14747
  /**
14746
14748
  * 清空单元格内容
@@ -14873,6 +14875,13 @@ const maxXWidth = 5e6;
14873
14875
  const rowid = getRowid($xeTable, row);
14874
14876
  return !!editStore.insertMaps[rowid];
14875
14877
  },
14878
+ isRemoveByRow(row) {
14879
+ const {
14880
+ editStore
14881
+ } = reactData;
14882
+ const rowid = getRowid($xeTable, row);
14883
+ return !!editStore.removeMaps[rowid];
14884
+ },
14876
14885
  /**
14877
14886
  * 删除所有新增的临时数据
14878
14887
  * @returns
@@ -18059,18 +18068,25 @@ const maxXWidth = 5e6;
18059
18068
  const {
18060
18069
  treeConfig
18061
18070
  } = props;
18062
- const treeOpts = computeTreeOpts.value;
18071
+ const {
18072
+ treeExpandedMaps
18073
+ } = reactData;
18063
18074
  const {
18064
18075
  fullAllDataRowIdData,
18065
18076
  tableFullData,
18066
18077
  tableFullTreeData
18067
18078
  } = internalData;
18079
+ const treeOpts = computeTreeOpts.value;
18068
18080
  const childrenField = treeOpts.children || treeOpts.childrenField;
18069
18081
  const hasChildField = treeOpts.hasChild || treeOpts.hasChildField;
18070
18082
  const rowkey = getRowkey($xeTable);
18071
- const isLazy = treeConfig && treeOpts.lazy;
18072
- const fullAllDataRowIdMaps = {};
18083
+ const fullAllDataRowIdMaps = {
18084
+ ...fullAllDataRowIdData
18085
+ }; // 存在已删除数据
18073
18086
  const fullDataRowIdMaps = {};
18087
+ const treeTempExpandedMaps = {
18088
+ ...treeExpandedMaps
18089
+ };
18074
18090
  const handleRow = (row, index, items, path, parentRow, nodes) => {
18075
18091
  let rowid = getRowid($xeTable, row);
18076
18092
  const seq = treeConfig && path ? toTreePathSeq(path) : index + 1;
@@ -18079,8 +18095,16 @@ const maxXWidth = 5e6;
18079
18095
  rowid = getRowUniqueId();
18080
18096
  external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().set(row, rowkey, rowid);
18081
18097
  }
18082
- if (isLazy && row[hasChildField] && external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isUndefined(row[childrenField])) {
18083
- row[childrenField] = null;
18098
+ if (treeConfig && treeOpts.lazy) {
18099
+ const treeExpRest = treeExpandedMaps[rowid];
18100
+ if (row[hasChildField] && external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isUndefined(row[childrenField])) {
18101
+ row[childrenField] = null;
18102
+ }
18103
+ if (treeExpRest) {
18104
+ if (!row[childrenField] || !row[childrenField].length) {
18105
+ delete treeTempExpandedMaps[rowid];
18106
+ }
18107
+ }
18084
18108
  }
18085
18109
  let rowRest = fullAllDataRowIdData[rowid];
18086
18110
  if (!rowRest) {
@@ -18101,6 +18125,8 @@ const maxXWidth = 5e6;
18101
18125
  expandHeight: 0
18102
18126
  };
18103
18127
  }
18128
+ rowRest.treeLoaded = false;
18129
+ rowRest.expandLoaded = false;
18104
18130
  rowRest.row = row;
18105
18131
  rowRest.items = items;
18106
18132
  rowRest.parent = parentRow;
@@ -18109,8 +18135,6 @@ const maxXWidth = 5e6;
18109
18135
  fullDataRowIdMaps[rowid] = rowRest;
18110
18136
  fullAllDataRowIdMaps[rowid] = rowRest;
18111
18137
  };
18112
- internalData.fullDataRowIdData = fullDataRowIdMaps;
18113
- internalData.fullAllDataRowIdData = fullAllDataRowIdMaps;
18114
18138
  if (treeConfig) {
18115
18139
  external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eachTree(tableFullTreeData, handleRow, {
18116
18140
  children: childrenField
@@ -18118,6 +18142,9 @@ const maxXWidth = 5e6;
18118
18142
  } else {
18119
18143
  tableFullData.forEach(handleRow);
18120
18144
  }
18145
+ internalData.fullDataRowIdData = fullDataRowIdMaps;
18146
+ internalData.fullAllDataRowIdData = fullAllDataRowIdMaps;
18147
+ reactData.treeExpandedMaps = treeTempExpandedMaps;
18121
18148
  },
18122
18149
  cacheSourceMap(fullData) {
18123
18150
  const {
@@ -21149,18 +21176,16 @@ const maxXWidth = 5e6;
21149
21176
  }
21150
21177
  };
21151
21178
  // 检测对应模块是否安装
21152
- if (true) {
21153
- 'openExport,openPrint,exportData,openImport,importData,saveFile,readFile,importByFile,print'.split(',').forEach(name => {
21154
- $xeTable[name] = function () {
21155
- errLog('vxe.error.reqModule', ['VxeTableExportModule']);
21156
- };
21157
- });
21158
- 'clearValidate,fullValidate,validate'.split(',').forEach(name => {
21159
- $xeTable[name] = function () {
21160
- errLog('vxe.error.reqModule', ['VxeTableValidatorModule']);
21161
- };
21162
- });
21163
- }
21179
+ 'openExport,openPrint,exportData,openImport,importData,saveFile,readFile,importByFile,print'.split(',').forEach(name => {
21180
+ $xeTable[name] = function () {
21181
+ errLog('vxe.error.reqModule', ['VxeTableExportModule']);
21182
+ };
21183
+ });
21184
+ 'clearValidate,fullValidate,validate'.split(',').forEach(name => {
21185
+ $xeTable[name] = function () {
21186
+ errLog('vxe.error.reqModule', ['VxeTableValidatorModule']);
21187
+ };
21188
+ });
21164
21189
  Object.assign($xeTable, tableMethods, tablePrivateMethods);
21165
21190
  /**
21166
21191
  * 渲染浮固定列
@@ -22139,20 +22164,18 @@ const maxXWidth = 5e6;
22139
22164
  $table: $xeTable
22140
22165
  });
22141
22166
  });
22142
- if (true) {
22143
- (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
22144
- if (props.loading) {
22145
- if (!VxeUILoadingComponent && !slots.loading) {
22146
- errLog('vxe.error.reqComp', ['vxe-loading']);
22147
- }
22167
+ (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
22168
+ if (props.loading) {
22169
+ if (!VxeUILoadingComponent && !slots.loading) {
22170
+ errLog('vxe.error.reqComp', ['vxe-loading']);
22148
22171
  }
22149
- if (props.showOverflow === true || props.showOverflow === 'tooltip' || props.showHeaderOverflow === true || props.showHeaderOverflow === 'tooltip' || props.showFooterOverflow === true || props.showFooterOverflow === 'tooltip' || props.tooltipConfig || props.editRules) {
22150
- if (!VxeUITooltipComponent) {
22151
- errLog('vxe.error.reqComp', ['vxe-tooltip']);
22152
- }
22172
+ }
22173
+ if (props.showOverflow === true || props.showOverflow === 'tooltip' || props.showHeaderOverflow === true || props.showHeaderOverflow === 'tooltip' || props.showFooterOverflow === true || props.showFooterOverflow === 'tooltip' || props.tooltipConfig || props.editRules) {
22174
+ if (!VxeUITooltipComponent) {
22175
+ errLog('vxe.error.reqComp', ['vxe-tooltip']);
22153
22176
  }
22154
- });
22155
- }
22177
+ }
22178
+ });
22156
22179
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.provide)('$xeColgroup', null);
22157
22180
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.provide)('$xeTable', $xeTable);
22158
22181
  $xeTable.renderVN = renderVN;
@@ -25367,9 +25390,7 @@ export_hook_hooks.add('tableExportModule', {
25367
25390
  }
25368
25391
  } else {
25369
25392
  // 不支持的浏览器
25370
- if (true) {
25371
- errLog('vxe.error.notExp');
25372
- }
25393
+ errLog('vxe.error.notExp');
25373
25394
  _importResolve({
25374
25395
  status: true
25375
25396
  });
@@ -26097,10 +26118,8 @@ export_hook_hooks.add('tableExportModule', {
26097
26118
  message: true,
26098
26119
  types: external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().keys(exportOpts._typeMaps)
26099
26120
  }, exportOpts, options);
26100
- if (true) {
26101
- if (!props.exportConfig) {
26102
- errLog('vxe.error.reqProp', ['export-config']);
26103
- }
26121
+ if (!props.exportConfig) {
26122
+ errLog('vxe.error.reqProp', ['export-config']);
26104
26123
  }
26105
26124
  handleExportAndPrint(defOpts);
26106
26125
  },
@@ -26110,10 +26129,8 @@ export_hook_hooks.add('tableExportModule', {
26110
26129
  const defOpts = Object.assign({
26111
26130
  message: true
26112
26131
  }, printOpts, options);
26113
- if (true) {
26114
- if (!props.printConfig) {
26115
- errLog('vxe.error.reqProp', ['print-config']);
26116
- }
26132
+ if (!props.printConfig) {
26133
+ errLog('vxe.error.reqProp', ['print-config']);
26117
26134
  }
26118
26135
  handleExportAndPrint(defOpts, true);
26119
26136
  }
@@ -27036,9 +27053,7 @@ validator_hook_hooks.add('tableValidatorModule', {
27036
27053
  }
27037
27054
  }
27038
27055
  } else {
27039
- if (true) {
27040
- errLog('vxe.error.notValidators', [validator]);
27041
- }
27056
+ errLog('vxe.error.notValidators', [validator]);
27042
27057
  }
27043
27058
  } else {
27044
27059
  customValid = validator(validParams);
@@ -27755,10 +27770,8 @@ function getComponentOns(renderOpts, params, eFns) {
27755
27770
  const ons = {};
27756
27771
  external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().objectEach(events, (func, key) => {
27757
27772
  ons[getOnName(key)] = function (...args) {
27758
- if (true) {
27759
- if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(func)) {
27760
- errLog('vxe.error.errFunc', [func]);
27761
- }
27773
+ if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(func)) {
27774
+ errLog('vxe.error.errFunc', [func]);
27762
27775
  }
27763
27776
  func(params, ...args);
27764
27777
  };
@@ -28245,6 +28258,69 @@ function handleExportTreeSelectMethod(params) {
28245
28258
  } = params;
28246
28259
  return options.original ? getCellValue(row, column) : getTreeSelectCellValue(column.editRender || column.cellRender, params);
28247
28260
  }
28261
+ function handleNumberCell(renderOpts, params) {
28262
+ const {
28263
+ props = {},
28264
+ showNegativeStatus
28265
+ } = renderOpts;
28266
+ const {
28267
+ row,
28268
+ column
28269
+ } = params;
28270
+ const {
28271
+ type
28272
+ } = props;
28273
+ let cellValue = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(row, column.field);
28274
+ let isNegative = false;
28275
+ if (!isEmptyValue(cellValue)) {
28276
+ const numberInputConfig = render_getConfig().numberInput || {};
28277
+ if (type === 'float') {
28278
+ const autoFill = handleDefaultValue(props.autoFill, numberInputConfig.autoFill, true);
28279
+ const digits = handleDefaultValue(props.digits, numberInputConfig.digits, 1);
28280
+ cellValue = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toFixed(external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().floor(cellValue, digits), digits);
28281
+ if (!autoFill) {
28282
+ cellValue = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(cellValue);
28283
+ }
28284
+ if (showNegativeStatus) {
28285
+ if (cellValue < 0) {
28286
+ isNegative = true;
28287
+ }
28288
+ }
28289
+ } else if (type === 'amount') {
28290
+ const autoFill = handleDefaultValue(props.autoFill, numberInputConfig.autoFill, true);
28291
+ const digits = handleDefaultValue(props.digits, numberInputConfig.digits, 2);
28292
+ const showCurrency = handleDefaultValue(props.showCurrency, numberInputConfig.showCurrency, false);
28293
+ cellValue = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(cellValue);
28294
+ if (showNegativeStatus) {
28295
+ if (cellValue < 0) {
28296
+ isNegative = true;
28297
+ }
28298
+ }
28299
+ cellValue = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().commafy(cellValue, {
28300
+ digits
28301
+ });
28302
+ if (!autoFill) {
28303
+ const [iStr, dStr] = cellValue.split('.');
28304
+ if (dStr) {
28305
+ const dRest = dStr.replace(/0+$/, '');
28306
+ cellValue = dRest ? [iStr, '.', dRest].join('') : iStr;
28307
+ }
28308
+ }
28309
+ if (showCurrency) {
28310
+ cellValue = `${props.currencySymbol || numberInputConfig.currencySymbol || render_getI18n('vxe.numberInput.currencySymbol') || ''}${cellValue}`;
28311
+ }
28312
+ } else {
28313
+ if (showNegativeStatus) {
28314
+ if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(cellValue) < 0) {
28315
+ isNegative = true;
28316
+ }
28317
+ }
28318
+ }
28319
+ }
28320
+ return getCellLabelVNs(renderOpts, params, cellValue, isNegative ? {
28321
+ class: 'is--negative'
28322
+ } : {});
28323
+ }
28248
28324
  /**
28249
28325
  * 表格 - 渲染器
28250
28326
  */
@@ -28316,72 +28392,13 @@ render_renderer.mixin({
28316
28392
  renderTableFilter: defaultFilterRender,
28317
28393
  tableFilterDefaultMethod: handleInputFilterMethod
28318
28394
  },
28395
+ FormatNumberInput: {
28396
+ renderTableDefault: handleNumberCell
28397
+ },
28319
28398
  VxeNumberInput: {
28320
28399
  tableAutoFocus: 'input',
28321
28400
  renderTableEdit: defaultEditRender,
28322
- renderTableCell(renderOpts, params) {
28323
- const {
28324
- props = {},
28325
- showNegativeStatus
28326
- } = renderOpts;
28327
- const {
28328
- row,
28329
- column
28330
- } = params;
28331
- const {
28332
- type
28333
- } = props;
28334
- let cellValue = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(row, column.field);
28335
- let isNegative = false;
28336
- if (!isEmptyValue(cellValue)) {
28337
- const numberInputConfig = render_getConfig().numberInput || {};
28338
- if (type === 'float') {
28339
- const autoFill = handleDefaultValue(props.autoFill, numberInputConfig.autoFill, true);
28340
- const digits = handleDefaultValue(props.digits, numberInputConfig.digits, 1);
28341
- cellValue = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toFixed(external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().floor(cellValue, digits), digits);
28342
- if (!autoFill) {
28343
- cellValue = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(cellValue);
28344
- }
28345
- if (showNegativeStatus) {
28346
- if (cellValue < 0) {
28347
- isNegative = true;
28348
- }
28349
- }
28350
- } else if (type === 'amount') {
28351
- const autoFill = handleDefaultValue(props.autoFill, numberInputConfig.autoFill, true);
28352
- const digits = handleDefaultValue(props.digits, numberInputConfig.digits, 2);
28353
- const showCurrency = handleDefaultValue(props.showCurrency, numberInputConfig.showCurrency, false);
28354
- cellValue = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(cellValue);
28355
- if (showNegativeStatus) {
28356
- if (cellValue < 0) {
28357
- isNegative = true;
28358
- }
28359
- }
28360
- cellValue = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().commafy(cellValue, {
28361
- digits
28362
- });
28363
- if (!autoFill) {
28364
- const [iStr, dStr] = cellValue.split('.');
28365
- if (dStr) {
28366
- const dRest = dStr.replace(/0+$/, '');
28367
- cellValue = dRest ? [iStr, '.', dRest].join('') : iStr;
28368
- }
28369
- }
28370
- if (showCurrency) {
28371
- cellValue = `${props.currencySymbol || numberInputConfig.currencySymbol || render_getI18n('vxe.numberInput.currencySymbol') || ''}${cellValue}`;
28372
- }
28373
- } else {
28374
- if (showNegativeStatus) {
28375
- if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(cellValue) < 0) {
28376
- isNegative = true;
28377
- }
28378
- }
28379
- }
28380
- }
28381
- return getCellLabelVNs(renderOpts, params, cellValue, isNegative ? {
28382
- class: 'is--negative'
28383
- } : {});
28384
- },
28401
+ renderTableCell: handleNumberCell,
28385
28402
  renderTableFooter(renderOpts, params) {
28386
28403
  const {
28387
28404
  props = {}
@@ -28524,11 +28541,20 @@ render_renderer.mixin({
28524
28541
  tableFilterDefaultMethod: handleFilterMethod,
28525
28542
  tableExportMethod: handleExportSelectMethod
28526
28543
  },
28544
+ /**
28545
+ * 已废弃,被 FormatSelect 替换
28546
+ * @deprecated
28547
+ */
28527
28548
  formatOption: {
28528
28549
  renderTableDefault(renderOpts, params) {
28529
28550
  return getCellLabelVNs(renderOpts, params, getSelectCellValue(renderOpts, params));
28530
28551
  }
28531
28552
  },
28553
+ FormatSelect: {
28554
+ renderTableDefault(renderOpts, params) {
28555
+ return getCellLabelVNs(renderOpts, params, getSelectCellValue(renderOpts, params));
28556
+ }
28557
+ },
28532
28558
  VxeTreeSelect: {
28533
28559
  tableAutoFocus: 'input',
28534
28560
  renderTableEdit: defaultTableOrTreeSelectEditRender,
@@ -28537,11 +28563,20 @@ render_renderer.mixin({
28537
28563
  },
28538
28564
  tableExportMethod: handleExportTreeSelectMethod
28539
28565
  },
28566
+ /**
28567
+ * 已废弃,被 FormatTreeSelect 替换
28568
+ * @deprecated
28569
+ */
28540
28570
  formatTree: {
28541
28571
  renderTableDefault(renderOpts, params) {
28542
28572
  return getCellLabelVNs(renderOpts, params, getTreeSelectCellValue(renderOpts, params));
28543
28573
  }
28544
28574
  },
28575
+ FormatTreeSelect: {
28576
+ renderTableDefault(renderOpts, params) {
28577
+ return getCellLabelVNs(renderOpts, params, getTreeSelectCellValue(renderOpts, params));
28578
+ }
28579
+ },
28545
28580
  VxeTableSelect: {
28546
28581
  tableAutoFocus: 'input',
28547
28582
  renderTableEdit: defaultTableOrTreeSelectEditRender,
@@ -29039,9 +29074,7 @@ const {
29039
29074
  if (tCommandMethod) {
29040
29075
  tCommandMethod(params);
29041
29076
  } else {
29042
- if (true) {
29043
- errLog('vxe.error.notCommands', [code]);
29044
- }
29077
+ errLog('vxe.error.notCommands', [code]);
29045
29078
  }
29046
29079
  }
29047
29080
  $xeToolbar.dispatchEvent('button-click', params, evnt);
@@ -29073,9 +29106,7 @@ const {
29073
29106
  if (tCommandMethod) {
29074
29107
  tCommandMethod(params);
29075
29108
  } else {
29076
- if (true) {
29077
- errLog('vxe.error.notCommands', [code]);
29078
- }
29109
+ errLog('vxe.error.notCommands', [code]);
29079
29110
  }
29080
29111
  }
29081
29112
  $xeToolbar.dispatchEvent('tool-click', params, evnt);
@@ -29449,25 +29480,21 @@ const {
29449
29480
  warnLog('vxe.error.notFunc', ['queryMethod']);
29450
29481
  }
29451
29482
  const customOpts = computeCustomOpts.value;
29452
- if (true) {
29453
- if (customOpts.isFooter) {
29454
- warnLog('vxe.error.delProp', ['toolbar.custom.isFooter', 'table.custom-config.showFooter']);
29455
- }
29456
- if (customOpts.showFooter) {
29457
- warnLog('vxe.error.delProp', ['toolbar.custom.showFooter', 'table.custom-config.showFooter']);
29458
- }
29459
- if (customOpts.immediate) {
29460
- warnLog('vxe.error.delProp', ['toolbar.custom.immediate', 'table.custom-config.immediate']);
29461
- }
29462
- if (customOpts.trigger) {
29463
- warnLog('vxe.error.delProp', ['toolbar.custom.trigger', 'table.custom-config.trigger']);
29464
- }
29483
+ if (customOpts.isFooter) {
29484
+ warnLog('vxe.error.delProp', ['toolbar.custom.isFooter', 'table.custom-config.showFooter']);
29465
29485
  }
29466
- if (true) {
29467
- if (props.refresh || props.import || props.export || props.print || props.zoom) {
29468
- if (!VxeUIButtonComponent) {
29469
- errLog('vxe.error.reqComp', ['vxe-button']);
29470
- }
29486
+ if (customOpts.showFooter) {
29487
+ warnLog('vxe.error.delProp', ['toolbar.custom.showFooter', 'table.custom-config.showFooter']);
29488
+ }
29489
+ if (customOpts.immediate) {
29490
+ warnLog('vxe.error.delProp', ['toolbar.custom.immediate', 'table.custom-config.immediate']);
29491
+ }
29492
+ if (customOpts.trigger) {
29493
+ warnLog('vxe.error.delProp', ['toolbar.custom.trigger', 'table.custom-config.trigger']);
29494
+ }
29495
+ if (props.refresh || props.import || props.export || props.print || props.zoom) {
29496
+ if (!VxeUIButtonComponent) {
29497
+ errLog('vxe.error.reqComp', ['vxe-button']);
29471
29498
  }
29472
29499
  }
29473
29500
  });
@@ -29520,7 +29547,7 @@ const {
29520
29547
  renderEmptyElement: grid_renderEmptyElement
29521
29548
  } = core_.VxeUI;
29522
29549
  const tableComponentPropKeys = Object.keys(src_props);
29523
- const tableComponentMethodKeys = ['clearAll', 'syncData', 'updateData', 'loadData', 'reloadData', 'reloadRow', 'loadColumn', 'reloadColumn', 'getRowNode', 'getColumnNode', 'getRowIndex', 'getVTRowIndex', 'getVMRowIndex', 'getColumnIndex', 'getVTColumnIndex', 'getVMColumnIndex', 'setRow', 'createData', 'createRow', 'revertData', 'clearData', 'isInsertByRow', 'isUpdateByRow', 'getColumns', 'getColumnById', 'getColumnByField', 'getTableColumn', 'getFullColumns', 'getData', 'getCheckboxRecords', 'getParentRow', 'getTreeParentRow', 'getRowSeq', 'getRowById', 'getRowid', 'getTableData', 'getFullData', 'setColumnFixed', 'clearColumnFixed', 'setColumnWidth', 'getColumnWidth', 'setRowHeightConf', 'getRowHeightConf', 'setRowHeight', 'getRowHeight', 'hideColumn', 'showColumn', 'resetColumn', 'refreshColumn', 'refreshScroll', 'recalculate', 'closeTooltip', 'isAllCheckboxChecked', 'isAllCheckboxIndeterminate', 'getCheckboxIndeterminateRecords', 'setCheckboxRow', 'setCheckboxRowKey', 'isCheckedByCheckboxRow', 'isCheckedByCheckboxRowKey', 'isIndeterminateByCheckboxRow', 'isIndeterminateByCheckboxRowKey', 'toggleCheckboxRow', 'setAllCheckboxRow', 'getRadioReserveRecord', 'clearRadioReserve', 'getCheckboxReserveRecords', 'clearCheckboxReserve', 'toggleAllCheckboxRow', 'clearCheckboxRow', 'setCurrentRow', 'isCheckedByRadioRow', 'isCheckedByRadioRowKey', 'setRadioRow', 'setRadioRowKey', 'clearCurrentRow', 'clearRadioRow', 'getCurrentRecord', 'getRadioRecord', 'getCurrentColumn', 'setCurrentColumn', 'clearCurrentColumn', 'setPendingRow', 'togglePendingRow', 'getPendingRecords', 'clearPendingRow', 'sort', 'setSort', 'clearSort', 'isSort', 'getSortColumns', 'closeFilter', 'isFilter', 'isActiveFilterByColumn', 'isRowExpandLoaded', 'clearRowExpandLoaded', 'reloadRowExpand', 'reloadRowExpand', 'toggleRowExpand', 'setAllRowExpand', 'setRowExpand', 'isExpandByRow', 'isRowExpandByRow', 'clearRowExpand', 'clearRowExpandReserve', 'getRowExpandRecords', 'getTreeExpandRecords', 'isTreeExpandLoaded', 'clearTreeExpandLoaded', 'reloadTreeExpand', 'reloadTreeChilds', 'toggleTreeExpand', 'setAllTreeExpand', 'setTreeExpand', 'isTreeExpandByRow', 'clearTreeExpand', 'clearTreeExpandReserve', 'getScroll', 'scrollTo', 'scrollToRow', 'scrollToColumn', 'clearScroll', 'updateFooter', 'updateStatus', 'setMergeCells', 'removeInsertRow', 'removeMergeCells', 'getMergeCells', 'clearMergeCells', 'setMergeFooterItems', 'removeMergeFooterItems', 'getMergeFooterItems', 'clearMergeFooterItems', 'getCustomStoreData', 'openTooltip', 'getCellLabel', 'getCellElement', 'focus', 'blur', 'connect'];
29550
+ const tableComponentMethodKeys = ['clearAll', 'syncData', 'updateData', 'loadData', 'reloadData', 'reloadRow', 'loadColumn', 'reloadColumn', 'getRowNode', 'getColumnNode', 'getRowIndex', 'getVTRowIndex', 'getVMRowIndex', 'getColumnIndex', 'getVTColumnIndex', 'getVMColumnIndex', 'setRow', 'createData', 'createRow', 'revertData', 'clearData', 'isRemoveByRow', 'isInsertByRow', 'isUpdateByRow', 'getColumns', 'getColumnById', 'getColumnByField', 'getTableColumn', 'getFullColumns', 'getData', 'getCheckboxRecords', 'getParentRow', 'getTreeParentRow', 'getRowSeq', 'getRowById', 'getRowid', 'getTableData', 'getFullData', 'setColumnFixed', 'clearColumnFixed', 'setColumnWidth', 'getColumnWidth', 'setRowHeightConf', 'getRowHeightConf', 'setRowHeight', 'getRowHeight', 'hideColumn', 'showColumn', 'resetColumn', 'refreshColumn', 'refreshScroll', 'recalculate', 'closeTooltip', 'isAllCheckboxChecked', 'isAllCheckboxIndeterminate', 'getCheckboxIndeterminateRecords', 'setCheckboxRow', 'setCheckboxRowKey', 'isCheckedByCheckboxRow', 'isCheckedByCheckboxRowKey', 'isIndeterminateByCheckboxRow', 'isIndeterminateByCheckboxRowKey', 'toggleCheckboxRow', 'setAllCheckboxRow', 'getRadioReserveRecord', 'clearRadioReserve', 'getCheckboxReserveRecords', 'clearCheckboxReserve', 'toggleAllCheckboxRow', 'clearCheckboxRow', 'setCurrentRow', 'isCheckedByRadioRow', 'isCheckedByRadioRowKey', 'setRadioRow', 'setRadioRowKey', 'clearCurrentRow', 'clearRadioRow', 'getCurrentRecord', 'getRadioRecord', 'getCurrentColumn', 'setCurrentColumn', 'clearCurrentColumn', 'setPendingRow', 'togglePendingRow', 'getPendingRecords', 'clearPendingRow', 'sort', 'setSort', 'clearSort', 'isSort', 'getSortColumns', 'closeFilter', 'isFilter', 'isActiveFilterByColumn', 'isRowExpandLoaded', 'clearRowExpandLoaded', 'reloadRowExpand', 'reloadRowExpand', 'toggleRowExpand', 'setAllRowExpand', 'setRowExpand', 'isExpandByRow', 'isRowExpandByRow', 'clearRowExpand', 'clearRowExpandReserve', 'getRowExpandRecords', 'getTreeExpandRecords', 'isTreeExpandLoaded', 'clearTreeExpandLoaded', 'reloadTreeExpand', 'reloadTreeChilds', 'toggleTreeExpand', 'setAllTreeExpand', 'setTreeExpand', 'isTreeExpandByRow', 'clearTreeExpand', 'clearTreeExpandReserve', 'getScroll', 'scrollTo', 'scrollToRow', 'scrollToColumn', 'clearScroll', 'updateFooter', 'updateStatus', 'setMergeCells', 'removeInsertRow', 'removeMergeCells', 'getMergeCells', 'clearMergeCells', 'setMergeFooterItems', 'removeMergeFooterItems', 'getMergeFooterItems', 'clearMergeFooterItems', 'getCustomStoreData', 'openTooltip', 'getCellLabel', 'getCellElement', 'focus', 'blur', 'connect'];
29524
29551
  const gridComponentEmits = [...emits, 'page-change', 'form-submit', 'form-submit-invalid', 'form-reset', 'form-collapse', 'form-toggle-collapse', 'proxy-query', 'proxy-delete', 'proxy-save', 'toolbar-button-click', 'toolbar-tool-click', 'zoom'];
29525
29552
  /* harmony default export */ var grid = ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.defineComponent)({
29526
29553
  name: 'VxeGrid',
@@ -29984,9 +30011,7 @@ const gridComponentEmits = [...emits, 'page-change', 'form-submit', 'form-submit
29984
30011
  if (slots[funcSlot]) {
29985
30012
  return slots[funcSlot];
29986
30013
  } else {
29987
- if (true) {
29988
- errLog('vxe.error.notSlot', [funcSlot]);
29989
- }
30014
+ errLog('vxe.error.notSlot', [funcSlot]);
29990
30015
  }
29991
30016
  } else {
29992
30017
  return funcSlot;
@@ -30585,9 +30610,7 @@ const gridComponentEmits = [...emits, 'page-change', 'form-submit', 'form-submit
30585
30610
  };
30586
30611
  });
30587
30612
  } else {
30588
- if (true) {
30589
- errLog('vxe.error.notFunc', ['proxy-config.ajax.query']);
30590
- }
30613
+ errLog('vxe.error.notFunc', ['proxy-config.ajax.query']);
30591
30614
  }
30592
30615
  break;
30593
30616
  }
@@ -30675,9 +30698,7 @@ const gridComponentEmits = [...emits, 'page-change', 'form-submit', 'form-submit
30675
30698
  }
30676
30699
  }
30677
30700
  } else {
30678
- if (true) {
30679
- errLog('vxe.error.notFunc', ['proxy-config.ajax.delete']);
30680
- }
30701
+ errLog('vxe.error.notFunc', ['proxy-config.ajax.delete']);
30681
30702
  }
30682
30703
  break;
30683
30704
  }
@@ -30781,9 +30802,7 @@ const gridComponentEmits = [...emits, 'page-change', 'form-submit', 'form-submit
30781
30802
  }
30782
30803
  });
30783
30804
  } else {
30784
- if (true) {
30785
- errLog('vxe.error.notFunc', ['proxy-config.ajax.save']);
30786
- }
30805
+ errLog('vxe.error.notFunc', ['proxy-config.ajax.save']);
30787
30806
  }
30788
30807
  break;
30789
30808
  }
@@ -30800,9 +30819,7 @@ const gridComponentEmits = [...emits, 'page-change', 'form-submit', 'form-submit
30800
30819
  $table: $xeTable
30801
30820
  }, ...args);
30802
30821
  } else {
30803
- if (true) {
30804
- errLog('vxe.error.notCommands', [code]);
30805
- }
30822
+ errLog('vxe.error.notCommands', [code]);
30806
30823
  }
30807
30824
  }
30808
30825
  }
@@ -31006,35 +31023,29 @@ const gridComponentEmits = [...emits, 'page-change', 'form-submit', 'form-submit
31006
31023
  });
31007
31024
  initPages();
31008
31025
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
31009
- if (true) {
31010
- (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
31011
- if (props.formConfig) {
31012
- if (!VxeUIFormComponent) {
31013
- errLog('vxe.error.reqComp', ['vxe-form']);
31014
- }
31015
- }
31016
- if (props.pagerConfig) {
31017
- if (!VxeUIPagerComponent) {
31018
- errLog('vxe.error.reqComp', ['vxe-pager']);
31019
- }
31020
- }
31021
- });
31022
- }
31023
31026
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
31024
31027
  const {
31025
31028
  columns
31026
31029
  } = props;
31030
+ if (props.formConfig) {
31031
+ if (!VxeUIFormComponent) {
31032
+ errLog('vxe.error.reqComp', ['vxe-form']);
31033
+ }
31034
+ }
31035
+ if (props.pagerConfig) {
31036
+ if (!VxeUIPagerComponent) {
31037
+ errLog('vxe.error.reqComp', ['vxe-pager']);
31038
+ }
31039
+ }
31027
31040
  // const { data, columns, proxyConfig } = props
31028
31041
  // const proxyOpts = computeProxyOpts.value
31029
31042
  // const formOpts = computeFormOpts.value
31030
31043
  // if (isEnableConf(proxyConfig) && (data || (proxyOpts.form && formOpts.data))) {
31031
31044
  // errLog('vxe.error.errConflicts', ['grid.data', 'grid.proxy-config'])
31032
31045
  // }
31033
- // if (process.env.VUE_APP_VXE_ENV === 'development') {
31034
31046
  // if (proxyOpts.props) {
31035
31047
  // warnLog('vxe.error.delProp', ['proxy-config.props', 'proxy-config.response'])
31036
31048
  // }
31037
- // }
31038
31049
  if (columns && columns.length) {
31039
31050
  $xeGrid.loadColumn(columns);
31040
31051
  }