vxe-table 3.15.25 → 3.15.27
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/cell.js +3 -1
- package/es/table/src/methods.js +9 -8
- package/es/table/src/table.js +30 -1
- package/es/table/src/util.js +21 -17
- package/es/ui/index.js +1 -1
- package/es/ui/src/log.js +1 -1
- package/lib/index.umd.js +80 -28
- package/lib/index.umd.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/table/src/cell.js +3 -1
- package/lib/table/src/cell.min.js +1 -1
- package/lib/table/src/methods.js +11 -8
- package/lib/table/src/methods.min.js +1 -1
- package/lib/table/src/table.js +32 -0
- package/lib/table/src/table.min.js +1 -1
- package/lib/table/src/util.js +33 -17
- package/lib/table/src/util.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 +1 -1
- package/packages/table/src/cell.ts +3 -1
- package/packages/table/src/methods.ts +9 -8
- package/packages/table/src/table.ts +41 -7
- package/packages/table/src/util.ts +24 -19
- /package/es/{iconfont.1747008127102.ttf → iconfont.1747094784148.ttf} +0 -0
- /package/es/{iconfont.1747008127102.woff → iconfont.1747094784148.woff} +0 -0
- /package/es/{iconfont.1747008127102.woff2 → iconfont.1747094784148.woff2} +0 -0
- /package/lib/{iconfont.1747008127102.ttf → iconfont.1747094784148.ttf} +0 -0
- /package/lib/{iconfont.1747008127102.woff → iconfont.1747094784148.woff} +0 -0
- /package/lib/{iconfont.1747008127102.woff2 → iconfont.1747094784148.woff2} +0 -0
package/es/table/src/methods.js
CHANGED
|
@@ -4188,7 +4188,6 @@ const Methods = {
|
|
|
4188
4188
|
},
|
|
4189
4189
|
/**
|
|
4190
4190
|
* 检查是否为临时行数据
|
|
4191
|
-
* @param {Row} row 行对象
|
|
4192
4191
|
*/
|
|
4193
4192
|
isInsertByRow(row) {
|
|
4194
4193
|
const $xeTable = this;
|
|
@@ -4206,18 +4205,15 @@ const Methods = {
|
|
|
4206
4205
|
},
|
|
4207
4206
|
/**
|
|
4208
4207
|
* 删除所有新增的临时数据
|
|
4209
|
-
* @returns
|
|
4210
4208
|
*/
|
|
4211
4209
|
removeInsertRow() {
|
|
4212
4210
|
const $xeTable = this;
|
|
4213
4211
|
const internalData = $xeTable;
|
|
4214
|
-
|
|
4215
|
-
return $xeTable.remove(
|
|
4212
|
+
const { insertRowMaps } = internalData;
|
|
4213
|
+
return $xeTable.remove(XEUtils.values(insertRowMaps));
|
|
4216
4214
|
},
|
|
4217
4215
|
/**
|
|
4218
4216
|
* 检查行或列数据是否发生改变
|
|
4219
|
-
* @param {Row} rowOrId 行对象
|
|
4220
|
-
* @param {String} field 字段名
|
|
4221
4217
|
*/
|
|
4222
4218
|
isUpdateByRow(rowOrId, field) {
|
|
4223
4219
|
const $xeTable = this;
|
|
@@ -6191,7 +6187,11 @@ const Methods = {
|
|
|
6191
6187
|
if (!titleElem) {
|
|
6192
6188
|
return;
|
|
6193
6189
|
}
|
|
6194
|
-
const
|
|
6190
|
+
const cWrapperEl = titleElem.parentElement;
|
|
6191
|
+
if (!cWrapperEl) {
|
|
6192
|
+
return;
|
|
6193
|
+
}
|
|
6194
|
+
const cellEl = cWrapperEl.parentElement;
|
|
6195
6195
|
if (!cellEl) {
|
|
6196
6196
|
return;
|
|
6197
6197
|
}
|
|
@@ -6200,7 +6200,8 @@ const Methods = {
|
|
|
6200
6200
|
return;
|
|
6201
6201
|
}
|
|
6202
6202
|
if (tooltipStore.column !== column || !tooltipStore.visible) {
|
|
6203
|
-
|
|
6203
|
+
const ctEl = thEl.querySelector('.vxe-cell--title');
|
|
6204
|
+
handleTooltip($xeTable, evnt, thEl, (hasClass(thEl, 'col--ellipsis') ? ctEl : cWrapperEl) || cWrapperEl, ctEl || cellEl, params);
|
|
6204
6205
|
}
|
|
6205
6206
|
},
|
|
6206
6207
|
/**
|
package/es/table/src/table.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import XEUtils from 'xe-utils';
|
|
2
2
|
import { getFuncText, isEnableConf } from '../../ui/src/utils';
|
|
3
3
|
import { initTpImg } from '../../ui/src/dom';
|
|
4
|
-
import { createHandleGetRowId, getCellHeight } from './util';
|
|
4
|
+
import { createHandleGetRowId, getCellHeight, hasDeepKey } from './util';
|
|
5
5
|
import { VxeUI } from '../../ui';
|
|
6
6
|
import methods from './methods';
|
|
7
7
|
import TableBodyComponent from './body';
|
|
@@ -23,6 +23,12 @@ import keyboardMixin from '../module/keyboard/mixin';
|
|
|
23
23
|
import validatorMixin from '../module/validator/mixin';
|
|
24
24
|
import customMixin from '../module/custom/mixin';
|
|
25
25
|
const { getConfig, getIcon, getI18n, renderer, globalResize, globalEvents, globalMixins, renderEmptyElement } = VxeUI;
|
|
26
|
+
function handleKeyField($xeTable) {
|
|
27
|
+
const internalData = $xeTable;
|
|
28
|
+
const keyField = $xeTable.computeRowField;
|
|
29
|
+
internalData.currKeyField = keyField;
|
|
30
|
+
internalData.isCurrDeepKey = hasDeepKey(keyField);
|
|
31
|
+
}
|
|
26
32
|
/**
|
|
27
33
|
* 渲染浮固定列
|
|
28
34
|
* 分别渲染左边固定列和右边固定列
|
|
@@ -690,6 +696,12 @@ export default {
|
|
|
690
696
|
}
|
|
691
697
|
return '';
|
|
692
698
|
},
|
|
699
|
+
computeRowField() {
|
|
700
|
+
const $xeTable = this;
|
|
701
|
+
const props = $xeTable;
|
|
702
|
+
const rowOpts = $xeTable.computeRowOpts;
|
|
703
|
+
return `${props.rowId || rowOpts.keyField || '_X_ROW_KEY'}`;
|
|
704
|
+
},
|
|
693
705
|
validOpts() {
|
|
694
706
|
return this.computeValidOpts;
|
|
695
707
|
},
|
|
@@ -1303,6 +1315,20 @@ export default {
|
|
|
1303
1315
|
computeRowGroupFields(val) {
|
|
1304
1316
|
const $xeTable = this;
|
|
1305
1317
|
$xeTable.handleUpdateRowGroup(val);
|
|
1318
|
+
},
|
|
1319
|
+
computeRowField() {
|
|
1320
|
+
const $xeTable = this;
|
|
1321
|
+
const reactData = $xeTable;
|
|
1322
|
+
const internalData = $xeTable;
|
|
1323
|
+
// 行主键被改变,重载表格
|
|
1324
|
+
const { inited, tableFullData } = internalData;
|
|
1325
|
+
if (inited) {
|
|
1326
|
+
handleKeyField($xeTable);
|
|
1327
|
+
reactData.tableData = [];
|
|
1328
|
+
$xeTable.$nextTick(() => {
|
|
1329
|
+
$xeTable.reloadData(tableFullData);
|
|
1330
|
+
});
|
|
1331
|
+
}
|
|
1306
1332
|
}
|
|
1307
1333
|
},
|
|
1308
1334
|
created() {
|
|
@@ -1311,6 +1337,8 @@ export default {
|
|
|
1311
1337
|
const internalData = $xeTable;
|
|
1312
1338
|
Object.assign($xeTable, {
|
|
1313
1339
|
tZindex: 0,
|
|
1340
|
+
currKeyField: '',
|
|
1341
|
+
isCurrDeepKey: false,
|
|
1314
1342
|
elemStore: {},
|
|
1315
1343
|
// 存放横向 X 虚拟滚动相关的信息
|
|
1316
1344
|
scrollXStore: {
|
|
@@ -1417,6 +1445,7 @@ export default {
|
|
|
1417
1445
|
swYInterval: 0,
|
|
1418
1446
|
swYTotal: 0
|
|
1419
1447
|
});
|
|
1448
|
+
handleKeyField($xeTable);
|
|
1420
1449
|
const { data, exportConfig, importConfig, treeConfig, showOverflow, highlightCurrentRow, highlightCurrentColumn } = props;
|
|
1421
1450
|
const { scrollXStore, scrollYStore } = internalData;
|
|
1422
1451
|
const columnOpts = $xeTable.computeColumnOpts;
|
package/es/table/src/util.js
CHANGED
|
@@ -86,36 +86,40 @@ export function toTreePathSeq(path) {
|
|
|
86
86
|
export function getRowUniqueId() {
|
|
87
87
|
return XEUtils.uniqueId('row_');
|
|
88
88
|
}
|
|
89
|
+
export function hasDeepKey(rowKey) {
|
|
90
|
+
return rowKey.indexOf('.') > -1;
|
|
91
|
+
}
|
|
89
92
|
// 行主键 key
|
|
90
93
|
export function getRowkey($xeTable) {
|
|
91
|
-
const
|
|
92
|
-
const
|
|
93
|
-
return
|
|
94
|
+
const internalData = $xeTable;
|
|
95
|
+
const { currKeyField } = internalData;
|
|
96
|
+
return currKeyField;
|
|
94
97
|
}
|
|
95
98
|
// 行主键 value
|
|
96
99
|
export function getRowid($xeTable, row) {
|
|
97
|
-
const
|
|
98
|
-
|
|
100
|
+
const internalData = $xeTable;
|
|
101
|
+
const { isCurrDeepKey, currKeyField } = internalData;
|
|
102
|
+
return row ? encodeRowid((isCurrDeepKey ? getDeepRowIdByKey : getFastRowIdByKey)(row, currKeyField)) : '';
|
|
99
103
|
}
|
|
100
104
|
export function createHandleUpdateRowId($xeTable) {
|
|
101
|
-
const
|
|
102
|
-
const
|
|
103
|
-
const updateRId =
|
|
105
|
+
const internalData = $xeTable;
|
|
106
|
+
const { isCurrDeepKey, currKeyField } = internalData;
|
|
107
|
+
const updateRId = isCurrDeepKey ? updateDeepRowKey : updateFastRowKey;
|
|
104
108
|
return {
|
|
105
|
-
rowKey,
|
|
109
|
+
rowKey: currKeyField,
|
|
106
110
|
handleUpdateRowId(row) {
|
|
107
|
-
return row ? updateRId(row,
|
|
111
|
+
return row ? updateRId(row, currKeyField) : '';
|
|
108
112
|
}
|
|
109
113
|
};
|
|
110
114
|
}
|
|
111
115
|
export function createHandleGetRowId($xeTable) {
|
|
112
|
-
const
|
|
113
|
-
const
|
|
114
|
-
const getRId =
|
|
116
|
+
const internalData = $xeTable;
|
|
117
|
+
const { isCurrDeepKey, currKeyField } = internalData;
|
|
118
|
+
const getRId = isCurrDeepKey ? getDeepRowIdByKey : getFastRowIdByKey;
|
|
115
119
|
return {
|
|
116
|
-
rowKey,
|
|
120
|
+
rowKey: currKeyField,
|
|
117
121
|
handleGetRowId(row) {
|
|
118
|
-
return row ? getRId(row,
|
|
122
|
+
return row ? encodeRowid(getRId(row, currKeyField)) : '';
|
|
119
123
|
}
|
|
120
124
|
};
|
|
121
125
|
}
|
|
@@ -127,7 +131,7 @@ function getDeepRowIdByKey(row, rowKey) {
|
|
|
127
131
|
return XEUtils.get(row, rowKey);
|
|
128
132
|
}
|
|
129
133
|
export function updateDeepRowKey(row, rowKey) {
|
|
130
|
-
let rowid = getDeepRowIdByKey(row, rowKey);
|
|
134
|
+
let rowid = encodeRowid(getDeepRowIdByKey(row, rowKey));
|
|
131
135
|
if (eqEmptyValue(rowid)) {
|
|
132
136
|
rowid = getRowUniqueId();
|
|
133
137
|
XEUtils.set(row, rowKey, rowid);
|
|
@@ -138,7 +142,7 @@ function getFastRowIdByKey(row, rowKey) {
|
|
|
138
142
|
return row[rowKey];
|
|
139
143
|
}
|
|
140
144
|
export function updateFastRowKey(row, rowKey) {
|
|
141
|
-
let rowid = getFastRowIdByKey(row, rowKey);
|
|
145
|
+
let rowid = encodeRowid(getFastRowIdByKey(row, rowKey));
|
|
142
146
|
if (eqEmptyValue(rowid)) {
|
|
143
147
|
rowid = getRowUniqueId();
|
|
144
148
|
row[rowKey] = rowid;
|
package/es/ui/index.js
CHANGED
package/es/ui/src/log.js
CHANGED
package/lib/index.umd.js
CHANGED
|
@@ -2220,7 +2220,7 @@ function getClass(property, params) {
|
|
|
2220
2220
|
;// CONCATENATED MODULE: ./packages/ui/index.ts
|
|
2221
2221
|
|
|
2222
2222
|
|
|
2223
|
-
const version = "3.15.
|
|
2223
|
+
const version = "3.15.27";
|
|
2224
2224
|
core_.VxeUI.version = version;
|
|
2225
2225
|
core_.VxeUI.tableVersion = version;
|
|
2226
2226
|
core_.VxeUI.setConfig({
|
|
@@ -2864,7 +2864,7 @@ function isNodeElement(elem) {
|
|
|
2864
2864
|
const {
|
|
2865
2865
|
log: log_log
|
|
2866
2866
|
} = core_.VxeUI;
|
|
2867
|
-
const log_version = `table v${"3.15.
|
|
2867
|
+
const log_version = `table v${"3.15.27"}`;
|
|
2868
2868
|
const warnLog = log_log.create('warn', log_version);
|
|
2869
2869
|
const errLog = log_log.create('error', log_version);
|
|
2870
2870
|
;// CONCATENATED MODULE: ./packages/table/src/columnInfo.ts
|
|
@@ -3129,36 +3129,51 @@ function toTreePathSeq(path) {
|
|
|
3129
3129
|
function getRowUniqueId() {
|
|
3130
3130
|
return external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().uniqueId('row_');
|
|
3131
3131
|
}
|
|
3132
|
+
function hasDeepKey(rowKey) {
|
|
3133
|
+
return rowKey.indexOf('.') > -1;
|
|
3134
|
+
}
|
|
3132
3135
|
// 行主键 key
|
|
3133
3136
|
function getRowkey($xeTable) {
|
|
3134
|
-
const
|
|
3135
|
-
const
|
|
3136
|
-
|
|
3137
|
+
const internalData = $xeTable;
|
|
3138
|
+
const {
|
|
3139
|
+
currKeyField
|
|
3140
|
+
} = internalData;
|
|
3141
|
+
return currKeyField;
|
|
3137
3142
|
}
|
|
3138
3143
|
// 行主键 value
|
|
3139
3144
|
function getRowid($xeTable, row) {
|
|
3140
|
-
const
|
|
3141
|
-
|
|
3145
|
+
const internalData = $xeTable;
|
|
3146
|
+
const {
|
|
3147
|
+
isCurrDeepKey,
|
|
3148
|
+
currKeyField
|
|
3149
|
+
} = internalData;
|
|
3150
|
+
return row ? encodeRowid((isCurrDeepKey ? getDeepRowIdByKey : getFastRowIdByKey)(row, currKeyField)) : '';
|
|
3142
3151
|
}
|
|
3143
3152
|
function createHandleUpdateRowId($xeTable) {
|
|
3144
|
-
const
|
|
3145
|
-
const
|
|
3146
|
-
|
|
3153
|
+
const internalData = $xeTable;
|
|
3154
|
+
const {
|
|
3155
|
+
isCurrDeepKey,
|
|
3156
|
+
currKeyField
|
|
3157
|
+
} = internalData;
|
|
3158
|
+
const updateRId = isCurrDeepKey ? updateDeepRowKey : updateFastRowKey;
|
|
3147
3159
|
return {
|
|
3148
|
-
rowKey,
|
|
3160
|
+
rowKey: currKeyField,
|
|
3149
3161
|
handleUpdateRowId(row) {
|
|
3150
|
-
return row ? updateRId(row,
|
|
3162
|
+
return row ? updateRId(row, currKeyField) : '';
|
|
3151
3163
|
}
|
|
3152
3164
|
};
|
|
3153
3165
|
}
|
|
3154
3166
|
function createHandleGetRowId($xeTable) {
|
|
3155
|
-
const
|
|
3156
|
-
const
|
|
3157
|
-
|
|
3167
|
+
const internalData = $xeTable;
|
|
3168
|
+
const {
|
|
3169
|
+
isCurrDeepKey,
|
|
3170
|
+
currKeyField
|
|
3171
|
+
} = internalData;
|
|
3172
|
+
const getRId = isCurrDeepKey ? getDeepRowIdByKey : getFastRowIdByKey;
|
|
3158
3173
|
return {
|
|
3159
|
-
rowKey,
|
|
3174
|
+
rowKey: currKeyField,
|
|
3160
3175
|
handleGetRowId(row) {
|
|
3161
|
-
return row ? getRId(row,
|
|
3176
|
+
return row ? encodeRowid(getRId(row, currKeyField)) : '';
|
|
3162
3177
|
}
|
|
3163
3178
|
};
|
|
3164
3179
|
}
|
|
@@ -3170,7 +3185,7 @@ function getDeepRowIdByKey(row, rowKey) {
|
|
|
3170
3185
|
return external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(row, rowKey);
|
|
3171
3186
|
}
|
|
3172
3187
|
function updateDeepRowKey(row, rowKey) {
|
|
3173
|
-
let rowid = getDeepRowIdByKey(row, rowKey);
|
|
3188
|
+
let rowid = encodeRowid(getDeepRowIdByKey(row, rowKey));
|
|
3174
3189
|
if (eqEmptyValue(rowid)) {
|
|
3175
3190
|
rowid = getRowUniqueId();
|
|
3176
3191
|
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().set(row, rowKey, rowid);
|
|
@@ -3181,7 +3196,7 @@ function getFastRowIdByKey(row, rowKey) {
|
|
|
3181
3196
|
return row[rowKey];
|
|
3182
3197
|
}
|
|
3183
3198
|
function updateFastRowKey(row, rowKey) {
|
|
3184
|
-
let rowid = getFastRowIdByKey(row, rowKey);
|
|
3199
|
+
let rowid = encodeRowid(getFastRowIdByKey(row, rowKey));
|
|
3185
3200
|
if (eqEmptyValue(rowid)) {
|
|
3186
3201
|
rowid = getRowUniqueId();
|
|
3187
3202
|
row[rowKey] = rowid;
|
|
@@ -4926,7 +4941,9 @@ const Cell = {
|
|
|
4926
4941
|
class: 'vxe-cell--required-icon'
|
|
4927
4942
|
})]) : renderEmptyElement($table), isEnableConf(editRender) && editOpts.showIcon ? h('i', {
|
|
4928
4943
|
class: 'vxe-cell--edit-icon'
|
|
4929
|
-
}, [h('i'
|
|
4944
|
+
}, [h('i', {
|
|
4945
|
+
class: editOpts.icon || cell_getIcon().TABLE_EDIT
|
|
4946
|
+
})]) : renderEmptyElement($table)];
|
|
4930
4947
|
}
|
|
4931
4948
|
return renderHeaderCellBaseVNs(h, params, editIconVNs.concat(Cell.renderHeaderTitle(h, params)).concat(sortable ? Cell.renderSortIcon(h, params) : []).concat(filters ? Cell.renderFilterIcon(h, params) : []));
|
|
4932
4949
|
},
|
|
@@ -10203,7 +10220,6 @@ const Methods = {
|
|
|
10203
10220
|
},
|
|
10204
10221
|
/**
|
|
10205
10222
|
* 检查是否为临时行数据
|
|
10206
|
-
* @param {Row} row 行对象
|
|
10207
10223
|
*/
|
|
10208
10224
|
isInsertByRow(row) {
|
|
10209
10225
|
const $xeTable = this;
|
|
@@ -10221,18 +10237,17 @@ const Methods = {
|
|
|
10221
10237
|
},
|
|
10222
10238
|
/**
|
|
10223
10239
|
* 删除所有新增的临时数据
|
|
10224
|
-
* @returns
|
|
10225
10240
|
*/
|
|
10226
10241
|
removeInsertRow() {
|
|
10227
10242
|
const $xeTable = this;
|
|
10228
10243
|
const internalData = $xeTable;
|
|
10229
|
-
|
|
10230
|
-
|
|
10244
|
+
const {
|
|
10245
|
+
insertRowMaps
|
|
10246
|
+
} = internalData;
|
|
10247
|
+
return $xeTable.remove(external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().values(insertRowMaps));
|
|
10231
10248
|
},
|
|
10232
10249
|
/**
|
|
10233
10250
|
* 检查行或列数据是否发生改变
|
|
10234
|
-
* @param {Row} rowOrId 行对象
|
|
10235
|
-
* @param {String} field 字段名
|
|
10236
10251
|
*/
|
|
10237
10252
|
isUpdateByRow(rowOrId, field) {
|
|
10238
10253
|
const $xeTable = this;
|
|
@@ -12465,7 +12480,11 @@ const Methods = {
|
|
|
12465
12480
|
if (!titleElem) {
|
|
12466
12481
|
return;
|
|
12467
12482
|
}
|
|
12468
|
-
const
|
|
12483
|
+
const cWrapperEl = titleElem.parentElement;
|
|
12484
|
+
if (!cWrapperEl) {
|
|
12485
|
+
return;
|
|
12486
|
+
}
|
|
12487
|
+
const cellEl = cWrapperEl.parentElement;
|
|
12469
12488
|
if (!cellEl) {
|
|
12470
12489
|
return;
|
|
12471
12490
|
}
|
|
@@ -12474,7 +12493,8 @@ const Methods = {
|
|
|
12474
12493
|
return;
|
|
12475
12494
|
}
|
|
12476
12495
|
if (tooltipStore.column !== column || !tooltipStore.visible) {
|
|
12477
|
-
|
|
12496
|
+
const ctEl = thEl.querySelector('.vxe-cell--title');
|
|
12497
|
+
handleTooltip($xeTable, evnt, thEl, (hasClass(thEl, 'col--ellipsis') ? ctEl : cWrapperEl) || cWrapperEl, ctEl || cellEl, params);
|
|
12478
12498
|
}
|
|
12479
12499
|
},
|
|
12480
12500
|
/**
|
|
@@ -27092,6 +27112,12 @@ const {
|
|
|
27092
27112
|
globalMixins: table_globalMixins,
|
|
27093
27113
|
renderEmptyElement: table_renderEmptyElement
|
|
27094
27114
|
} = core_.VxeUI;
|
|
27115
|
+
function handleKeyField($xeTable) {
|
|
27116
|
+
const internalData = $xeTable;
|
|
27117
|
+
const keyField = $xeTable.computeRowField;
|
|
27118
|
+
internalData.currKeyField = keyField;
|
|
27119
|
+
internalData.isCurrDeepKey = hasDeepKey(keyField);
|
|
27120
|
+
}
|
|
27095
27121
|
/**
|
|
27096
27122
|
* 渲染浮固定列
|
|
27097
27123
|
* 分别渲染左边固定列和右边固定列
|
|
@@ -27753,6 +27779,12 @@ function renderBody(h, $xeTable) {
|
|
|
27753
27779
|
}
|
|
27754
27780
|
return '';
|
|
27755
27781
|
},
|
|
27782
|
+
computeRowField() {
|
|
27783
|
+
const $xeTable = this;
|
|
27784
|
+
const props = $xeTable;
|
|
27785
|
+
const rowOpts = $xeTable.computeRowOpts;
|
|
27786
|
+
return `${props.rowId || rowOpts.keyField || '_X_ROW_KEY'}`;
|
|
27787
|
+
},
|
|
27756
27788
|
validOpts() {
|
|
27757
27789
|
return this.computeValidOpts;
|
|
27758
27790
|
},
|
|
@@ -28437,6 +28469,23 @@ function renderBody(h, $xeTable) {
|
|
|
28437
28469
|
computeRowGroupFields(val) {
|
|
28438
28470
|
const $xeTable = this;
|
|
28439
28471
|
$xeTable.handleUpdateRowGroup(val);
|
|
28472
|
+
},
|
|
28473
|
+
computeRowField() {
|
|
28474
|
+
const $xeTable = this;
|
|
28475
|
+
const reactData = $xeTable;
|
|
28476
|
+
const internalData = $xeTable;
|
|
28477
|
+
// 行主键被改变,重载表格
|
|
28478
|
+
const {
|
|
28479
|
+
inited,
|
|
28480
|
+
tableFullData
|
|
28481
|
+
} = internalData;
|
|
28482
|
+
if (inited) {
|
|
28483
|
+
handleKeyField($xeTable);
|
|
28484
|
+
reactData.tableData = [];
|
|
28485
|
+
$xeTable.$nextTick(() => {
|
|
28486
|
+
$xeTable.reloadData(tableFullData);
|
|
28487
|
+
});
|
|
28488
|
+
}
|
|
28440
28489
|
}
|
|
28441
28490
|
},
|
|
28442
28491
|
created() {
|
|
@@ -28445,6 +28494,8 @@ function renderBody(h, $xeTable) {
|
|
|
28445
28494
|
const internalData = $xeTable;
|
|
28446
28495
|
Object.assign($xeTable, {
|
|
28447
28496
|
tZindex: 0,
|
|
28497
|
+
currKeyField: '',
|
|
28498
|
+
isCurrDeepKey: false,
|
|
28448
28499
|
elemStore: {},
|
|
28449
28500
|
// 存放横向 X 虚拟滚动相关的信息
|
|
28450
28501
|
scrollXStore: {
|
|
@@ -28551,6 +28602,7 @@ function renderBody(h, $xeTable) {
|
|
|
28551
28602
|
swYInterval: 0,
|
|
28552
28603
|
swYTotal: 0
|
|
28553
28604
|
});
|
|
28605
|
+
handleKeyField($xeTable);
|
|
28554
28606
|
const {
|
|
28555
28607
|
data,
|
|
28556
28608
|
exportConfig,
|