vxe-table 3.15.30 → 3.15.32
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/en-US.js +2 -2
- package/es/style.css +1 -1
- package/es/table/module/export/mixin.js +11 -5
- package/es/table/module/validator/mixin.js +2 -2
- package/es/table/src/methods.js +3 -1
- package/es/table/src/util.js +1 -1
- package/es/ui/index.js +3 -3
- package/es/ui/src/log.js +1 -1
- package/lib/index.umd.js +34 -25
- package/lib/index.umd.min.js +1 -1
- package/lib/locale/lang/en-US.js +2 -2
- package/lib/locale/lang/en-US.min.js +1 -1
- package/lib/locale/lang/en-US.umd.js +2 -2
- package/lib/style.css +1 -1
- package/lib/table/module/export/mixin.js +25 -18
- package/lib/table/module/export/mixin.min.js +1 -1
- package/lib/table/module/validator/mixin.js +1 -1
- package/lib/table/module/validator/mixin.min.js +1 -1
- package/lib/table/src/methods.js +3 -1
- package/lib/table/src/methods.min.js +1 -1
- package/lib/table/src/util.js +1 -1
- package/lib/table/src/util.min.js +1 -1
- package/lib/ui/index.js +3 -3
- 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/en-US.ts +2 -2
- package/packages/table/module/export/mixin.ts +10 -5
- package/packages/table/module/validator/mixin.ts +2 -2
- package/packages/table/src/methods.ts +3 -1
- package/packages/table/src/util.ts +1 -1
- package/packages/ui/index.ts +2 -2
- /package/es/{iconfont.1747357311626.ttf → iconfont.1748578557669.ttf} +0 -0
- /package/es/{iconfont.1747357311626.woff → iconfont.1748578557669.woff} +0 -0
- /package/es/{iconfont.1747357311626.woff2 → iconfont.1748578557669.woff2} +0 -0
- /package/lib/{iconfont.1747357311626.ttf → iconfont.1748578557669.ttf} +0 -0
- /package/lib/{iconfont.1747357311626.woff → iconfont.1748578557669.woff} +0 -0
- /package/lib/{iconfont.1747357311626.woff2 → iconfont.1748578557669.woff2} +0 -0
|
@@ -31,7 +31,7 @@ function getSeq($xeTable, cellValue, row, $rowIndex, column, $columnIndex) {
|
|
|
31
31
|
return cellValue;
|
|
32
32
|
}
|
|
33
33
|
function defaultFilterExportColumn(column) {
|
|
34
|
-
return !!column.field || ['seq', 'checkbox', 'radio'].indexOf(column.type || '')
|
|
34
|
+
return !!column.field || ['seq', 'checkbox', 'radio'].indexOf(column.type || '') === -1;
|
|
35
35
|
}
|
|
36
36
|
function toTableBorder(border) {
|
|
37
37
|
if (border === true) {
|
|
@@ -1138,9 +1138,14 @@ export default {
|
|
|
1138
1138
|
if (!mode) {
|
|
1139
1139
|
mode = selectRecords.length ? 'selected' : 'current';
|
|
1140
1140
|
}
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1141
|
+
let isCustomCol = false;
|
|
1142
|
+
let customCols = [];
|
|
1143
|
+
if (columns && columns.length) {
|
|
1144
|
+
isCustomCol = true;
|
|
1145
|
+
customCols = columns;
|
|
1146
|
+
}
|
|
1147
|
+
else {
|
|
1148
|
+
customCols = XEUtils.searchTree(collectColumn, column => {
|
|
1144
1149
|
const isColGroup = column.children && column.children.length > 0;
|
|
1145
1150
|
let isChecked = false;
|
|
1146
1151
|
if (columns && columns.length) {
|
|
@@ -1154,9 +1159,10 @@ export default {
|
|
|
1154
1159
|
}
|
|
1155
1160
|
return isChecked;
|
|
1156
1161
|
}, { children: 'children', mapChildren: 'childNodes', original: true });
|
|
1162
|
+
}
|
|
1157
1163
|
const handleOptions = Object.assign({}, opts, { filename: '', sheetName: '' });
|
|
1158
1164
|
// 如果设置源数据,则默认导出设置了字段的列
|
|
1159
|
-
if (!
|
|
1165
|
+
if (!isCustomCol && !columnFilterMethod) {
|
|
1160
1166
|
columnFilterMethod = ({ column }) => {
|
|
1161
1167
|
if (excludeFields) {
|
|
1162
1168
|
if (XEUtils.includes(excludeFields, column.field)) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import XEUtils from 'xe-utils';
|
|
2
2
|
import { VxeUI } from '../../../ui';
|
|
3
|
-
import { getFuncText } from '../../../ui/src/utils';
|
|
3
|
+
import { eqEmptyValue, getFuncText } from '../../../ui/src/utils';
|
|
4
4
|
import { scrollToView } from '../../../ui/src/dom';
|
|
5
5
|
import { handleFieldOrColumn, getRowid } from '../../src/util';
|
|
6
6
|
import { warnLog, errLog } from '../../../ui/src/log';
|
|
@@ -119,7 +119,7 @@ function validRuleValue(rule, val, required) {
|
|
|
119
119
|
}
|
|
120
120
|
function checkRuleStatus(rule, val) {
|
|
121
121
|
const { required } = rule;
|
|
122
|
-
const isEmptyVal = XEUtils.
|
|
122
|
+
const isEmptyVal = XEUtils.isArray(val) ? !val.length : eqEmptyValue(val);
|
|
123
123
|
if (required) {
|
|
124
124
|
if (isEmptyVal) {
|
|
125
125
|
return false;
|
package/es/table/src/methods.js
CHANGED
|
@@ -3365,7 +3365,9 @@ function updateColumnOffsetLeft($xeTable) {
|
|
|
3365
3365
|
const column = visibleColumn[cIndex];
|
|
3366
3366
|
const colid = column.id;
|
|
3367
3367
|
const colRest = fullColumnIdData[colid];
|
|
3368
|
-
colRest
|
|
3368
|
+
if (colRest) {
|
|
3369
|
+
colRest.oLeft = offsetLeft;
|
|
3370
|
+
}
|
|
3369
3371
|
offsetLeft += column.renderWidth;
|
|
3370
3372
|
}
|
|
3371
3373
|
}
|
package/es/table/src/util.js
CHANGED
|
@@ -75,7 +75,7 @@ export function restoreScrollLocation($xeTable, scrollLeft, scrollTop) {
|
|
|
75
75
|
// 还原滚动状态
|
|
76
76
|
return $xeTable.scrollTo(scrollLeft, scrollTop);
|
|
77
77
|
}
|
|
78
|
-
return $xeTable
|
|
78
|
+
return $xeTable.clearScroll();
|
|
79
79
|
}
|
|
80
80
|
export function toTreePathSeq(path) {
|
|
81
81
|
return path.map((num, i) => i % 2 === 0 ? (Number(num) + 1) : '.').join('');
|
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 = "3.15.
|
|
3
|
+
export const version = "3.15.32";
|
|
4
4
|
VxeUI.version = version;
|
|
5
5
|
VxeUI.tableVersion = version;
|
|
6
6
|
VxeUI.setConfig({
|
|
@@ -201,13 +201,13 @@ VxeUI.setConfig({
|
|
|
201
201
|
isReplace: true
|
|
202
202
|
},
|
|
203
203
|
virtualXConfig: {
|
|
204
|
-
enabled: false,
|
|
204
|
+
// enabled: false,
|
|
205
205
|
gt: 24,
|
|
206
206
|
preSize: 0,
|
|
207
207
|
oSize: 0
|
|
208
208
|
},
|
|
209
209
|
virtualYConfig: {
|
|
210
|
-
enabled: false,
|
|
210
|
+
// enabled: false,
|
|
211
211
|
gt: 100,
|
|
212
212
|
preSize: 1,
|
|
213
213
|
oSize: 0
|
package/es/ui/src/log.js
CHANGED
package/lib/index.umd.js
CHANGED
|
@@ -2002,7 +2002,7 @@ function getClass(property, params) {
|
|
|
2002
2002
|
;// CONCATENATED MODULE: ./packages/ui/index.ts
|
|
2003
2003
|
|
|
2004
2004
|
|
|
2005
|
-
const version = "3.15.
|
|
2005
|
+
const version = "3.15.32";
|
|
2006
2006
|
core_.VxeUI.version = version;
|
|
2007
2007
|
core_.VxeUI.tableVersion = version;
|
|
2008
2008
|
core_.VxeUI.setConfig({
|
|
@@ -2203,13 +2203,13 @@ core_.VxeUI.setConfig({
|
|
|
2203
2203
|
isReplace: true
|
|
2204
2204
|
},
|
|
2205
2205
|
virtualXConfig: {
|
|
2206
|
-
enabled: false,
|
|
2206
|
+
// enabled: false,
|
|
2207
2207
|
gt: 24,
|
|
2208
2208
|
preSize: 0,
|
|
2209
2209
|
oSize: 0
|
|
2210
2210
|
},
|
|
2211
2211
|
virtualYConfig: {
|
|
2212
|
-
enabled: false,
|
|
2212
|
+
// enabled: false,
|
|
2213
2213
|
gt: 100,
|
|
2214
2214
|
preSize: 1,
|
|
2215
2215
|
oSize: 0
|
|
@@ -2646,7 +2646,7 @@ function isNodeElement(elem) {
|
|
|
2646
2646
|
const {
|
|
2647
2647
|
log: log_log
|
|
2648
2648
|
} = core_.VxeUI;
|
|
2649
|
-
const log_version = `table v${"3.15.
|
|
2649
|
+
const log_version = `table v${"3.15.32"}`;
|
|
2650
2650
|
const warnLog = log_log.create('warn', log_version);
|
|
2651
2651
|
const errLog = log_log.create('error', log_version);
|
|
2652
2652
|
;// CONCATENATED MODULE: ./packages/table/src/columnInfo.ts
|
|
@@ -2900,7 +2900,7 @@ function restoreScrollLocation($xeTable, scrollLeft, scrollTop) {
|
|
|
2900
2900
|
// 还原滚动状态
|
|
2901
2901
|
return $xeTable.scrollTo(scrollLeft, scrollTop);
|
|
2902
2902
|
}
|
|
2903
|
-
return $xeTable
|
|
2903
|
+
return $xeTable.clearScroll();
|
|
2904
2904
|
}
|
|
2905
2905
|
function toTreePathSeq(path) {
|
|
2906
2906
|
return path.map((num, i) => i % 2 === 0 ? Number(num) + 1 : '.').join('');
|
|
@@ -9051,7 +9051,9 @@ function updateColumnOffsetLeft($xeTable) {
|
|
|
9051
9051
|
const column = visibleColumn[cIndex];
|
|
9052
9052
|
const colid = column.id;
|
|
9053
9053
|
const colRest = fullColumnIdData[colid];
|
|
9054
|
-
colRest
|
|
9054
|
+
if (colRest) {
|
|
9055
|
+
colRest.oLeft = offsetLeft;
|
|
9056
|
+
}
|
|
9055
9057
|
offsetLeft += column.renderWidth;
|
|
9056
9058
|
}
|
|
9057
9059
|
}
|
|
@@ -23551,7 +23553,7 @@ function getSeq($xeTable, cellValue, row, $rowIndex, column, $columnIndex) {
|
|
|
23551
23553
|
return cellValue;
|
|
23552
23554
|
}
|
|
23553
23555
|
function defaultFilterExportColumn(column) {
|
|
23554
|
-
return !!column.field || ['seq', 'checkbox', 'radio'].indexOf(column.type || '')
|
|
23556
|
+
return !!column.field || ['seq', 'checkbox', 'radio'].indexOf(column.type || '') === -1;
|
|
23555
23557
|
}
|
|
23556
23558
|
function toTableBorder(border) {
|
|
23557
23559
|
if (border === true) {
|
|
@@ -24866,28 +24868,35 @@ const convertToRows = originColumns => {
|
|
|
24866
24868
|
if (!mode) {
|
|
24867
24869
|
mode = selectRecords.length ? 'selected' : 'current';
|
|
24868
24870
|
}
|
|
24869
|
-
|
|
24870
|
-
|
|
24871
|
-
|
|
24872
|
-
|
|
24873
|
-
|
|
24874
|
-
|
|
24875
|
-
|
|
24876
|
-
|
|
24877
|
-
isChecked =
|
|
24878
|
-
|
|
24879
|
-
|
|
24880
|
-
|
|
24881
|
-
|
|
24882
|
-
|
|
24883
|
-
|
|
24884
|
-
|
|
24871
|
+
let isCustomCol = false;
|
|
24872
|
+
let customCols = [];
|
|
24873
|
+
if (columns && columns.length) {
|
|
24874
|
+
isCustomCol = true;
|
|
24875
|
+
customCols = columns;
|
|
24876
|
+
} else {
|
|
24877
|
+
customCols = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().searchTree(collectColumn, column => {
|
|
24878
|
+
const isColGroup = column.children && column.children.length > 0;
|
|
24879
|
+
let isChecked = false;
|
|
24880
|
+
if (columns && columns.length) {
|
|
24881
|
+
isChecked = handleFilterColumns(opts, column, columns);
|
|
24882
|
+
} else if (excludeFields || includeFields) {
|
|
24883
|
+
isChecked = handleFilterFields(opts, column, includeFields, excludeFields);
|
|
24884
|
+
} else {
|
|
24885
|
+
isChecked = column.visible && (isColGroup || defaultFilterExportColumn(column));
|
|
24886
|
+
}
|
|
24887
|
+
return isChecked;
|
|
24888
|
+
}, {
|
|
24889
|
+
children: 'children',
|
|
24890
|
+
mapChildren: 'childNodes',
|
|
24891
|
+
original: true
|
|
24892
|
+
});
|
|
24893
|
+
}
|
|
24885
24894
|
const handleOptions = Object.assign({}, opts, {
|
|
24886
24895
|
filename: '',
|
|
24887
24896
|
sheetName: ''
|
|
24888
24897
|
});
|
|
24889
24898
|
// 如果设置源数据,则默认导出设置了字段的列
|
|
24890
|
-
if (!
|
|
24899
|
+
if (!isCustomCol && !columnFilterMethod) {
|
|
24891
24900
|
columnFilterMethod = ({
|
|
24892
24901
|
column
|
|
24893
24902
|
}) => {
|
|
@@ -26090,7 +26099,7 @@ function checkRuleStatus(rule, val) {
|
|
|
26090
26099
|
const {
|
|
26091
26100
|
required
|
|
26092
26101
|
} = rule;
|
|
26093
|
-
const isEmptyVal = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().
|
|
26102
|
+
const isEmptyVal = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(val) ? !val.length : eqEmptyValue(val);
|
|
26094
26103
|
if (required) {
|
|
26095
26104
|
if (isEmptyVal) {
|
|
26096
26105
|
return false;
|