vxe-table 4.13.45 → 4.13.46
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/es/locale/lang/ar-EG.js +5 -1
- package/es/locale/lang/de-DE.js +5 -1
- package/es/locale/lang/en-US.js +5 -1
- package/es/locale/lang/es-ES.js +5 -1
- package/es/locale/lang/fr-FR.js +5 -1
- package/es/locale/lang/hu-HU.js +5 -1
- package/es/locale/lang/hy-AM.js +5 -1
- package/es/locale/lang/id-ID.js +5 -1
- package/es/locale/lang/it-IT.js +5 -1
- package/es/locale/lang/ja-JP.js +5 -1
- package/es/locale/lang/ko-KR.js +5 -1
- package/es/locale/lang/ms-MY.js +5 -1
- package/es/locale/lang/nb-NO.js +5 -1
- package/es/locale/lang/pt-BR.js +5 -1
- package/es/locale/lang/ru-RU.js +5 -1
- package/es/locale/lang/th-TH.js +5 -1
- package/es/locale/lang/ug-CN.js +5 -1
- package/es/locale/lang/uk-UA.js +5 -1
- package/es/locale/lang/uz-UZ.js +5 -1
- package/es/locale/lang/vi-VN.js +5 -1
- package/es/locale/lang/zh-CHT.js +6 -2
- package/es/locale/lang/zh-CN.js +5 -1
- package/es/style.css +1 -1
- package/es/table/module/custom/panel.js +11 -11
- package/es/table/src/table.js +25 -4
- package/es/ui/index.js +4 -2
- package/es/ui/src/log.js +1 -1
- package/lib/index.umd.js +25 -19
- package/lib/index.umd.min.js +1 -1
- package/lib/locale/lang/ar-EG.js +5 -1
- package/lib/locale/lang/ar-EG.min.js +1 -1
- package/lib/locale/lang/ar-EG.umd.js +5 -1
- package/lib/locale/lang/de-DE.js +5 -1
- package/lib/locale/lang/de-DE.min.js +1 -1
- package/lib/locale/lang/de-DE.umd.js +5 -1
- package/lib/locale/lang/en-US.js +5 -1
- package/lib/locale/lang/en-US.min.js +1 -1
- package/lib/locale/lang/en-US.umd.js +5 -1
- package/lib/locale/lang/es-ES.js +5 -1
- package/lib/locale/lang/es-ES.min.js +1 -1
- package/lib/locale/lang/es-ES.umd.js +5 -1
- package/lib/locale/lang/fr-FR.js +5 -1
- package/lib/locale/lang/fr-FR.min.js +1 -1
- package/lib/locale/lang/fr-FR.umd.js +5 -1
- package/lib/locale/lang/hu-HU.js +5 -1
- package/lib/locale/lang/hu-HU.min.js +1 -1
- package/lib/locale/lang/hu-HU.umd.js +5 -1
- package/lib/locale/lang/hy-AM.js +5 -1
- package/lib/locale/lang/hy-AM.min.js +1 -1
- package/lib/locale/lang/hy-AM.umd.js +5 -1
- package/lib/locale/lang/id-ID.js +5 -1
- package/lib/locale/lang/id-ID.min.js +1 -1
- package/lib/locale/lang/id-ID.umd.js +5 -1
- package/lib/locale/lang/it-IT.js +5 -1
- package/lib/locale/lang/it-IT.min.js +1 -1
- package/lib/locale/lang/it-IT.umd.js +5 -1
- package/lib/locale/lang/ja-JP.js +5 -1
- package/lib/locale/lang/ja-JP.min.js +1 -1
- package/lib/locale/lang/ja-JP.umd.js +5 -1
- package/lib/locale/lang/ko-KR.js +5 -1
- package/lib/locale/lang/ko-KR.min.js +1 -1
- package/lib/locale/lang/ko-KR.umd.js +5 -1
- package/lib/locale/lang/ms-MY.js +5 -1
- package/lib/locale/lang/ms-MY.min.js +1 -1
- package/lib/locale/lang/ms-MY.umd.js +5 -1
- package/lib/locale/lang/nb-NO.js +5 -1
- package/lib/locale/lang/nb-NO.min.js +1 -1
- package/lib/locale/lang/nb-NO.umd.js +5 -1
- package/lib/locale/lang/pt-BR.js +5 -1
- package/lib/locale/lang/pt-BR.min.js +1 -1
- package/lib/locale/lang/pt-BR.umd.js +5 -1
- package/lib/locale/lang/ru-RU.js +5 -1
- package/lib/locale/lang/ru-RU.min.js +1 -1
- package/lib/locale/lang/ru-RU.umd.js +5 -1
- package/lib/locale/lang/th-TH.js +5 -1
- package/lib/locale/lang/th-TH.min.js +1 -1
- package/lib/locale/lang/th-TH.umd.js +5 -1
- package/lib/locale/lang/ug-CN.js +5 -1
- package/lib/locale/lang/ug-CN.min.js +1 -1
- package/lib/locale/lang/ug-CN.umd.js +5 -1
- package/lib/locale/lang/uk-UA.js +5 -1
- package/lib/locale/lang/uk-UA.min.js +1 -1
- package/lib/locale/lang/uk-UA.umd.js +5 -1
- package/lib/locale/lang/uz-UZ.js +5 -1
- package/lib/locale/lang/uz-UZ.min.js +1 -1
- package/lib/locale/lang/uz-UZ.umd.js +5 -1
- package/lib/locale/lang/vi-VN.js +5 -1
- package/lib/locale/lang/vi-VN.min.js +1 -1
- package/lib/locale/lang/vi-VN.umd.js +5 -1
- package/lib/locale/lang/zh-CHT.js +6 -2
- package/lib/locale/lang/zh-CHT.min.js +1 -1
- package/lib/locale/lang/zh-CHT.umd.js +6 -2
- package/lib/locale/lang/zh-CN.js +5 -1
- package/lib/locale/lang/zh-CN.min.js +1 -1
- package/lib/locale/lang/zh-CN.umd.js +5 -1
- package/lib/style.css +1 -1
- package/lib/table/module/custom/panel.js +12 -12
- package/lib/table/module/custom/panel.min.js +1 -1
- package/lib/table/src/table.js +3 -3
- package/lib/table/src/table.min.js +1 -1
- package/lib/ui/index.js +4 -2
- package/lib/ui/index.min.js +1 -1
- package/lib/ui/src/log.js +1 -1
- package/lib/ui/src/log.min.js +1 -1
- package/package.json +1 -1
- package/packages/locale/lang/ar-EG.ts +5 -1
- package/packages/locale/lang/de-DE.ts +5 -1
- package/packages/locale/lang/en-US.ts +5 -1
- package/packages/locale/lang/es-ES.ts +5 -1
- package/packages/locale/lang/fr-FR.ts +5 -1
- package/packages/locale/lang/hu-HU.ts +5 -1
- package/packages/locale/lang/hy-AM.ts +5 -1
- package/packages/locale/lang/id-ID.ts +5 -1
- package/packages/locale/lang/it-IT.ts +5 -1
- package/packages/locale/lang/ja-JP.ts +5 -1
- package/packages/locale/lang/ko-KR.ts +5 -1
- package/packages/locale/lang/ms-MY.ts +5 -1
- package/packages/locale/lang/nb-NO.ts +5 -1
- package/packages/locale/lang/pt-BR.ts +5 -1
- package/packages/locale/lang/ru-RU.ts +5 -1
- package/packages/locale/lang/th-TH.ts +5 -1
- package/packages/locale/lang/ug-CN.ts +5 -1
- package/packages/locale/lang/uk-UA.ts +5 -1
- package/packages/locale/lang/uz-UZ.ts +5 -1
- package/packages/locale/lang/vi-VN.ts +5 -1
- package/packages/locale/lang/zh-CHT.ts +6 -2
- package/packages/locale/lang/zh-CN.ts +5 -1
- package/packages/table/module/custom/panel.ts +11 -11
- package/packages/table/src/table.ts +30 -8
- package/packages/ui/index.ts +3 -1
- /package/es/{iconfont.1750641793236.ttf → iconfont.1750660623154.ttf} +0 -0
- /package/es/{iconfont.1750641793236.woff → iconfont.1750660623154.woff} +0 -0
- /package/es/{iconfont.1750641793236.woff2 → iconfont.1750660623154.woff2} +0 -0
- /package/lib/{iconfont.1750641793236.ttf → iconfont.1750660623154.ttf} +0 -0
- /package/lib/{iconfont.1750641793236.woff → iconfont.1750660623154.woff} +0 -0
- /package/lib/{iconfont.1750641793236.woff2 → iconfont.1750660623154.woff2} +0 -0
|
@@ -31,8 +31,8 @@ export default defineVxeComponent({
|
|
|
31
31
|
const refDragTipElem = ref();
|
|
32
32
|
const customPanelReactData = reactive({
|
|
33
33
|
dragCol: null,
|
|
34
|
-
|
|
35
|
-
|
|
34
|
+
prevDragGroup: null,
|
|
35
|
+
prevDragValues: null,
|
|
36
36
|
dragTipText: ''
|
|
37
37
|
});
|
|
38
38
|
const customPanelInternalData = {
|
|
@@ -287,8 +287,8 @@ export default defineVxeComponent({
|
|
|
287
287
|
if (evnt.dataTransfer) {
|
|
288
288
|
evnt.dataTransfer.setDragImage(getTpImg(), 0, 0);
|
|
289
289
|
}
|
|
290
|
-
|
|
291
|
-
|
|
290
|
+
customPanelInternalData.prevDragGroup = null;
|
|
291
|
+
customPanelInternalData.prevDragValues = null;
|
|
292
292
|
};
|
|
293
293
|
const sortDragendEvent = (evnt) => {
|
|
294
294
|
const { mouseConfig } = tableProps;
|
|
@@ -299,10 +299,10 @@ export default defineVxeComponent({
|
|
|
299
299
|
const trEl = evnt.currentTarget;
|
|
300
300
|
const columnDragOpts = computeColumnDragOpts.value;
|
|
301
301
|
const { isCrossDrag, isSelfToChildDrag, isToChildDrag, dragEndMethod } = columnDragOpts;
|
|
302
|
-
const { dragCol
|
|
303
|
-
const { prevDragCol, prevDragPos, prevDragToChild } = customPanelInternalData;
|
|
302
|
+
const { dragCol } = customPanelReactData;
|
|
303
|
+
const { prevDragCol, prevDragGroup, prevDragValues, prevDragPos, prevDragToChild } = customPanelInternalData;
|
|
304
304
|
const dragOffsetIndex = prevDragPos === 'bottom' ? 1 : 0;
|
|
305
|
-
if (
|
|
305
|
+
if (prevDragGroup || prevDragValues) {
|
|
306
306
|
if ($xeTable.handlePivotTableAggregatePanelDragendEvent) {
|
|
307
307
|
$xeTable.handlePivotTableAggregatePanelDragendEvent(evnt);
|
|
308
308
|
}
|
|
@@ -461,8 +461,8 @@ export default defineVxeComponent({
|
|
|
461
461
|
}
|
|
462
462
|
hideDropTip();
|
|
463
463
|
customPanelReactData.dragCol = null;
|
|
464
|
-
|
|
465
|
-
|
|
464
|
+
customPanelInternalData.prevDragGroup = null;
|
|
465
|
+
customPanelInternalData.prevDragValues = null;
|
|
466
466
|
trEl.draggable = false;
|
|
467
467
|
trEl.removeAttribute('drag-pos');
|
|
468
468
|
removeClass(trEl, 'active--drag-target');
|
|
@@ -478,8 +478,8 @@ export default defineVxeComponent({
|
|
|
478
478
|
const colid = optEl.getAttribute('colid');
|
|
479
479
|
const column = $xeTable.getColumnById(colid);
|
|
480
480
|
const { dragCol } = customPanelReactData;
|
|
481
|
-
|
|
482
|
-
|
|
481
|
+
customPanelInternalData.prevDragGroup = null;
|
|
482
|
+
customPanelInternalData.prevDragValues = null;
|
|
483
483
|
// 是否移入有效列
|
|
484
484
|
if (column && (isCrossDrag || column.level === 1)) {
|
|
485
485
|
evnt.preventDefault();
|
package/es/table/src/table.js
CHANGED
|
@@ -6079,12 +6079,25 @@ export default defineVxeComponent({
|
|
|
6079
6079
|
},
|
|
6080
6080
|
setRowGroups(fieldOrColumns) {
|
|
6081
6081
|
const { aggregateConfig, rowGroupConfig } = props;
|
|
6082
|
+
const { rowGroupList } = reactData;
|
|
6083
|
+
const aggregateOpts = computeAggregateOpts.value;
|
|
6084
|
+
const { maxGroupSize } = aggregateOpts;
|
|
6082
6085
|
if (!(aggregateConfig || rowGroupConfig)) {
|
|
6083
6086
|
errLog('vxe.error.reqProp', ['aggregate-config']);
|
|
6084
6087
|
return nextTick();
|
|
6085
6088
|
}
|
|
6086
|
-
|
|
6087
|
-
|
|
6089
|
+
const confList = fieldOrColumns ? (XEUtils.isArray(fieldOrColumns) ? fieldOrColumns : [fieldOrColumns]) : [];
|
|
6090
|
+
if (maxGroupSize && (rowGroupList.length + confList.length > maxGroupSize)) {
|
|
6091
|
+
if (VxeUI.modal) {
|
|
6092
|
+
VxeUI.modal.message({
|
|
6093
|
+
status: 'error',
|
|
6094
|
+
content: getI18n('vxe.table.maxGroupCol', [maxGroupSize])
|
|
6095
|
+
});
|
|
6096
|
+
}
|
|
6097
|
+
return nextTick();
|
|
6098
|
+
}
|
|
6099
|
+
if (confList.length) {
|
|
6100
|
+
handleUpdateRowGroup(confList.map(fieldOrColumn => {
|
|
6088
6101
|
return XEUtils.isString(fieldOrColumn) ? fieldOrColumn : fieldOrColumn.field;
|
|
6089
6102
|
}));
|
|
6090
6103
|
return loadTableData(internalData.tableSynchData, true);
|
|
@@ -6729,7 +6742,7 @@ export default defineVxeComponent({
|
|
|
6729
6742
|
if (customStore.btnEl === evnt.target || getEventTargetNode(evnt, document.body, 'vxe-toolbar-custom-target').flag) {
|
|
6730
6743
|
// 如果点击了自定义列按钮
|
|
6731
6744
|
}
|
|
6732
|
-
else if (getEventTargetNode(evnt, tableCustom
|
|
6745
|
+
else if (getEventTargetNode(evnt, tableCustom.getRefMaps().refElem.value).flag) {
|
|
6733
6746
|
// 如果点击自定义列容器
|
|
6734
6747
|
}
|
|
6735
6748
|
else {
|
|
@@ -8281,7 +8294,15 @@ export default defineVxeComponent({
|
|
|
8281
8294
|
}
|
|
8282
8295
|
vLen++;
|
|
8283
8296
|
});
|
|
8284
|
-
|
|
8297
|
+
let isSelected = (sLen >= vLen && (vLen >= 1 || hLen >= 1));
|
|
8298
|
+
if (checkMethod) {
|
|
8299
|
+
if (checkMethod({ $table: $xeTable, row })) {
|
|
8300
|
+
isSelected = sLen >= vLen;
|
|
8301
|
+
}
|
|
8302
|
+
else {
|
|
8303
|
+
isSelected = selectCheckboxMaps[rowid];
|
|
8304
|
+
}
|
|
8305
|
+
}
|
|
8285
8306
|
const halfSelect = !isSelected && (sLen >= 1 || hLen >= 1);
|
|
8286
8307
|
if (checkField) {
|
|
8287
8308
|
XEUtils.set(row, checkField, isSelected);
|
package/es/ui/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { VxeUI } from '@vxe-ui/core';
|
|
2
2
|
import { getFuncText } from './src/utils';
|
|
3
|
-
export const version = "4.13.
|
|
3
|
+
export const version = "4.13.46";
|
|
4
4
|
VxeUI.version = version;
|
|
5
5
|
VxeUI.tableVersion = version;
|
|
6
6
|
VxeUI.setConfig({
|
|
@@ -141,7 +141,8 @@ VxeUI.setConfig({
|
|
|
141
141
|
childrenField: '_X_ROW_CHILDREN',
|
|
142
142
|
mapChildrenField: '_X_ROW_CHILD_LIST',
|
|
143
143
|
indent: 20,
|
|
144
|
-
showIcon: true
|
|
144
|
+
showIcon: true,
|
|
145
|
+
maxGroupSize: 4
|
|
145
146
|
},
|
|
146
147
|
treeConfig: {
|
|
147
148
|
padding: true,
|
|
@@ -313,6 +314,7 @@ VxeUI.setIcon({
|
|
|
313
314
|
TABLE_ROW_GROUP_CLOSE: iconPrefix + 'arrow-right',
|
|
314
315
|
TABLE_AGGREGATION_GROUPING: iconPrefix + 'grouping',
|
|
315
316
|
TABLE_AGGREGATION_VALUES: iconPrefix + 'values',
|
|
317
|
+
TABLE_AGGREGATION_SORT: iconPrefix + 'drag-handle',
|
|
316
318
|
TABLE_AGGREGATION_DELETE: iconPrefix + 'close',
|
|
317
319
|
// toolbar
|
|
318
320
|
TOOLBAR_TOOLS_REFRESH: iconPrefix + 'repeat',
|
package/es/ui/src/log.js
CHANGED
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.13.
|
|
3141
|
+
const version = "4.13.46";
|
|
3142
3142
|
core_.VxeUI.version = version;
|
|
3143
3143
|
core_.VxeUI.tableVersion = version;
|
|
3144
3144
|
core_.VxeUI.setConfig({
|
|
@@ -3279,7 +3279,8 @@ core_.VxeUI.setConfig({
|
|
|
3279
3279
|
childrenField: '_X_ROW_CHILDREN',
|
|
3280
3280
|
mapChildrenField: '_X_ROW_CHILD_LIST',
|
|
3281
3281
|
indent: 20,
|
|
3282
|
-
showIcon: true
|
|
3282
|
+
showIcon: true,
|
|
3283
|
+
maxGroupSize: 4
|
|
3283
3284
|
},
|
|
3284
3285
|
treeConfig: {
|
|
3285
3286
|
padding: true,
|
|
@@ -3451,6 +3452,7 @@ core_.VxeUI.setIcon({
|
|
|
3451
3452
|
TABLE_ROW_GROUP_CLOSE: iconPrefix + 'arrow-right',
|
|
3452
3453
|
TABLE_AGGREGATION_GROUPING: iconPrefix + 'grouping',
|
|
3453
3454
|
TABLE_AGGREGATION_VALUES: iconPrefix + 'values',
|
|
3455
|
+
TABLE_AGGREGATION_SORT: iconPrefix + 'drag-handle',
|
|
3454
3456
|
TABLE_AGGREGATION_DELETE: iconPrefix + 'close',
|
|
3455
3457
|
// toolbar
|
|
3456
3458
|
TOOLBAR_TOOLS_REFRESH: iconPrefix + 'repeat',
|
|
@@ -3618,7 +3620,7 @@ var esnext_iterator_some = __webpack_require__(7550);
|
|
|
3618
3620
|
const {
|
|
3619
3621
|
log: log_log
|
|
3620
3622
|
} = core_.VxeUI;
|
|
3621
|
-
const log_version = `table v${"4.13.
|
|
3623
|
+
const log_version = `table v${"4.13.46"}`;
|
|
3622
3624
|
const warnLog = log_log.create('warn', log_version);
|
|
3623
3625
|
const errLog = log_log.create('error', log_version);
|
|
3624
3626
|
;// ./packages/table/src/columnInfo.ts
|
|
@@ -8680,8 +8682,8 @@ const {
|
|
|
8680
8682
|
const refDragTipElem = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
8681
8683
|
const customPanelReactData = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.reactive)({
|
|
8682
8684
|
dragCol: null,
|
|
8683
|
-
|
|
8684
|
-
|
|
8685
|
+
prevDragGroup: null,
|
|
8686
|
+
prevDragValues: null,
|
|
8685
8687
|
dragTipText: ''
|
|
8686
8688
|
});
|
|
8687
8689
|
const customPanelInternalData = {
|
|
@@ -8961,8 +8963,8 @@ const {
|
|
|
8961
8963
|
if (evnt.dataTransfer) {
|
|
8962
8964
|
evnt.dataTransfer.setDragImage(getTpImg(), 0, 0);
|
|
8963
8965
|
}
|
|
8964
|
-
|
|
8965
|
-
|
|
8966
|
+
customPanelInternalData.prevDragGroup = null;
|
|
8967
|
+
customPanelInternalData.prevDragValues = null;
|
|
8966
8968
|
};
|
|
8967
8969
|
const sortDragendEvent = evnt => {
|
|
8968
8970
|
const {
|
|
@@ -8987,17 +8989,17 @@ const {
|
|
|
8987
8989
|
dragEndMethod
|
|
8988
8990
|
} = columnDragOpts;
|
|
8989
8991
|
const {
|
|
8990
|
-
dragCol
|
|
8991
|
-
dragGroup,
|
|
8992
|
-
dragValues
|
|
8992
|
+
dragCol
|
|
8993
8993
|
} = customPanelReactData;
|
|
8994
8994
|
const {
|
|
8995
8995
|
prevDragCol,
|
|
8996
|
+
prevDragGroup,
|
|
8997
|
+
prevDragValues,
|
|
8996
8998
|
prevDragPos,
|
|
8997
8999
|
prevDragToChild
|
|
8998
9000
|
} = customPanelInternalData;
|
|
8999
9001
|
const dragOffsetIndex = prevDragPos === 'bottom' ? 1 : 0;
|
|
9000
|
-
if (
|
|
9002
|
+
if (prevDragGroup || prevDragValues) {
|
|
9001
9003
|
if ($xeTable.handlePivotTableAggregatePanelDragendEvent) {
|
|
9002
9004
|
$xeTable.handlePivotTableAggregatePanelDragendEvent(evnt);
|
|
9003
9005
|
}
|
|
@@ -9157,8 +9159,8 @@ const {
|
|
|
9157
9159
|
}
|
|
9158
9160
|
hideDropTip();
|
|
9159
9161
|
customPanelReactData.dragCol = null;
|
|
9160
|
-
|
|
9161
|
-
|
|
9162
|
+
customPanelInternalData.prevDragGroup = null;
|
|
9163
|
+
customPanelInternalData.prevDragValues = null;
|
|
9162
9164
|
trEl.draggable = false;
|
|
9163
9165
|
trEl.removeAttribute('drag-pos');
|
|
9164
9166
|
removeClass(trEl, 'active--drag-target');
|
|
@@ -9181,8 +9183,8 @@ const {
|
|
|
9181
9183
|
const {
|
|
9182
9184
|
dragCol
|
|
9183
9185
|
} = customPanelReactData;
|
|
9184
|
-
|
|
9185
|
-
|
|
9186
|
+
customPanelInternalData.prevDragGroup = null;
|
|
9187
|
+
customPanelInternalData.prevDragValues = null;
|
|
9186
9188
|
// 是否移入有效列
|
|
9187
9189
|
if (column && (isCrossDrag || column.level === 1)) {
|
|
9188
9190
|
evnt.preventDefault();
|
|
@@ -11416,7 +11418,7 @@ rowExpandedMaps={};internalData.rowExpandedMaps=rowExpandedMaps;rows=rows.slice(
|
|
|
11416
11418
|
*/isRowExpandByRow(row){const{rowExpandedFlag}=reactData;const{rowExpandedMaps}=internalData;const rowid=getRowid($xeTable,row);return!!rowExpandedFlag&&!!rowExpandedMaps[rowid];},isExpandByRow(row){// 已废弃
|
|
11417
11419
|
warnLog('vxe.error.delFunc',['isExpandByRow','isRowExpandByRow']);return tableMethods.isRowExpandByRow(row);},/**
|
|
11418
11420
|
* 手动清空展开行状态,数据会恢复成未展开的状态
|
|
11419
|
-
*/clearRowExpand(){const{tableFullData}=internalData;const expandOpts=computeExpandOpts.value;const{reserve}=expandOpts;const expList=$xeTable.getRowExpandRecords();internalData.rowExpandedMaps={};reactData.rowExpandedFlag++;if(reserve){tableFullData.forEach(row=>handleRowExpandReserve(row,false));}return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)().then(()=>{if(expList.length){return $xeTable.recalculate(true);}}).then(()=>{updateRowOffsetTop();updateRowExpandStyle();handleRowExpandScroll();return $xeTable.updateCellAreas();});},clearRowExpandReserve(){internalData.rowExpandedReserveRowMap={};return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();},getRowExpandRecords(){const rest=[];external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(internalData.rowExpandedMaps,item=>{if(item){rest.push(item);}});return rest;},setRowGroups(fieldOrColumns){const{aggregateConfig,rowGroupConfig}=props;if(!(aggregateConfig||rowGroupConfig)){errLog('vxe.error.reqProp',['aggregate-config']);return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();}
|
|
11421
|
+
*/clearRowExpand(){const{tableFullData}=internalData;const expandOpts=computeExpandOpts.value;const{reserve}=expandOpts;const expList=$xeTable.getRowExpandRecords();internalData.rowExpandedMaps={};reactData.rowExpandedFlag++;if(reserve){tableFullData.forEach(row=>handleRowExpandReserve(row,false));}return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)().then(()=>{if(expList.length){return $xeTable.recalculate(true);}}).then(()=>{updateRowOffsetTop();updateRowExpandStyle();handleRowExpandScroll();return $xeTable.updateCellAreas();});},clearRowExpandReserve(){internalData.rowExpandedReserveRowMap={};return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();},getRowExpandRecords(){const rest=[];external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(internalData.rowExpandedMaps,item=>{if(item){rest.push(item);}});return rest;},setRowGroups(fieldOrColumns){const{aggregateConfig,rowGroupConfig}=props;const{rowGroupList}=reactData;const aggregateOpts=computeAggregateOpts.value;const{maxGroupSize}=aggregateOpts;if(!(aggregateConfig||rowGroupConfig)){errLog('vxe.error.reqProp',['aggregate-config']);return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();}const confList=fieldOrColumns?external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(fieldOrColumns)?fieldOrColumns:[fieldOrColumns]:[];if(maxGroupSize&&rowGroupList.length+confList.length>maxGroupSize){if(core_.VxeUI.modal){core_.VxeUI.modal.message({status:'error',content:table_getI18n('vxe.table.maxGroupCol',[maxGroupSize])});}return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();}if(confList.length){handleUpdateRowGroup(confList.map(fieldOrColumn=>{return external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isString(fieldOrColumn)?fieldOrColumn:fieldOrColumn.field;}));return loadTableData(internalData.tableSynchData,true);}return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();},clearRowGroups(){const{aggregateConfig,rowGroupConfig}=props;if(!(aggregateConfig||rowGroupConfig)){errLog('vxe.error.reqProp',['aggregate-config']);return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();}handleUpdateRowGroup([]);return loadTableData(internalData.tableSynchData,true);},isRowGroupRecord(row){warnLog('vxe.error.delFunc',['isRowGroupRecord','isAggregateRecord']);return $xeTable.isAggregateRecord(row);},isRowGroupExpandByRow(row){warnLog('vxe.error.delFunc',['isRowGroupExpandByRow','isAggregateExpandByRow']);return $xeTable.isAggregateExpandByRow(row);},isAggregateRecord(row){const{isRowGroupStatus}=reactData;return isRowGroupStatus&&row.isAggregate;},getAggregateContentByRow(row){const{isRowGroupStatus}=reactData;return isRowGroupStatus&&row&&row.isAggregate?row.groupContent:'';},getAggregateRowChildren(row){const aggregateOpts=computeAggregateOpts.value;const{childrenField,mapChildrenField}=aggregateOpts;const{isRowGroupStatus}=reactData;return isRowGroupStatus&&row&&row.isAggregate&&childrenField&&mapChildrenField?row[mapChildrenField]||[]:[];},isAggregateExpandByRow(row){const{rowGroupExpandedFlag}=reactData;const{rowGroupExpandedMaps}=internalData;return!!rowGroupExpandedFlag&&!!rowGroupExpandedMaps[getRowid($xeTable,row)];},setRowGroupExpand(rows,expanded){if(rows){if(!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(rows)){rows=[rows];}return handleRowGroupVirtualExpand(rows,expanded);}return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();},setAllRowGroupExpand(expanded){const{tableFullGroupData}=internalData;const aggregateOpts=computeAggregateOpts.value;const{mapChildrenField}=aggregateOpts;const rgExpandedMaps={};if(expanded&&mapChildrenField){external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eachTree(tableFullGroupData,row=>{if(row[mapChildrenField]&&row[mapChildrenField].length){rgExpandedMaps[getRowid($xeTable,row)]=row;}},{children:mapChildrenField});}internalData.rowGroupExpandedMaps=rgExpandedMaps;handleVirtualTreeToList();$xeTable.handleTableData();updateAfterDataIndex();reactData.rowGroupExpandedFlag++;return $xeTable.recalculate(true);},clearRowGroupExpand(){internalData.rowGroupExpandedMaps={};handleVirtualTreeToList();$xeTable.handleTableData();updateAfterDataIndex();reactData.rowGroupExpandedFlag++;return $xeTable.recalculate(true);},getTreeExpandRecords(){const rest=[];external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(internalData.treeExpandedMaps,item=>{if(item){rest.push(item);}});return rest;},/**
|
|
11420
11422
|
* 判断树节点是否懒加载完成
|
|
11421
11423
|
* @param {Row} row 行对象
|
|
11422
11424
|
*/isTreeExpandLoaded(row){const{fullAllDataRowIdData}=internalData;const rowRest=fullAllDataRowIdData[getRowid($xeTable,row)];return rowRest&&!!rowRest.treeLoaded;},clearTreeExpandLoaded(rows){const{fullAllDataRowIdData,treeExpandedMaps}=internalData;const treeOpts=computeTreeOpts.value;const{transform}=treeOpts;if(rows){if(!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(rows)){rows=[rows];}rows.forEach(row=>{const rowid=getRowid($xeTable,row);const rowRest=fullAllDataRowIdData[rowid];if(rowRest){rowRest.treeLoaded=false;if(treeExpandedMaps[rowid]){delete treeExpandedMaps[rowid];}}});}else{external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(fullAllDataRowIdData,rowRest=>{rowRest.treeLoaded=false;});}internalData.treeExpandedMaps={};if(transform){handleVirtualTreeToList();$xeTable.handleTableData();}reactData.treeExpandedFlag++;return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();},/**
|
|
@@ -11485,7 +11487,7 @@ if(tableFilter){if(getEventTargetNode(evnt,el,'vxe-cell--filter').flag){// 如
|
|
|
11485
11487
|
}else if(getEventTargetNode(evnt,tableFilter.getRefMaps().refElem.value).flag){// 如果点击筛选容器
|
|
11486
11488
|
}else{if(!getEventTargetNode(evnt,document.body,'vxe-table--ignore-clear').flag){tablePrivateMethods.preventEvent(evnt,'event.clearFilter',filterStore.args,tableMethods.closeFilter);}}}// 自定义列
|
|
11487
11489
|
if(tableCustom){if(customStore.btnEl===evnt.target||getEventTargetNode(evnt,document.body,'vxe-toolbar-custom-target').flag){// 如果点击了自定义列按钮
|
|
11488
|
-
}else if(getEventTargetNode(evnt,tableCustom
|
|
11490
|
+
}else if(getEventTargetNode(evnt,tableCustom.getRefMaps().refElem.value).flag){// 如果点击自定义列容器
|
|
11489
11491
|
}else{if(!getEventTargetNode(evnt,document.body,'vxe-table--ignore-clear').flag){tablePrivateMethods.preventEvent(evnt,'event.clearCustom',{},()=>{if($xeTable.closeCustom){$xeTable.closeCustom();}});}}}// 如果已激活了编辑状态
|
|
11490
11492
|
if(actived.row){if(!(editOpts.autoClear===false)){// 如果是激活状态,点击了单元格之外
|
|
11491
11493
|
const cell=actived.args.cell;if(!cell||!getEventTargetNode(evnt,cell).flag){if($validTooltip&&getEventTargetNode(evnt,$validTooltip.$el).flag){// 如果是激活状态,且点击了校验提示框
|
|
@@ -11583,7 +11585,7 @@ const mapChildrenField=aggregateOpts.mapChildrenField;if(mapChildrenField){exter
|
|
|
11583
11585
|
const{transform,mapChildrenField}=treeOpts;external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eachTree(afterTreeFullData,row=>{const rowid=handleGetRowId(row);const childList=row[transform?mapChildrenField:childrenField];if(childList&&childList.length&&!childRowMaps[rowid]){childRowMaps[rowid]=1;childRowList.unshift([row,rowid,childList]);}},{children:transform?mapChildrenField:childrenField});}childRowList.forEach(vals=>{const row=vals[0];const rowid=vals[1];const childList=vals[2];let sLen=0;// 已选
|
|
11584
11586
|
let hLen=0;// 半选
|
|
11585
11587
|
let vLen=0;// 有效行
|
|
11586
|
-
childList.forEach(checkMethod?item=>{const childRowid=handleGetRowId(item);const isSelect=checkField?external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(item,checkField):selectCheckboxMaps[childRowid];if(checkMethod({$table:$xeTable,row:item})){if(isSelect){sLen++;}else if(treeIndeterminateRowMaps[childRowid]){hLen++;}vLen++;}else{if(isSelect){sLen++;}else if(treeIndeterminateRowMaps[childRowid]){hLen++;}}}:item=>{const childRowid=handleGetRowId(item);const isSelect=checkField?external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(item,checkField):selectCheckboxMaps[childRowid];if(isSelect){sLen++;}else if(treeIndeterminateRowMaps[childRowid]){hLen++;}vLen++;});
|
|
11588
|
+
childList.forEach(checkMethod?item=>{const childRowid=handleGetRowId(item);const isSelect=checkField?external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(item,checkField):selectCheckboxMaps[childRowid];if(checkMethod({$table:$xeTable,row:item})){if(isSelect){sLen++;}else if(treeIndeterminateRowMaps[childRowid]){hLen++;}vLen++;}else{if(isSelect){sLen++;}else if(treeIndeterminateRowMaps[childRowid]){hLen++;}}}:item=>{const childRowid=handleGetRowId(item);const isSelect=checkField?external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(item,checkField):selectCheckboxMaps[childRowid];if(isSelect){sLen++;}else if(treeIndeterminateRowMaps[childRowid]){hLen++;}vLen++;});let isSelected=sLen>=vLen&&(vLen>=1||hLen>=1);if(checkMethod){if(checkMethod({$table:$xeTable,row})){isSelected=sLen>=vLen;}else{isSelected=selectCheckboxMaps[rowid];}}const halfSelect=!isSelected&&(sLen>=1||hLen>=1);if(checkField){external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().set(row,checkField,isSelected);}if(isSelected){if(!checkField){selectCheckboxMaps[rowid]=row;}if(treeIndeterminateRowMaps[rowid]){delete treeIndeterminateRowMaps[rowid];}}else{if(!checkField){if(selectCheckboxMaps[rowid]){delete selectCheckboxMaps[rowid];}}if(halfSelect){treeIndeterminateRowMaps[rowid]=row;}else{if(treeIndeterminateRowMaps[rowid]){delete treeIndeterminateRowMaps[rowid];}}}});}reactData.updateCheckboxFlag++;},updateAllCheckboxStatus(){const{treeConfig}=props;const{isRowGroupStatus}=reactData;const{afterFullData,afterTreeFullData,afterGroupFullData,checkboxReserveRowMap,selectCheckboxMaps,treeIndeterminateRowMaps}=internalData;const checkboxOpts=computeCheckboxOpts.value;const{checkField,checkMethod,showReserveStatus}=checkboxOpts;const{handleGetRowId}=createHandleGetRowId($xeTable);let sLen=0;// 已选
|
|
11587
11589
|
let hLen=0;// 半选
|
|
11588
11590
|
let vLen=0;// 有效行
|
|
11589
11591
|
const rootList=treeConfig?afterTreeFullData:isRowGroupStatus?afterGroupFullData:afterFullData;rootList.forEach(checkMethod?row=>{const childRowid=handleGetRowId(row);const selected=checkField?external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(row,checkField):selectCheckboxMaps[childRowid];if(checkMethod({$table:$xeTable,row})){if(selected){sLen++;}else if(treeIndeterminateRowMaps[childRowid]){hLen++;}vLen++;}else{if(selected){sLen++;}else if(treeIndeterminateRowMaps[childRowid]){hLen++;}}}:row=>{const childRowid=handleGetRowId(row);const selected=checkField?external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(row,checkField):selectCheckboxMaps[childRowid];if(selected){sLen++;}else if(treeIndeterminateRowMaps[childRowid]){hLen++;}vLen++;});const isSelected=rootList.length>0?vLen>0?sLen>=vLen:sLen>=rootList.length:false;let halfSelect=!isSelected&&(sLen>=1||hLen>=1);// 如果复选框启用保留记录,当保留数据存在时显示半选
|
|
@@ -21292,6 +21294,7 @@ const Toolbar = VxeToolbar;
|
|
|
21292
21294
|
customCancel: '取消',
|
|
21293
21295
|
customRestore: '恢复默认',
|
|
21294
21296
|
maxFixedCol: '最大冻结列的数量不能超过 {0} 个',
|
|
21297
|
+
maxGroupCol: '最大分组字段的数量不能超过 {0} 个',
|
|
21295
21298
|
dragTip: '移动:{0}',
|
|
21296
21299
|
resizeColTip: '宽:{0} 像素',
|
|
21297
21300
|
resizeRowTip: '高:{0} 像素',
|
|
@@ -21774,7 +21777,10 @@ const Toolbar = VxeToolbar;
|
|
|
21774
21777
|
extendPivotTable: {
|
|
21775
21778
|
aggregation: {
|
|
21776
21779
|
grouping: '分组',
|
|
21777
|
-
values: '值'
|
|
21780
|
+
values: '值',
|
|
21781
|
+
groupPlaceholder: '拖至此处进行分组',
|
|
21782
|
+
valuesPlaceholder: '拖至此处进行聚合',
|
|
21783
|
+
dragExistCol: '该列已存在'
|
|
21778
21784
|
}
|
|
21779
21785
|
},
|
|
21780
21786
|
filterComplexInput: {
|