vxe-table 4.13.5 → 4.13.6

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 (174) hide show
  1. package/es/grid/src/grid.js +1 -1
  2. package/es/index.css +1 -1
  3. package/es/index.min.css +1 -1
  4. package/es/locale/lang/ar-EG.js +3 -2
  5. package/es/locale/lang/de-DE.js +3 -2
  6. package/es/locale/lang/en-US.js +2 -1
  7. package/es/locale/lang/es-ES.js +3 -2
  8. package/es/locale/lang/fr-FR.js +2 -1
  9. package/es/locale/lang/hu-HU.js +2 -1
  10. package/es/locale/lang/hy-AM.js +2 -1
  11. package/es/locale/lang/id-ID.js +2 -1
  12. package/es/locale/lang/it-IT.js +2 -1
  13. package/es/locale/lang/ja-JP.js +2 -1
  14. package/es/locale/lang/ko-KR.js +2 -1
  15. package/es/locale/lang/nb-NO.js +2 -1
  16. package/es/locale/lang/pt-BR.js +2 -1
  17. package/es/locale/lang/ru-RU.js +2 -1
  18. package/es/locale/lang/th-TH.js +2 -1
  19. package/es/locale/lang/ug-CN.js +2 -1
  20. package/es/locale/lang/uk-UA.js +2 -1
  21. package/es/locale/lang/vi-VN.js +2 -1
  22. package/es/locale/lang/zh-CHT.js +2 -1
  23. package/es/locale/lang/zh-CN.js +2 -1
  24. package/es/style.css +1 -1
  25. package/es/style.min.css +1 -1
  26. package/es/table/module/custom/hook.js +11 -8
  27. package/es/table/module/custom/panel.js +7 -7
  28. package/es/table/module/export/hook.js +21 -20
  29. package/es/table/module/keyboard/hook.js +3 -2
  30. package/es/table/src/body.js +45 -10
  31. package/es/table/src/cell.js +159 -69
  32. package/es/table/src/column.js +2 -0
  33. package/es/table/src/columnInfo.js +1 -0
  34. package/es/table/src/emits.js +1 -0
  35. package/es/table/src/props.js +9 -7
  36. package/es/table/src/table.js +653 -171
  37. package/es/table/style.css +70 -40
  38. package/es/table/style.min.css +1 -1
  39. package/es/ui/index.js +13 -1
  40. package/es/ui/src/dom.js +3 -0
  41. package/es/ui/src/log.js +1 -1
  42. package/es/vxe-table/style.css +70 -40
  43. package/es/vxe-table/style.min.css +1 -1
  44. package/lib/grid/src/grid.js +1 -1
  45. package/lib/grid/src/grid.min.js +1 -1
  46. package/lib/index.css +1 -1
  47. package/lib/index.min.css +1 -1
  48. package/lib/index.umd.js +419 -179
  49. package/lib/index.umd.min.js +1 -1
  50. package/lib/locale/lang/ar-EG.js +3 -2
  51. package/lib/locale/lang/ar-EG.min.js +1 -1
  52. package/lib/locale/lang/de-DE.js +3 -2
  53. package/lib/locale/lang/de-DE.min.js +1 -1
  54. package/lib/locale/lang/en-US.js +2 -1
  55. package/lib/locale/lang/en-US.min.js +1 -1
  56. package/lib/locale/lang/en-US.umd.js +2 -1
  57. package/lib/locale/lang/es-ES.js +3 -2
  58. package/lib/locale/lang/es-ES.min.js +1 -1
  59. package/lib/locale/lang/es-ES.umd.js +3 -2
  60. package/lib/locale/lang/fr-FR.js +2 -1
  61. package/lib/locale/lang/fr-FR.min.js +1 -1
  62. package/lib/locale/lang/hu-HU.js +2 -1
  63. package/lib/locale/lang/hu-HU.min.js +1 -1
  64. package/lib/locale/lang/hu-HU.umd.js +2 -1
  65. package/lib/locale/lang/hy-AM.js +2 -1
  66. package/lib/locale/lang/hy-AM.min.js +1 -1
  67. package/lib/locale/lang/id-ID.js +2 -1
  68. package/lib/locale/lang/id-ID.min.js +1 -1
  69. package/lib/locale/lang/it-IT.js +2 -1
  70. package/lib/locale/lang/it-IT.min.js +1 -1
  71. package/lib/locale/lang/ja-JP.js +2 -1
  72. package/lib/locale/lang/ja-JP.min.js +1 -1
  73. package/lib/locale/lang/ja-JP.umd.js +2 -1
  74. package/lib/locale/lang/ko-KR.js +2 -1
  75. package/lib/locale/lang/ko-KR.min.js +1 -1
  76. package/lib/locale/lang/ko-KR.umd.js +2 -1
  77. package/lib/locale/lang/nb-NO.js +2 -1
  78. package/lib/locale/lang/nb-NO.min.js +1 -1
  79. package/lib/locale/lang/pt-BR.js +2 -1
  80. package/lib/locale/lang/pt-BR.min.js +1 -1
  81. package/lib/locale/lang/pt-BR.umd.js +2 -1
  82. package/lib/locale/lang/ru-RU.js +2 -1
  83. package/lib/locale/lang/ru-RU.min.js +1 -1
  84. package/lib/locale/lang/ru-RU.umd.js +2 -1
  85. package/lib/locale/lang/th-TH.js +2 -1
  86. package/lib/locale/lang/th-TH.min.js +1 -1
  87. package/lib/locale/lang/ug-CN.js +2 -1
  88. package/lib/locale/lang/ug-CN.min.js +1 -1
  89. package/lib/locale/lang/uk-UA.js +2 -1
  90. package/lib/locale/lang/uk-UA.min.js +1 -1
  91. package/lib/locale/lang/uk-UA.umd.js +2 -1
  92. package/lib/locale/lang/vi-VN.js +2 -1
  93. package/lib/locale/lang/vi-VN.min.js +1 -1
  94. package/lib/locale/lang/zh-CHT.js +2 -1
  95. package/lib/locale/lang/zh-CHT.min.js +1 -1
  96. package/lib/locale/lang/zh-CN.js +2 -1
  97. package/lib/locale/lang/zh-CN.min.js +1 -1
  98. package/lib/locale/lang/zh-CN.umd.js +2 -1
  99. package/lib/style.css +1 -1
  100. package/lib/style.min.css +1 -1
  101. package/lib/table/module/custom/hook.js +11 -1
  102. package/lib/table/module/custom/hook.min.js +1 -1
  103. package/lib/table/module/custom/panel.js +6 -2
  104. package/lib/table/module/custom/panel.min.js +1 -1
  105. package/lib/table/module/export/hook.js +21 -11
  106. package/lib/table/module/export/hook.min.js +1 -1
  107. package/lib/table/module/keyboard/hook.js +2 -1
  108. package/lib/table/module/keyboard/hook.min.js +1 -1
  109. package/lib/table/src/body.js +35 -9
  110. package/lib/table/src/body.min.js +1 -1
  111. package/lib/table/src/cell.js +177 -52
  112. package/lib/table/src/cell.min.js +1 -1
  113. package/lib/table/src/column.js +2 -0
  114. package/lib/table/src/column.min.js +1 -1
  115. package/lib/table/src/columnInfo.js +1 -0
  116. package/lib/table/src/columnInfo.min.js +1 -1
  117. package/lib/table/src/emits.js +1 -1
  118. package/lib/table/src/emits.min.js +1 -1
  119. package/lib/table/src/props.js +9 -7
  120. package/lib/table/src/props.min.js +1 -1
  121. package/lib/table/src/table.js +134 -91
  122. package/lib/table/src/table.min.js +1 -1
  123. package/lib/table/style/style.css +70 -40
  124. package/lib/table/style/style.min.css +1 -1
  125. package/lib/ui/index.js +13 -1
  126. package/lib/ui/index.min.js +1 -1
  127. package/lib/ui/src/dom.js +4 -0
  128. package/lib/ui/src/dom.min.js +1 -1
  129. package/lib/ui/src/log.js +1 -1
  130. package/lib/ui/src/log.min.js +1 -1
  131. package/lib/vxe-table/style/style.css +70 -40
  132. package/lib/vxe-table/style/style.min.css +1 -1
  133. package/package.json +2 -2
  134. package/packages/grid/src/grid.ts +1 -1
  135. package/packages/locale/lang/ar-EG.ts +3 -2
  136. package/packages/locale/lang/de-DE.ts +3 -2
  137. package/packages/locale/lang/en-US.ts +2 -1
  138. package/packages/locale/lang/es-ES.ts +3 -2
  139. package/packages/locale/lang/fr-FR.ts +2 -1
  140. package/packages/locale/lang/hu-HU.ts +2 -1
  141. package/packages/locale/lang/hy-AM.ts +2 -1
  142. package/packages/locale/lang/id-ID.ts +2 -1
  143. package/packages/locale/lang/it-IT.ts +2 -1
  144. package/packages/locale/lang/ja-JP.ts +2 -1
  145. package/packages/locale/lang/ko-KR.ts +2 -1
  146. package/packages/locale/lang/nb-NO.ts +2 -1
  147. package/packages/locale/lang/pt-BR.ts +2 -1
  148. package/packages/locale/lang/ru-RU.ts +2 -1
  149. package/packages/locale/lang/th-TH.ts +2 -1
  150. package/packages/locale/lang/ug-CN.ts +2 -1
  151. package/packages/locale/lang/uk-UA.ts +2 -1
  152. package/packages/locale/lang/vi-VN.ts +2 -1
  153. package/packages/locale/lang/zh-CHT.ts +2 -1
  154. package/packages/locale/lang/zh-CN.ts +2 -1
  155. package/packages/table/module/custom/hook.ts +14 -8
  156. package/packages/table/module/custom/panel.ts +7 -7
  157. package/packages/table/module/export/hook.ts +28 -27
  158. package/packages/table/module/keyboard/hook.ts +3 -2
  159. package/packages/table/src/body.ts +46 -10
  160. package/packages/table/src/cell.ts +162 -73
  161. package/packages/table/src/column.ts +2 -0
  162. package/packages/table/src/columnInfo.ts +1 -0
  163. package/packages/table/src/emits.ts +1 -0
  164. package/packages/table/src/props.ts +9 -7
  165. package/packages/table/src/table.ts +658 -176
  166. package/packages/ui/index.ts +12 -0
  167. package/packages/ui/src/dom.ts +4 -0
  168. package/styles/components/table.scss +131 -92
  169. /package/es/{iconfont.1744880866629.ttf → iconfont.1745197925862.ttf} +0 -0
  170. /package/es/{iconfont.1744880866629.woff → iconfont.1745197925862.woff} +0 -0
  171. /package/es/{iconfont.1744880866629.woff2 → iconfont.1745197925862.woff2} +0 -0
  172. /package/lib/{iconfont.1744880866629.ttf → iconfont.1745197925862.ttf} +0 -0
  173. /package/lib/{iconfont.1744880866629.woff → iconfont.1745197925862.woff} +0 -0
  174. /package/lib/{iconfont.1744880866629.woff2 → iconfont.1745197925862.woff2} +0 -0
@@ -81,18 +81,18 @@ function renderCellBaseVNs(params, content) {
81
81
  const treeOpts = computeTreeOpts.value;
82
82
  const { showIcon, isPeerDrag, isCrossDrag, visibleMethod } = rowDragOpts;
83
83
  const rVisibleMethod = visibleMethod || (dragConfig ? dragConfig.rowVisibleMethod : null);
84
- const vns = XEUtils.isArray(content) ? content : [content];
84
+ const vns = [];
85
85
  if (dragSort && rowOpts.drag && ((showIcon || (dragConfig ? dragConfig.showRowIcon : false)) && (!rVisibleMethod || rVisibleMethod(params)))) {
86
86
  if (treeConfig) {
87
87
  if (treeOpts.transform && (isPeerDrag || isCrossDrag || !level)) {
88
- vns.unshift(renderCellDragIcon(params));
88
+ vns.push(renderCellDragIcon(params));
89
89
  }
90
90
  }
91
91
  else {
92
- vns.unshift(renderCellDragIcon(params));
92
+ vns.push(renderCellDragIcon(params));
93
93
  }
94
94
  }
95
- return vns;
95
+ return vns.concat(XEUtils.isArray(content) ? content : [content]);
96
96
  }
97
97
  function renderHeaderCellDragIcon(params) {
98
98
  const { $table, column } = params;
@@ -246,26 +246,27 @@ function renderCellHandle(params) {
246
246
  const { column, $table } = params;
247
247
  const tableProps = $table.props;
248
248
  const { editConfig } = tableProps;
249
- const { type, treeNode, editRender } = column;
249
+ const { type, treeNode, rowGroupNode, editRender } = column;
250
250
  const { computeEditOpts, computeCheckboxOpts } = $table.getComputeMaps();
251
251
  const checkboxOpts = computeCheckboxOpts.value;
252
252
  const editOpts = computeEditOpts.value;
253
+ const isDeepCell = treeNode || rowGroupNode;
253
254
  switch (type) {
254
255
  case 'seq':
255
- return treeNode ? Cell.renderTreeIndexCell(params) : Cell.renderSeqCell(params);
256
+ return isDeepCell ? Cell.renderDeepIndexCell(params) : Cell.renderSeqCell(params);
256
257
  case 'radio':
257
- return treeNode ? Cell.renderTreeRadioCell(params) : Cell.renderRadioCell(params);
258
+ return isDeepCell ? Cell.renderDeepRadioCell(params) : Cell.renderRadioCell(params);
258
259
  case 'checkbox':
259
- return checkboxOpts.checkField ? (treeNode ? Cell.renderTreeSelectionCellByProp(params) : Cell.renderCheckboxCellByProp(params)) : (treeNode ? Cell.renderTreeSelectionCell(params) : Cell.renderCheckboxCell(params));
260
+ return checkboxOpts.checkField ? (isDeepCell ? Cell.renderDeepSelectionCellByProp(params) : Cell.renderCheckboxCellByProp(params)) : (isDeepCell ? Cell.renderDeepSelectionCell(params) : Cell.renderCheckboxCell(params));
260
261
  case 'expand':
261
262
  return Cell.renderExpandCell(params);
262
263
  case 'html':
263
- return treeNode ? Cell.renderTreeHTMLCell(params) : Cell.renderHTMLCell(params);
264
+ return isDeepCell ? Cell.renderDeepHTMLCell(params) : Cell.renderHTMLCell(params);
264
265
  }
265
266
  if (isEnableConf(editConfig) && editRender) {
266
- return editOpts.mode === 'cell' ? (treeNode ? Cell.renderTreeCellEdit(params) : Cell.renderCellEdit(params)) : (treeNode ? Cell.renderTreeRowEdit(params) : Cell.renderRowEdit(params));
267
+ return editOpts.mode === 'cell' ? (isDeepCell ? Cell.renderDeepCellEdit(params) : Cell.renderCellEdit(params)) : (isDeepCell ? Cell.renderDeepRowEdit(params) : Cell.renderRowEdit(params));
267
268
  }
268
- return treeNode ? Cell.renderTreeCell(params) : Cell.renderDefaultCell(params);
269
+ return isDeepCell ? Cell.renderDeepCell(params) : Cell.renderDefaultCell(params);
269
270
  }
270
271
  function renderHeaderHandle(params) {
271
272
  const { column, $table } = params;
@@ -348,7 +349,10 @@ export const Cell = {
348
349
  },
349
350
  renderDefaultCell(params) {
350
351
  const { $table, row, column } = params;
351
- const { slots, editRender, cellRender } = column;
352
+ const tableReactData = $table.reactData;
353
+ const tableInternalData = $table.internalData;
354
+ const { isRowGroupStatus } = tableReactData;
355
+ const { slots, editRender, cellRender, rowGroupNode } = column;
352
356
  const renderOpts = editRender || cellRender;
353
357
  const defaultSlot = slots ? slots.default : null;
354
358
  if (defaultSlot) {
@@ -365,7 +369,36 @@ export const Cell = {
365
369
  }
366
370
  }
367
371
  }
368
- const cellValue = $table.getCellLabel(row, column);
372
+ let cellValue = '';
373
+ if (isRowGroupStatus && rowGroupNode && row.isAggregate) {
374
+ const { fullColumnFieldData } = tableInternalData;
375
+ const { computeRowGroupOpts } = $table.getComputeMaps();
376
+ const rowGroupOpts = computeRowGroupOpts.value;
377
+ const { showTotal, totalMethod, contentMethod, mapChildrenField } = rowGroupOpts;
378
+ const groupField = row.groupField;
379
+ cellValue = row.groupContent;
380
+ const childList = mapChildrenField ? (row[mapChildrenField] || []) : [];
381
+ const totalValue = childList.length;
382
+ const colRest = fullColumnFieldData[groupField] || {};
383
+ const params = {
384
+ $table,
385
+ groupField,
386
+ groupColumn: (colRest ? colRest.column : null),
387
+ column,
388
+ groupValue: cellValue,
389
+ children: childList,
390
+ totalValue: totalValue
391
+ };
392
+ if (contentMethod) {
393
+ cellValue = `${contentMethod(params)}`;
394
+ }
395
+ if (showTotal) {
396
+ cellValue = getI18n('vxe.table.rowGroupContentTotal', [cellValue, totalMethod ? totalMethod(params) : totalValue, totalValue]);
397
+ }
398
+ }
399
+ else if (!(isRowGroupStatus && row.isAggregate)) {
400
+ cellValue = $table.getCellLabel(row, column);
401
+ }
369
402
  const cellPlaceholder = editRender ? editRender.placeholder : '';
370
403
  return renderCellBaseVNs(params, [
371
404
  h('span', {
@@ -380,39 +413,79 @@ export const Cell = {
380
413
  ])
381
414
  ]);
382
415
  },
383
- renderTreeCell(params) {
384
- return Cell.renderTreeIcon(params, Cell.renderDefaultCell(params));
416
+ renderDeepCell(params) {
417
+ return Cell.renderDeepNodeBtn(params, Cell.renderDefaultCell(params));
385
418
  },
386
419
  renderDefaultFooter(params) {
387
420
  return getFooterContent(params);
388
421
  },
389
422
  /**
390
- * 树节点
423
+ * 行分组
391
424
  */
392
- renderTreeIcon(params, cellVNodes) {
425
+ renderRowGroupBtn(params, cellVNodes) {
426
+ const { $table } = params;
427
+ const tableReactData = $table.reactData;
428
+ const tableInternalData = $table.internalData;
429
+ const { row, level } = params;
430
+ const { computeRowGroupOpts } = $table.getComputeMaps();
431
+ const { rowGroupExpandedFlag } = tableReactData;
432
+ const { rowGroupExpandedMaps } = tableInternalData;
433
+ const rowGroupOpts = computeRowGroupOpts.value;
434
+ const { padding, indent } = rowGroupOpts;
435
+ const rowid = getRowid($table, row);
436
+ const isExpand = !!rowGroupExpandedFlag && !!rowGroupExpandedMaps[rowid];
437
+ return h('div', {
438
+ class: ['vxe-row-group--tree-node', {
439
+ 'is--expanded': isExpand
440
+ }],
441
+ style: padding && indent
442
+ ? {
443
+ paddingLeft: `${level * indent}px`
444
+ }
445
+ : undefined
446
+ }, [
447
+ h('span', {
448
+ class: 'vxe-row-group--node-btn',
449
+ onClick(evnt) {
450
+ $table.triggerRowGroupExpandEvent(evnt, params);
451
+ }
452
+ }, [
453
+ h('i', {
454
+ class: isExpand ? getIcon().TABLE_ROW_GROUP_OPEN : getIcon().TABLE_ROW_GROUP_CLOSE
455
+ })
456
+ ]),
457
+ h('div', {
458
+ class: 'vxe-row-group-cell'
459
+ }, cellVNodes)
460
+ ]);
461
+ },
462
+ /**
463
+ * 树
464
+ */
465
+ renderTreeNodeBtn(params, cellVNodes) {
393
466
  const { $table, isHidden } = params;
394
467
  const tableReactData = $table.reactData;
395
468
  const tableInternalData = $table.internalData;
469
+ const { row, column, level } = params;
470
+ const { slots } = column;
471
+ const iconSlot = slots ? slots.icon : null;
472
+ if (iconSlot) {
473
+ return $table.callSlot(iconSlot, params);
474
+ }
396
475
  const { computeTreeOpts } = $table.getComputeMaps();
397
476
  const { treeExpandedFlag } = tableReactData;
398
477
  const { fullAllDataRowIdData, treeExpandedMaps, treeExpandLazyLoadedMaps } = tableInternalData;
399
478
  const treeOpts = computeTreeOpts.value;
400
- const { row, column, level } = params;
401
- const { slots } = column;
402
- const { indent, lazy, trigger, iconLoaded, showIcon, iconOpen, iconClose } = treeOpts;
479
+ const { padding, indent, lazy, trigger, iconLoaded, showIcon, iconOpen, iconClose } = treeOpts;
403
480
  const childrenField = treeOpts.children || treeOpts.childrenField;
404
481
  const hasChildField = treeOpts.hasChild || treeOpts.hasChildField;
405
482
  const rowChilds = row[childrenField];
406
483
  const hasChild = rowChilds && rowChilds.length;
407
- const iconSlot = slots ? slots.icon : null;
408
484
  let hasLazyChilds = false;
409
485
  let isActive = false;
410
486
  let isLazyLoading = false;
411
487
  let isLazyLoaded = false;
412
488
  const ons = {};
413
- if (iconSlot) {
414
- return $table.callSlot(iconSlot, params);
415
- }
416
489
  if (!isHidden) {
417
490
  const rowid = getRowid($table, row);
418
491
  isActive = !!treeExpandedFlag && !!treeExpandedMaps[rowid];
@@ -428,29 +501,41 @@ export const Cell = {
428
501
  $table.triggerTreeExpandEvent(evnt, params);
429
502
  };
430
503
  }
431
- return [
432
- h('div', {
433
- class: ['vxe-cell--tree-node', {
434
- 'is--active': isActive
435
- }],
436
- style: {
504
+ return h('div', {
505
+ class: ['vxe-cell--tree-node', {
506
+ 'is--active': isActive
507
+ }],
508
+ style: padding && indent
509
+ ? {
437
510
  paddingLeft: `${level * indent}px`
438
511
  }
439
- }, [
440
- showIcon && (lazy ? (isLazyLoaded ? hasChild : (hasChild || hasLazyChilds)) : hasChild)
441
- ? [
442
- h('div', Object.assign({ class: 'vxe-tree--btn-wrapper' }, ons), [
443
- h('i', {
444
- class: ['vxe-tree--node-btn', isLazyLoading ? (iconLoaded || getIcon().TABLE_TREE_LOADED) : (isActive ? (iconOpen || getIcon().TABLE_TREE_OPEN) : (iconClose || getIcon().TABLE_TREE_CLOSE))]
445
- })
446
- ])
447
- ]
448
- : null,
449
- h('div', {
450
- class: 'vxe-tree-cell'
451
- }, cellVNodes)
452
- ])
453
- ];
512
+ : undefined
513
+ }, [
514
+ showIcon && (lazy ? (isLazyLoaded ? hasChild : (hasChild || hasLazyChilds)) : hasChild)
515
+ ? [
516
+ h('div', Object.assign({ class: 'vxe-cell--tree-btn' }, ons), [
517
+ h('i', {
518
+ class: isLazyLoading ? (iconLoaded || getIcon().TABLE_TREE_LOADED) : (isActive ? (iconOpen || getIcon().TABLE_TREE_OPEN) : (iconClose || getIcon().TABLE_TREE_CLOSE))
519
+ })
520
+ ])
521
+ ]
522
+ : null,
523
+ h('div', {
524
+ class: 'vxe-tree-cell'
525
+ }, cellVNodes)
526
+ ]);
527
+ },
528
+ /**
529
+ * 层级节点。
530
+ * 行分组、树结构
531
+ */
532
+ renderDeepNodeBtn(params, cellVNodes) {
533
+ const { row, column } = params;
534
+ const { rowGroupNode } = column;
535
+ if (rowGroupNode && row.isAggregate) {
536
+ return [Cell.renderRowGroupBtn(params, cellVNodes)];
537
+ }
538
+ return [Cell.renderTreeNodeBtn(params, cellVNodes)];
454
539
  },
455
540
  /**
456
541
  * 序号
@@ -478,8 +563,8 @@ export const Cell = {
478
563
  h('span', `${formatText(seqMethod ? seqMethod(params) : treeConfig ? seq : (seqOpts.startIndex || 0) + seq, 1)}`)
479
564
  ]);
480
565
  },
481
- renderTreeIndexCell(params) {
482
- return Cell.renderTreeIcon(params, Cell.renderSeqCell(params));
566
+ renderDeepIndexCell(params) {
567
+ return Cell.renderDeepNodeBtn(params, Cell.renderSeqCell(params));
483
568
  },
484
569
  /**
485
570
  * 单选
@@ -509,7 +594,7 @@ export const Cell = {
509
594
  const defaultSlot = slots ? slots.default : null;
510
595
  const radioSlot = slots ? slots.radio : null;
511
596
  const isChecked = $table.eqRow(row, selectRadioRow);
512
- const isVisible = !visibleMethod || visibleMethod({ row });
597
+ const isVisible = !visibleMethod || visibleMethod({ $table, row });
513
598
  let isDisabled = !!checkMethod;
514
599
  let ons;
515
600
  if (!isHidden) {
@@ -521,7 +606,7 @@ export const Cell = {
521
606
  }
522
607
  };
523
608
  if (checkMethod) {
524
- isDisabled = !checkMethod({ row });
609
+ isDisabled = !checkMethod({ $table, row });
525
610
  }
526
611
  }
527
612
  const radioParams = Object.assign(Object.assign({}, params), { checked: isChecked, disabled: isDisabled, visible: isVisible });
@@ -546,8 +631,8 @@ export const Cell = {
546
631
  }] }, ons), radioVNs)
547
632
  ]);
548
633
  },
549
- renderTreeRadioCell(params) {
550
- return Cell.renderTreeIcon(params, Cell.renderRadioCell(params));
634
+ renderDeepRadioCell(params) {
635
+ return Cell.renderDeepNodeBtn(params, Cell.renderRadioCell(params));
551
636
  },
552
637
  /**
553
638
  * 多选
@@ -607,7 +692,7 @@ export const Cell = {
607
692
  const tableReactData = $table.reactData;
608
693
  const tableInternalData = $table.internalData;
609
694
  const { treeConfig } = tableProps;
610
- const { updateCheckboxFlag } = tableReactData;
695
+ const { updateCheckboxFlag, isRowGroupStatus } = tableReactData;
611
696
  const { selectCheckboxMaps, treeIndeterminateRowMaps } = tableInternalData;
612
697
  const { computeCheckboxOpts } = $table.getComputeMaps();
613
698
  const checkboxOpts = computeCheckboxOpts.value;
@@ -617,7 +702,7 @@ export const Cell = {
617
702
  const checkboxSlot = slots ? slots.checkbox : null;
618
703
  let indeterminate = false;
619
704
  let isChecked = false;
620
- const isVisible = !visibleMethod || visibleMethod({ row });
705
+ const isVisible = !visibleMethod || visibleMethod({ $table, row });
621
706
  let isDisabled = !!checkMethod;
622
707
  const ons = {};
623
708
  if (!isHidden) {
@@ -629,9 +714,9 @@ export const Cell = {
629
714
  }
630
715
  };
631
716
  if (checkMethod) {
632
- isDisabled = !checkMethod({ row });
717
+ isDisabled = !checkMethod({ $table, row });
633
718
  }
634
- if (treeConfig) {
719
+ if (treeConfig || isRowGroupStatus) {
635
720
  indeterminate = !!treeIndeterminateRowMaps[rowid];
636
721
  }
637
722
  }
@@ -659,8 +744,8 @@ export const Cell = {
659
744
  }] }, ons), checkVNs)
660
745
  ]);
661
746
  },
662
- renderTreeSelectionCell(params) {
663
- return Cell.renderTreeIcon(params, Cell.renderCheckboxCell(params));
747
+ renderDeepSelectionCell(params) {
748
+ return Cell.renderDeepNodeBtn(params, Cell.renderCheckboxCell(params));
664
749
  },
665
750
  renderCheckboxCellByProp(params) {
666
751
  const { $table, row, column, isHidden } = params;
@@ -668,7 +753,7 @@ export const Cell = {
668
753
  const tableReactData = $table.reactData;
669
754
  const tableInternalData = $table.internalData;
670
755
  const { treeConfig } = tableProps;
671
- const { updateCheckboxFlag } = tableReactData;
756
+ const { updateCheckboxFlag, isRowGroupStatus } = tableReactData;
672
757
  const { treeIndeterminateRowMaps } = tableInternalData;
673
758
  const { computeCheckboxOpts } = $table.getComputeMaps();
674
759
  const checkboxOpts = computeCheckboxOpts.value;
@@ -679,7 +764,7 @@ export const Cell = {
679
764
  const checkboxSlot = slots ? slots.checkbox : null;
680
765
  let isIndeterminate = false;
681
766
  let isChecked = false;
682
- const isVisible = !visibleMethod || visibleMethod({ row });
767
+ const isVisible = !visibleMethod || visibleMethod({ $table, row });
683
768
  let isDisabled = !!checkMethod;
684
769
  const ons = {};
685
770
  if (!isHidden) {
@@ -691,9 +776,9 @@ export const Cell = {
691
776
  }
692
777
  };
693
778
  if (checkMethod) {
694
- isDisabled = !checkMethod({ row });
779
+ isDisabled = !checkMethod({ $table, row });
695
780
  }
696
- if (treeConfig) {
781
+ if (treeConfig || isRowGroupStatus) {
697
782
  isIndeterminate = !!treeIndeterminateRowMaps[rowid];
698
783
  }
699
784
  }
@@ -721,15 +806,17 @@ export const Cell = {
721
806
  }] }, ons), checkVNs)
722
807
  ]);
723
808
  },
724
- renderTreeSelectionCellByProp(params) {
725
- return Cell.renderTreeIcon(params, Cell.renderCheckboxCellByProp(params));
809
+ renderDeepSelectionCellByProp(params) {
810
+ return Cell.renderDeepNodeBtn(params, Cell.renderCheckboxCellByProp(params));
726
811
  },
727
812
  /**
728
813
  * 展开行
729
814
  */
730
815
  renderExpandCell(params) {
731
816
  const { $table, isHidden, row, column } = params;
817
+ const tableReactData = $table.reactData;
732
818
  const tableInternalData = $table.internalData;
819
+ const { isRowGroupStatus } = tableReactData;
733
820
  const { rowExpandedMaps, rowExpandLazyLoadedMaps } = tableInternalData;
734
821
  const { computeExpandOpts } = $table.getComputeMaps();
735
822
  const expandOpts = computeExpandOpts.value;
@@ -739,6 +826,9 @@ export const Cell = {
739
826
  const iconSlot = slots ? slots.icon : null;
740
827
  let isActive = false;
741
828
  let isLazyLoading = false;
829
+ if (isRowGroupStatus && row.isAggregate) {
830
+ return renderCellBaseVNs(params, []);
831
+ }
742
832
  if (iconSlot) {
743
833
  return renderCellBaseVNs(params, $table.callSlot(iconSlot, params));
744
834
  }
@@ -809,8 +899,8 @@ export const Cell = {
809
899
  })
810
900
  ]);
811
901
  },
812
- renderTreeHTMLCell(params) {
813
- return Cell.renderTreeIcon(params, Cell.renderHTMLCell(params));
902
+ renderDeepHTMLCell(params) {
903
+ return Cell.renderDeepNodeBtn(params, Cell.renderHTMLCell(params));
814
904
  },
815
905
  /**
816
906
  * 排序和筛选
@@ -943,8 +1033,8 @@ export const Cell = {
943
1033
  const { editRender } = column;
944
1034
  return Cell.runRenderer(params, isEnableConf(editRender) && actived && actived.row === params.row);
945
1035
  },
946
- renderTreeRowEdit(params) {
947
- return Cell.renderTreeIcon(params, Cell.renderRowEdit(params));
1036
+ renderDeepRowEdit(params) {
1037
+ return Cell.renderDeepNodeBtn(params, Cell.renderRowEdit(params));
948
1038
  },
949
1039
  // 单元格编辑模式
950
1040
  renderCellEdit(params) {
@@ -955,8 +1045,8 @@ export const Cell = {
955
1045
  const { editRender } = column;
956
1046
  return Cell.runRenderer(params, isEnableConf(editRender) && actived && actived.row === params.row && actived.column === params.column);
957
1047
  },
958
- renderTreeCellEdit(params) {
959
- return Cell.renderTreeIcon(params, Cell.renderCellEdit(params));
1048
+ renderDeepCellEdit(params) {
1049
+ return Cell.renderDeepNodeBtn(params, Cell.renderCellEdit(params));
960
1050
  },
961
1051
  runRenderer(params, isEdit) {
962
1052
  const { $table, column } = params;
@@ -88,6 +88,8 @@ export const columnProps = {
88
88
  filterRecoverMethod: Function,
89
89
  // 筛选模板配置项
90
90
  filterRender: Object,
91
+ // 设置为分组节点
92
+ rowGroupNode: Boolean,
91
93
  // 设置为树节点
92
94
  treeNode: Boolean,
93
95
  // 设置为拖拽排序
@@ -76,6 +76,7 @@ export class ColumnInfo {
76
76
  filterResetMethod: _vm.filterResetMethod,
77
77
  filterRecoverMethod: _vm.filterRecoverMethod,
78
78
  filterRender: _vm.filterRender,
79
+ rowGroupNode: _vm.rowGroupNode,
79
80
  treeNode: _vm.treeNode,
80
81
  dragSort: _vm.dragSort,
81
82
  rowResize: _vm.rowResize,
@@ -41,6 +41,7 @@ export default [
41
41
  'resizable-change',
42
42
  'column-resizable-change',
43
43
  'row-resizable-change',
44
+ 'toggle-row-group-expand',
44
45
  'toggle-row-expand',
45
46
  'toggle-tree-expand',
46
47
  'menu-click',
@@ -180,19 +180,21 @@ export default {
180
180
  syncResize: [Boolean, String, Number],
181
181
  // 响应式布局配置项
182
182
  resizeConfig: Object,
183
- // 列配置信息
183
+ // 列配置项
184
184
  columnConfig: Object,
185
- // 当前列配置信息
185
+ // 当前列配置项
186
186
  currentColumnConfig: Object,
187
- // 单元格配置信息
187
+ // 单元格配置项
188
188
  cellConfig: Object,
189
- // 表头单元格配置信息
189
+ // 表头单元格配置项
190
190
  headerCellConfig: Object,
191
- // 表尾单元格配置信息
191
+ // 表尾单元格配置项
192
192
  footerCellConfig: Object,
193
- // 行配置信息
193
+ // 行配置项
194
194
  rowConfig: Object,
195
- // 当前行配置信息
195
+ // 行分组配置项
196
+ rowGroupConfig: Object,
197
+ // 当前行配置项
196
198
  currentRowConfig: Object,
197
199
  // 已废弃,被 rowDragConfig 替换
198
200
  dragConfig: Object,