vxe-table 4.11.21 → 4.11.22
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/style.css +1 -1
- package/es/table/src/table.js +28 -32
- package/es/ui/index.js +1 -1
- package/es/ui/src/log.js +1 -1
- package/lib/index.umd.js +31 -34
- package/lib/index.umd.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/table/src/table.js +29 -32
- package/lib/table/src/table.min.js +1 -1
- package/lib/ui/index.js +1 -1
- 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 +2 -2
- package/packages/table/src/table.ts +28 -32
- /package/es/{iconfont.1741744105265.ttf → iconfont.1741854483061.ttf} +0 -0
- /package/es/{iconfont.1741744105265.woff → iconfont.1741854483061.woff} +0 -0
- /package/es/{iconfont.1741744105265.woff2 → iconfont.1741854483061.woff2} +0 -0
- /package/lib/{iconfont.1741744105265.ttf → iconfont.1741854483061.ttf} +0 -0
- /package/lib/{iconfont.1741744105265.woff → iconfont.1741854483061.woff} +0 -0
- /package/lib/{iconfont.1741744105265.woff2 → iconfont.1741854483061.woff2} +0 -0
package/es/table/src/table.js
CHANGED
|
@@ -1174,7 +1174,7 @@ export default defineComponent({
|
|
|
1174
1174
|
}
|
|
1175
1175
|
else {
|
|
1176
1176
|
if ((storage && !type) || (columnOpts.drag && (isCrossDrag || isSelfToChildDrag))) {
|
|
1177
|
-
errLog('vxe.error.reqProp', [`${column.getTitle() || type || ''} -> column.field
|
|
1177
|
+
errLog('vxe.error.reqProp', [`${column.getTitle() || type || ''} -> column.field=?`]);
|
|
1178
1178
|
}
|
|
1179
1179
|
}
|
|
1180
1180
|
if (!hasFixed && fixed) {
|
|
@@ -5758,7 +5758,13 @@ export default defineComponent({
|
|
|
5758
5758
|
const { id } = props;
|
|
5759
5759
|
const customOpts = computeCustomOpts.value;
|
|
5760
5760
|
const { collectColumn } = internalData;
|
|
5761
|
-
const { checkMethod } = customOpts;
|
|
5761
|
+
const { storage, checkMethod } = customOpts;
|
|
5762
|
+
const isAllCustom = storage === true;
|
|
5763
|
+
const storageOpts = isAllCustom ? {} : Object.assign({}, storage || {});
|
|
5764
|
+
const isCustomResizable = isAllCustom || storageOpts.resizable;
|
|
5765
|
+
const isCustomVisible = isAllCustom || storageOpts.visible;
|
|
5766
|
+
const isCustomFixed = isAllCustom || storageOpts.fixed;
|
|
5767
|
+
const isCustomSort = isAllCustom || storageOpts.sort;
|
|
5762
5768
|
const resizableData = {};
|
|
5763
5769
|
const sortData = {};
|
|
5764
5770
|
const visibleData = {};
|
|
@@ -5778,44 +5784,34 @@ export default defineComponent({
|
|
|
5778
5784
|
let hasFixed = 0;
|
|
5779
5785
|
let hasVisible = 0;
|
|
5780
5786
|
XEUtils.eachTree(collectColumn, (column, index, items, path, parentColumn) => {
|
|
5787
|
+
const colKey = column.getKey();
|
|
5788
|
+
if (!colKey) {
|
|
5789
|
+
errLog('vxe.error.reqProp', [`${column.getTitle() || column.type || ''} -> column.field=?`]);
|
|
5790
|
+
return;
|
|
5791
|
+
}
|
|
5781
5792
|
// 只支持一级
|
|
5782
5793
|
if (!parentColumn) {
|
|
5783
|
-
|
|
5784
|
-
|
|
5785
|
-
|
|
5786
|
-
hasSort = 1;
|
|
5787
|
-
sortData[colKey] = column.renderSortNumber;
|
|
5788
|
-
}
|
|
5789
|
-
});
|
|
5790
|
-
if (column.fixed !== column.defaultFixed) {
|
|
5791
|
-
const colKey = column.getKey();
|
|
5792
|
-
if (colKey) {
|
|
5793
|
-
hasFixed = 1;
|
|
5794
|
-
fixedData[colKey] = column.fixed;
|
|
5795
|
-
}
|
|
5794
|
+
if (isCustomSort) {
|
|
5795
|
+
hasSort = 1;
|
|
5796
|
+
sortData[colKey] = column.renderSortNumber;
|
|
5796
5797
|
}
|
|
5797
|
-
|
|
5798
|
-
|
|
5799
|
-
|
|
5800
|
-
if (colKey) {
|
|
5801
|
-
hasResizable = 1;
|
|
5802
|
-
resizableData[colKey] = column.renderWidth;
|
|
5798
|
+
if (isCustomFixed && column.fixed !== column.defaultFixed) {
|
|
5799
|
+
hasFixed = 1;
|
|
5800
|
+
fixedData[colKey] = column.fixed;
|
|
5803
5801
|
}
|
|
5804
5802
|
}
|
|
5805
|
-
if (
|
|
5803
|
+
if (isCustomResizable && column.resizeWidth) {
|
|
5804
|
+
hasResizable = 1;
|
|
5805
|
+
resizableData[colKey] = column.renderWidth;
|
|
5806
|
+
}
|
|
5807
|
+
if (isCustomVisible && (!checkMethod || checkMethod({ column }))) {
|
|
5806
5808
|
if (!column.visible && column.defaultVisible) {
|
|
5807
|
-
|
|
5808
|
-
|
|
5809
|
-
hasVisible = 1;
|
|
5810
|
-
visibleData[colKey] = false;
|
|
5811
|
-
}
|
|
5809
|
+
hasVisible = 1;
|
|
5810
|
+
visibleData[colKey] = false;
|
|
5812
5811
|
}
|
|
5813
5812
|
else if (column.visible && !column.defaultVisible) {
|
|
5814
|
-
|
|
5815
|
-
|
|
5816
|
-
hasVisible = 1;
|
|
5817
|
-
visibleData[colKey] = true;
|
|
5818
|
-
}
|
|
5813
|
+
hasVisible = 1;
|
|
5814
|
+
visibleData[colKey] = true;
|
|
5819
5815
|
}
|
|
5820
5816
|
}
|
|
5821
5817
|
});
|
package/es/ui/index.js
CHANGED
package/es/ui/src/log.js
CHANGED
package/lib/index.umd.js
CHANGED
|
@@ -3051,7 +3051,7 @@ function eqEmptyValue(cellValue) {
|
|
|
3051
3051
|
;// ./packages/ui/index.ts
|
|
3052
3052
|
|
|
3053
3053
|
|
|
3054
|
-
const version = "4.11.
|
|
3054
|
+
const version = "4.11.22";
|
|
3055
3055
|
core_.VxeUI.version = version;
|
|
3056
3056
|
core_.VxeUI.tableVersion = version;
|
|
3057
3057
|
core_.VxeUI.setConfig({
|
|
@@ -3499,7 +3499,7 @@ var es_iterator_some = __webpack_require__(3579);
|
|
|
3499
3499
|
const {
|
|
3500
3500
|
log: log_log
|
|
3501
3501
|
} = core_.VxeUI;
|
|
3502
|
-
const log_version = `table v${"4.11.
|
|
3502
|
+
const log_version = `table v${"4.11.22"}`;
|
|
3503
3503
|
const warnLog = log_log.create('warn', log_version);
|
|
3504
3504
|
const errLog = log_log.create('error', log_version);
|
|
3505
3505
|
;// ./packages/table/src/columnInfo.ts
|
|
@@ -11591,7 +11591,7 @@ const customStorageKey = 'VXE_CUSTOM_STORE';
|
|
|
11591
11591
|
fullColumnFieldData[field] = rest;
|
|
11592
11592
|
} else {
|
|
11593
11593
|
if (storage && !type || columnOpts.drag && (isCrossDrag || isSelfToChildDrag)) {
|
|
11594
|
-
errLog('vxe.error.reqProp', [`${column.getTitle() || type || ''} -> column.field
|
|
11594
|
+
errLog('vxe.error.reqProp', [`${column.getTitle() || type || ''} -> column.field=?`]);
|
|
11595
11595
|
}
|
|
11596
11596
|
}
|
|
11597
11597
|
if (!hasFixed && fixed) {
|
|
@@ -16942,8 +16942,15 @@ const customStorageKey = 'VXE_CUSTOM_STORE';
|
|
|
16942
16942
|
collectColumn
|
|
16943
16943
|
} = internalData;
|
|
16944
16944
|
const {
|
|
16945
|
+
storage,
|
|
16945
16946
|
checkMethod
|
|
16946
16947
|
} = customOpts;
|
|
16948
|
+
const isAllCustom = storage === true;
|
|
16949
|
+
const storageOpts = isAllCustom ? {} : Object.assign({}, storage || {});
|
|
16950
|
+
const isCustomResizable = isAllCustom || storageOpts.resizable;
|
|
16951
|
+
const isCustomVisible = isAllCustom || storageOpts.visible;
|
|
16952
|
+
const isCustomFixed = isAllCustom || storageOpts.fixed;
|
|
16953
|
+
const isCustomSort = isAllCustom || storageOpts.sort;
|
|
16947
16954
|
const resizableData = {};
|
|
16948
16955
|
const sortData = {};
|
|
16949
16956
|
const visibleData = {};
|
|
@@ -16963,45 +16970,35 @@ const customStorageKey = 'VXE_CUSTOM_STORE';
|
|
|
16963
16970
|
let hasFixed = 0;
|
|
16964
16971
|
let hasVisible = 0;
|
|
16965
16972
|
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eachTree(collectColumn, (column, index, items, path, parentColumn) => {
|
|
16973
|
+
const colKey = column.getKey();
|
|
16974
|
+
if (!colKey) {
|
|
16975
|
+
errLog('vxe.error.reqProp', [`${column.getTitle() || column.type || ''} -> column.field=?`]);
|
|
16976
|
+
return;
|
|
16977
|
+
}
|
|
16966
16978
|
// 只支持一级
|
|
16967
16979
|
if (!parentColumn) {
|
|
16968
|
-
|
|
16969
|
-
|
|
16970
|
-
|
|
16971
|
-
hasSort = 1;
|
|
16972
|
-
sortData[colKey] = column.renderSortNumber;
|
|
16973
|
-
}
|
|
16974
|
-
});
|
|
16975
|
-
if (column.fixed !== column.defaultFixed) {
|
|
16976
|
-
const colKey = column.getKey();
|
|
16977
|
-
if (colKey) {
|
|
16978
|
-
hasFixed = 1;
|
|
16979
|
-
fixedData[colKey] = column.fixed;
|
|
16980
|
-
}
|
|
16980
|
+
if (isCustomSort) {
|
|
16981
|
+
hasSort = 1;
|
|
16982
|
+
sortData[colKey] = column.renderSortNumber;
|
|
16981
16983
|
}
|
|
16982
|
-
|
|
16983
|
-
|
|
16984
|
-
|
|
16985
|
-
if (colKey) {
|
|
16986
|
-
hasResizable = 1;
|
|
16987
|
-
resizableData[colKey] = column.renderWidth;
|
|
16984
|
+
if (isCustomFixed && column.fixed !== column.defaultFixed) {
|
|
16985
|
+
hasFixed = 1;
|
|
16986
|
+
fixedData[colKey] = column.fixed;
|
|
16988
16987
|
}
|
|
16989
16988
|
}
|
|
16990
|
-
if (
|
|
16989
|
+
if (isCustomResizable && column.resizeWidth) {
|
|
16990
|
+
hasResizable = 1;
|
|
16991
|
+
resizableData[colKey] = column.renderWidth;
|
|
16992
|
+
}
|
|
16993
|
+
if (isCustomVisible && (!checkMethod || checkMethod({
|
|
16991
16994
|
column
|
|
16992
|
-
})) {
|
|
16995
|
+
}))) {
|
|
16993
16996
|
if (!column.visible && column.defaultVisible) {
|
|
16994
|
-
|
|
16995
|
-
|
|
16996
|
-
hasVisible = 1;
|
|
16997
|
-
visibleData[colKey] = false;
|
|
16998
|
-
}
|
|
16997
|
+
hasVisible = 1;
|
|
16998
|
+
visibleData[colKey] = false;
|
|
16999
16999
|
} else if (column.visible && !column.defaultVisible) {
|
|
17000
|
-
|
|
17001
|
-
|
|
17002
|
-
hasVisible = 1;
|
|
17003
|
-
visibleData[colKey] = true;
|
|
17004
|
-
}
|
|
17000
|
+
hasVisible = 1;
|
|
17001
|
+
visibleData[colKey] = true;
|
|
17005
17002
|
}
|
|
17006
17003
|
}
|
|
17007
17004
|
});
|