vxe-table 3.12.8 → 3.12.10-beta.0
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/grid/src/grid.js +6 -1
- package/es/index.css +1 -1
- package/es/index.min.css +1 -1
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/table/module/export/mixin.js +3 -3
- package/es/table/module/filter/mixin.js +3 -3
- package/es/table/module/keyboard/mixin.js +4 -4
- package/es/table/module/menu/mixin.js +2 -2
- package/es/table/module/validator/mixin.js +2 -2
- package/es/table/src/body.js +262 -363
- package/es/table/src/footer.js +135 -154
- package/es/table/src/header.js +120 -100
- package/es/table/src/methods.js +1175 -816
- package/es/table/src/props.js +9 -3
- package/es/table/src/table.js +187 -103
- package/es/table/src/util.js +35 -21
- package/es/table/style.css +146 -63
- package/es/table/style.min.css +1 -1
- package/es/ui/index.js +14 -4
- package/es/ui/src/log.js +1 -1
- package/es/vxe-table/style.css +146 -63
- package/es/vxe-table/style.min.css +1 -1
- package/lib/grid/src/grid.js +4 -1
- package/lib/grid/src/grid.min.js +1 -1
- package/lib/index.css +1 -1
- package/lib/index.min.css +1 -1
- package/lib/index.umd.js +1920 -1599
- package/lib/index.umd.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/table/module/export/mixin.js +3 -3
- package/lib/table/module/export/mixin.min.js +1 -1
- package/lib/table/module/filter/mixin.js +4 -4
- package/lib/table/module/filter/mixin.min.js +1 -1
- package/lib/table/module/keyboard/mixin.js +5 -5
- package/lib/table/module/keyboard/mixin.min.js +1 -1
- package/lib/table/module/menu/mixin.js +2 -2
- package/lib/table/module/menu/mixin.min.js +1 -1
- package/lib/table/module/validator/mixin.js +2 -2
- package/lib/table/module/validator/mixin.min.js +1 -1
- package/lib/table/src/body.js +205 -381
- package/lib/table/src/body.min.js +1 -1
- package/lib/table/src/footer.js +124 -151
- package/lib/table/src/footer.min.js +1 -1
- package/lib/table/src/header.js +97 -74
- package/lib/table/src/header.min.js +1 -1
- package/lib/table/src/methods.js +1261 -875
- package/lib/table/src/methods.min.js +1 -1
- package/lib/table/src/props.js +9 -3
- package/lib/table/src/props.min.js +1 -1
- package/lib/table/src/table.js +171 -90
- package/lib/table/src/table.min.js +1 -1
- package/lib/table/src/util.js +38 -22
- package/lib/table/src/util.min.js +1 -1
- package/lib/table/style/style.css +146 -63
- package/lib/table/style/style.min.css +1 -1
- package/lib/ui/index.js +14 -4
- 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/lib/vxe-table/style/style.css +146 -63
- package/lib/vxe-table/style/style.min.css +1 -1
- package/package.json +2 -2
- package/packages/grid/src/grid.ts +6 -1
- package/packages/table/module/export/mixin.ts +3 -3
- package/packages/table/module/filter/mixin.ts +3 -3
- package/packages/table/module/keyboard/mixin.ts +4 -4
- package/packages/table/module/menu/mixin.ts +2 -2
- package/packages/table/module/validator/mixin.ts +2 -2
- package/packages/table/src/body.ts +296 -436
- package/packages/table/src/footer.ts +148 -164
- package/packages/table/src/header.ts +135 -111
- package/packages/table/src/methods.ts +1249 -873
- package/packages/table/src/props.ts +9 -3
- package/packages/table/src/table.ts +195 -146
- package/packages/table/src/util.ts +40 -23
- package/packages/ui/index.ts +13 -3
- package/styles/components/table.scss +164 -74
- /package/es/{iconfont.1736406699090.ttf → iconfont.1736688976404.ttf} +0 -0
- /package/es/{iconfont.1736406699090.woff → iconfont.1736688976404.woff} +0 -0
- /package/es/{iconfont.1736406699090.woff2 → iconfont.1736688976404.woff2} +0 -0
- /package/lib/{iconfont.1736406699090.ttf → iconfont.1736688976404.ttf} +0 -0
- /package/lib/{iconfont.1736406699090.woff → iconfont.1736688976404.woff} +0 -0
- /package/lib/{iconfont.1736406699090.woff2 → iconfont.1736688976404.woff2} +0 -0
|
@@ -220,11 +220,17 @@ export default {
|
|
|
220
220
|
// 空内容渲染配置项
|
|
221
221
|
emptyRender: [Boolean, Object],
|
|
222
222
|
// 自定义列配置项
|
|
223
|
-
customConfig:
|
|
223
|
+
customConfig: Object as PropType<VxeTablePropTypes.CustomConfig>,
|
|
224
|
+
// (即将废弃)横向虚拟滚动配置项
|
|
225
|
+
scrollX: Object as PropType<VxeTablePropTypes.ScrollX>,
|
|
226
|
+
// (即将废弃)纵向虚拟滚动配置项
|
|
227
|
+
scrollY: Object as PropType<VxeTablePropTypes.ScrollY>,
|
|
224
228
|
// 横向虚拟滚动配置项
|
|
225
|
-
|
|
229
|
+
virtualXConfig: Object as PropType<VxeTablePropTypes.VirtualXConfig>,
|
|
226
230
|
// 纵向虚拟滚动配置项
|
|
227
|
-
|
|
231
|
+
virtualYConfig: Object as PropType<VxeTablePropTypes.VirtualYConfig>,
|
|
232
|
+
// 滚动条配置项
|
|
233
|
+
scrollbarConfig: Object as PropType<VxeTablePropTypes.ScrollbarConfig>,
|
|
228
234
|
// (即将废弃)优化相关
|
|
229
235
|
animat: { type: Boolean, default: () => getConfig().table.animat },
|
|
230
236
|
// (可能会被废弃的参数,不要使用)
|
|
@@ -25,6 +25,7 @@ import validatorMixin from '../module/validator/mixin'
|
|
|
25
25
|
import customMixin from '../module/custom/mixin'
|
|
26
26
|
|
|
27
27
|
import type { VxeLoadingComponent, VxeTooltipComponent, VxeTabsConstructor, VxeTabsPrivateMethods } from 'vxe-pc-ui'
|
|
28
|
+
import type { VxeTableConstructor, VxeTablePrivateMethods, TableInternalData, TableReactData } from '../../../types'
|
|
28
29
|
|
|
29
30
|
const { getConfig, getIcon, getI18n, renderer, globalResize, globalEvents, globalMixins, renderEmptyElement } = VxeUI
|
|
30
31
|
|
|
@@ -38,10 +39,11 @@ const { getConfig, getIcon, getI18n, renderer, globalResize, globalEvents, globa
|
|
|
38
39
|
*/
|
|
39
40
|
function renderFixed (h: CreateElement, $xetable: any, fixedType: any) {
|
|
40
41
|
const { _e, tableData, tableColumn, tableGroupColumn, vSize, showHeader, showFooter, columnStore, footerTableData } = $xetable
|
|
42
|
+
const isFixedLeft = fixedType === 'left'
|
|
41
43
|
const fixedColumn = columnStore[`${fixedType}List`]
|
|
42
44
|
return h('div', {
|
|
43
|
-
|
|
44
|
-
|
|
45
|
+
ref: isFixedLeft ? 'refLeftContainer' : 'refRightContainer',
|
|
46
|
+
class: `vxe-table--fixed-${fixedType}-wrapper`
|
|
45
47
|
}, [
|
|
46
48
|
showHeader
|
|
47
49
|
? h(TableHeaderComponent, {
|
|
@@ -215,7 +217,9 @@ export default {
|
|
|
215
217
|
}
|
|
216
218
|
},
|
|
217
219
|
data () {
|
|
220
|
+
const xID = XEUtils.uniqueId()
|
|
218
221
|
return {
|
|
222
|
+
xID,
|
|
219
223
|
tId: `${XEUtils.uniqueId()}`,
|
|
220
224
|
isCalcColumn: false,
|
|
221
225
|
// 低性能的静态列
|
|
@@ -441,7 +445,7 @@ export default {
|
|
|
441
445
|
dragTipText: '',
|
|
442
446
|
|
|
443
447
|
_isResize: false,
|
|
444
|
-
|
|
448
|
+
isLoading: false
|
|
445
449
|
}
|
|
446
450
|
},
|
|
447
451
|
computed: {
|
|
@@ -471,7 +475,7 @@ export default {
|
|
|
471
475
|
return this.computeSXOpts
|
|
472
476
|
},
|
|
473
477
|
computeSXOpts () {
|
|
474
|
-
return
|
|
478
|
+
return this.computeVirtualXOpts
|
|
475
479
|
},
|
|
476
480
|
computeScrollXThreshold () {
|
|
477
481
|
const $xeTable = this
|
|
@@ -487,7 +491,25 @@ export default {
|
|
|
487
491
|
return this.computeSYOpts
|
|
488
492
|
},
|
|
489
493
|
computeSYOpts () {
|
|
490
|
-
return
|
|
494
|
+
return this.computeVirtualYOpts
|
|
495
|
+
},
|
|
496
|
+
computeVirtualXOpts () {
|
|
497
|
+
const $xeTable = this
|
|
498
|
+
const props = $xeTable
|
|
499
|
+
|
|
500
|
+
return Object.assign({}, getConfig().table.scrollX, getConfig().table.virtualXConfig, props.scrollX, props.virtualXConfig)
|
|
501
|
+
},
|
|
502
|
+
computeVirtualYOpts () {
|
|
503
|
+
const $xeTable = this
|
|
504
|
+
const props = $xeTable
|
|
505
|
+
|
|
506
|
+
return Object.assign({}, getConfig().table.scrollY, getConfig().table.virtualYConfig, props.scrollY, props.virtualYConfig)
|
|
507
|
+
},
|
|
508
|
+
computeScrollbarOpts () {
|
|
509
|
+
const $xeTable = this
|
|
510
|
+
const props = $xeTable
|
|
511
|
+
|
|
512
|
+
return Object.assign({}, getConfig().table.scrollbarConfig, props.scrollbarConfig)
|
|
491
513
|
},
|
|
492
514
|
computeScrollYThreshold () {
|
|
493
515
|
const $xeTable = this
|
|
@@ -510,6 +532,13 @@ export default {
|
|
|
510
532
|
mini: 36
|
|
511
533
|
}
|
|
512
534
|
},
|
|
535
|
+
computeDefaultRowHeight () {
|
|
536
|
+
const $xeTable = this
|
|
537
|
+
|
|
538
|
+
const vSize = $xeTable.computeSize
|
|
539
|
+
const rowHeightMaps = $xeTable.computeRowHeightMaps
|
|
540
|
+
return rowHeightMaps[vSize || 'default']
|
|
541
|
+
},
|
|
513
542
|
columnOpts () {
|
|
514
543
|
return this.computeColumnOpts
|
|
515
544
|
},
|
|
@@ -651,6 +680,32 @@ export default {
|
|
|
651
680
|
computeMenuOpts () {
|
|
652
681
|
return Object.assign({}, getConfig().table.menuConfig, this.contextMenu, this.menuConfig)
|
|
653
682
|
},
|
|
683
|
+
computeLeftFixedWidth () {
|
|
684
|
+
const $xeTable = this
|
|
685
|
+
const reactData = $xeTable as TableReactData
|
|
686
|
+
|
|
687
|
+
const { columnStore } = reactData
|
|
688
|
+
const { leftList } = columnStore
|
|
689
|
+
let leftWidth = 0
|
|
690
|
+
for (let i = 0; i < leftList.length; i++) {
|
|
691
|
+
const column = leftList[i]
|
|
692
|
+
leftWidth += column.renderWidth
|
|
693
|
+
}
|
|
694
|
+
return leftWidth
|
|
695
|
+
},
|
|
696
|
+
computeRightFixedWidth () {
|
|
697
|
+
const $xeTable = this
|
|
698
|
+
const reactData = $xeTable as TableReactData
|
|
699
|
+
|
|
700
|
+
const { columnStore } = reactData
|
|
701
|
+
const { rightList } = columnStore
|
|
702
|
+
let leftWidth = 0
|
|
703
|
+
for (let i = 0; i < rightList.length; i++) {
|
|
704
|
+
const column = rightList[i]
|
|
705
|
+
leftWidth += column.renderWidth
|
|
706
|
+
}
|
|
707
|
+
return leftWidth
|
|
708
|
+
},
|
|
654
709
|
exportOpts () {
|
|
655
710
|
return this.computeExportOpts
|
|
656
711
|
},
|
|
@@ -693,7 +748,7 @@ export default {
|
|
|
693
748
|
computeLoadingOpts () {
|
|
694
749
|
return Object.assign({}, getConfig().table.loadingConfig, this.loadingConfig)
|
|
695
750
|
},
|
|
696
|
-
|
|
751
|
+
computeCellOffsetWidth () {
|
|
697
752
|
return this.border ? Math.max(2, Math.ceil(this.scrollbarWidth / this.tableColumn.length)) : 1
|
|
698
753
|
},
|
|
699
754
|
customOpts () {
|
|
@@ -707,9 +762,9 @@ export default {
|
|
|
707
762
|
return tableColumn.length || visibleColumn.length ? visibleColumn.filter((column: any) => column.width === 'auto' || column.minWidth === 'auto') : []
|
|
708
763
|
},
|
|
709
764
|
computeFixedColumnSize () {
|
|
710
|
-
const $xeTable = this
|
|
711
|
-
const reactData = $xeTable
|
|
712
|
-
const internalData = $xeTable
|
|
765
|
+
const $xeTable = this as VxeTableConstructor & VxeTablePrivateMethods
|
|
766
|
+
const reactData = $xeTable as unknown as TableReactData
|
|
767
|
+
const internalData = $xeTable as unknown as TableInternalData
|
|
713
768
|
|
|
714
769
|
const { tableColumn } = reactData
|
|
715
770
|
const { collectColumn } = internalData
|
|
@@ -873,16 +928,21 @@ export default {
|
|
|
873
928
|
elemStore: {},
|
|
874
929
|
// 存放横向 X 虚拟滚动相关的信息
|
|
875
930
|
scrollXStore: {
|
|
931
|
+
preloadSize: 0,
|
|
876
932
|
offsetSize: 0,
|
|
877
933
|
visibleSize: 0,
|
|
934
|
+
visibleStartIndex: 0,
|
|
935
|
+
visibleEndIndex: 0,
|
|
878
936
|
startIndex: 0,
|
|
879
937
|
endIndex: 0
|
|
880
938
|
},
|
|
881
939
|
// 存放纵向 Y 虚拟滚动相关信息
|
|
882
940
|
scrollYStore: {
|
|
883
|
-
|
|
941
|
+
preloadSize: 0,
|
|
884
942
|
offsetSize: 0,
|
|
885
943
|
visibleSize: 0,
|
|
944
|
+
visibleStartIndex: 0,
|
|
945
|
+
visibleEndIndex: 0,
|
|
886
946
|
startIndex: 0,
|
|
887
947
|
endIndex: 0
|
|
888
948
|
},
|
|
@@ -924,7 +984,11 @@ export default {
|
|
|
924
984
|
fullDataRowIdData: {},
|
|
925
985
|
fullColumnMap: new Map(),
|
|
926
986
|
fullColumnIdData: {},
|
|
927
|
-
fullColumnFieldData: {}
|
|
987
|
+
fullColumnFieldData: {},
|
|
988
|
+
|
|
989
|
+
swYSize: 0,
|
|
990
|
+
swYInterval: 0,
|
|
991
|
+
swYTotal: 0
|
|
928
992
|
})
|
|
929
993
|
|
|
930
994
|
if (process.env.VUE_APP_VXE_ENV === 'development') {
|
|
@@ -1203,65 +1267,38 @@ export default {
|
|
|
1203
1267
|
const VxeUILoadingComponent = VxeUI.getComponent<VxeLoadingComponent>('VxeLoading')
|
|
1204
1268
|
const VxeUITooltipComponent = VxeUI.getComponent<VxeTooltipComponent>('VxeTooltip')
|
|
1205
1269
|
|
|
1206
|
-
const $xeTable = this
|
|
1270
|
+
const $xeTable = this as VxeTableConstructor & VxeTablePrivateMethods
|
|
1207
1271
|
const $xeGrid = $xeTable.$xeGrid
|
|
1272
|
+
const props = $xeTable
|
|
1273
|
+
const slots = $xeTable.$scopedSlots
|
|
1274
|
+
const reactData = $xeTable as unknown as TableReactData
|
|
1275
|
+
|
|
1276
|
+
const { xID } = $xeTable
|
|
1208
1277
|
|
|
1209
|
-
const {
|
|
1210
|
-
|
|
1211
|
-
$scopedSlots,
|
|
1212
|
-
tId,
|
|
1213
|
-
isCalcColumn,
|
|
1214
|
-
tableData,
|
|
1215
|
-
tableColumn,
|
|
1216
|
-
tableGroupColumn,
|
|
1217
|
-
isGroup,
|
|
1218
|
-
loading,
|
|
1219
|
-
stripe,
|
|
1220
|
-
showHeader,
|
|
1221
|
-
height,
|
|
1222
|
-
treeOpts,
|
|
1223
|
-
treeConfig,
|
|
1224
|
-
mouseConfig,
|
|
1225
|
-
mouseOpts,
|
|
1226
|
-
areaOpts,
|
|
1227
|
-
computeSize,
|
|
1228
|
-
validOpts,
|
|
1229
|
-
showFooter,
|
|
1230
|
-
overflowX,
|
|
1231
|
-
overflowY,
|
|
1232
|
-
scrollXLoad,
|
|
1233
|
-
scrollYLoad,
|
|
1234
|
-
scrollbarHeight,
|
|
1235
|
-
highlightCell,
|
|
1236
|
-
highlightHoverRow,
|
|
1237
|
-
highlightHoverColumn,
|
|
1238
|
-
editConfig,
|
|
1239
|
-
validTipOpts,
|
|
1240
|
-
initStore,
|
|
1241
|
-
columnStore,
|
|
1242
|
-
filterStore,
|
|
1243
|
-
customStore,
|
|
1244
|
-
ctxMenuStore,
|
|
1245
|
-
ctxMenuOpts,
|
|
1246
|
-
footerTableData,
|
|
1247
|
-
columnOpts,
|
|
1248
|
-
rowOpts,
|
|
1249
|
-
checkboxOpts,
|
|
1250
|
-
loadingOpts,
|
|
1251
|
-
resizableOpts,
|
|
1252
|
-
editRules
|
|
1253
|
-
} = $xeTable
|
|
1278
|
+
const { loading, stripe, showHeader, height, treeConfig, mouseConfig, showFooter, highlightCell, highlightHoverRow, highlightHoverColumn, editConfig, editRules } = props
|
|
1279
|
+
const { isCalcColumn, isGroup, overflowX, overflowY, scrollXLoad, scrollYLoad, scrollbarHeight, tableData, tableColumn, tableGroupColumn, footerTableData, initStore, columnStore, filterStore, customStore, tooltipStore } = reactData
|
|
1254
1280
|
const { leftList, rightList } = columnStore
|
|
1255
|
-
const loadingSlot =
|
|
1256
|
-
const
|
|
1257
|
-
const
|
|
1281
|
+
const loadingSlot = slots.loading
|
|
1282
|
+
const tooltipOpts = $xeTable.computeTooltipOpts
|
|
1283
|
+
const validOpts = $xeTable.computeValidOpts
|
|
1284
|
+
const checkboxOpts = $xeTable.computeCheckboxOpts
|
|
1285
|
+
const treeOpts = $xeTable.computeTreeOpts
|
|
1286
|
+
const rowOpts = $xeTable.computeRowOpts
|
|
1287
|
+
const columnOpts = $xeTable.computeColumnOpts
|
|
1288
|
+
const vSize = $xeTable.computeSize
|
|
1258
1289
|
const tableBorder = $xeTable.computeTableBorder
|
|
1259
|
-
const
|
|
1290
|
+
const mouseOpts = $xeTable.computeMouseOpts
|
|
1291
|
+
const areaOpts = $xeTable.computeAreaOpts
|
|
1292
|
+
const loadingOpts = $xeTable.computeLoadingOpts
|
|
1293
|
+
const isMenu = $xeTable.computeIsMenu
|
|
1294
|
+
const currLoading = reactData.isLoading || loading
|
|
1295
|
+
const resizableOpts = $xeTable.computeResizableOpts
|
|
1260
1296
|
const isArea = mouseConfig && mouseOpts.area
|
|
1261
1297
|
const columnDragOpts = $xeTable.computeColumnDragOpts
|
|
1262
1298
|
return h('div', {
|
|
1263
1299
|
ref: 'refElem',
|
|
1264
|
-
class: ['vxe-table', 'vxe-table--render-default', `tid_${
|
|
1300
|
+
class: ['vxe-table', 'vxe-table--render-default', `tid_${xID}`, `border--${tableBorder}`, {
|
|
1301
|
+
[`size--${vSize}`]: vSize,
|
|
1265
1302
|
[`valid-msg--${validOpts.msgMode}`]: !!editRules,
|
|
1266
1303
|
'vxe-editable': !!editConfig,
|
|
1267
1304
|
'old-cell-valid': editRules && getConfig().cellVaildMode === 'obsolete',
|
|
@@ -1281,9 +1318,9 @@ export default {
|
|
|
1281
1318
|
'is--tree-line': treeConfig && (treeOpts.showLine || treeOpts.line),
|
|
1282
1319
|
'is--fixed-left': leftList.length,
|
|
1283
1320
|
'is--fixed-right': rightList.length,
|
|
1284
|
-
'is--animat': !!
|
|
1285
|
-
'is--padding':
|
|
1286
|
-
'is--round':
|
|
1321
|
+
'is--animat': !!props.animat,
|
|
1322
|
+
'is--padding': props.padding,
|
|
1323
|
+
'is--round': props.round,
|
|
1287
1324
|
'is--stripe': !treeConfig && stripe,
|
|
1288
1325
|
'is--loading': currLoading,
|
|
1289
1326
|
'is--empty': !currLoading && !tableData.length,
|
|
@@ -1311,100 +1348,112 @@ export default {
|
|
|
1311
1348
|
class: 'vxe-table--render-wrapper'
|
|
1312
1349
|
}, [
|
|
1313
1350
|
h('div', {
|
|
1314
|
-
|
|
1351
|
+
ref: 'refTableViewportElem',
|
|
1352
|
+
class: 'vxe-table--viewport-wrapper'
|
|
1315
1353
|
}, [
|
|
1354
|
+
h('div', {
|
|
1355
|
+
class: 'vxe-table--main-wrapper'
|
|
1356
|
+
}, [
|
|
1316
1357
|
/**
|
|
1317
1358
|
* 表头
|
|
1318
1359
|
*/
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1360
|
+
showHeader
|
|
1361
|
+
? h(TableHeaderComponent, {
|
|
1362
|
+
ref: 'refTableHeader',
|
|
1363
|
+
props: {
|
|
1364
|
+
tableData,
|
|
1365
|
+
tableColumn,
|
|
1366
|
+
tableGroupColumn,
|
|
1367
|
+
size: vSize
|
|
1368
|
+
}
|
|
1369
|
+
})
|
|
1370
|
+
: renderEmptyElement($xeTable),
|
|
1371
|
+
/**
|
|
1372
|
+
* 表体
|
|
1373
|
+
*/
|
|
1374
|
+
h(TableBodyComponent, {
|
|
1375
|
+
ref: 'refTableBody',
|
|
1322
1376
|
props: {
|
|
1323
1377
|
tableData,
|
|
1324
1378
|
tableColumn,
|
|
1325
|
-
tableGroupColumn,
|
|
1326
1379
|
size: vSize
|
|
1327
1380
|
}
|
|
1328
|
-
})
|
|
1329
|
-
|
|
1330
|
-
/**
|
|
1331
|
-
* 表体
|
|
1332
|
-
*/
|
|
1333
|
-
h(TableBodyComponent, {
|
|
1334
|
-
ref: 'tableBody',
|
|
1335
|
-
props: {
|
|
1336
|
-
tableData,
|
|
1337
|
-
tableColumn,
|
|
1338
|
-
size: vSize
|
|
1339
|
-
}
|
|
1340
|
-
}),
|
|
1341
|
-
/**
|
|
1381
|
+
}),
|
|
1382
|
+
/**
|
|
1342
1383
|
* 表尾
|
|
1343
1384
|
*/
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
h('div', {
|
|
1356
|
-
class: 'vxe-table--fixed-wrapper'
|
|
1357
|
-
}, [
|
|
1358
|
-
leftList && leftList.length && overflowX ? renderFixed(h, this, 'left') : _e(),
|
|
1359
|
-
rightList && rightList.length && overflowX ? renderFixed(h, this, 'right') : _e()
|
|
1360
|
-
])
|
|
1361
|
-
]),
|
|
1362
|
-
virtualScrollBars.x
|
|
1363
|
-
? h('div', {
|
|
1364
|
-
key: 'vx',
|
|
1365
|
-
ref: 'refScrollXVirtualElem',
|
|
1366
|
-
class: 'vxe-table--scroll-x-virtual'
|
|
1367
|
-
}, [
|
|
1385
|
+
showFooter
|
|
1386
|
+
? h(TableFooterComponent, {
|
|
1387
|
+
ref: 'refTableFooter',
|
|
1388
|
+
props: {
|
|
1389
|
+
footerTableData,
|
|
1390
|
+
tableColumn,
|
|
1391
|
+
size: vSize
|
|
1392
|
+
}
|
|
1393
|
+
})
|
|
1394
|
+
: renderEmptyElement($xeTable)
|
|
1395
|
+
]),
|
|
1368
1396
|
h('div', {
|
|
1369
|
-
|
|
1370
|
-
class: 'vxe-table--scroll-x-handle',
|
|
1371
|
-
on: {
|
|
1372
|
-
scroll: $xeTable.scrollXEvent
|
|
1373
|
-
}
|
|
1397
|
+
class: 'vxe-table--fixed-wrapper'
|
|
1374
1398
|
}, [
|
|
1375
|
-
h
|
|
1376
|
-
|
|
1377
|
-
class: 'vxe-table--scroll-x-space'
|
|
1378
|
-
})
|
|
1399
|
+
leftList && leftList.length && overflowX ? renderFixed(h, this, 'left') : renderEmptyElement($xeTable),
|
|
1400
|
+
rightList && rightList.length && overflowX ? renderFixed(h, this, 'right') : renderEmptyElement($xeTable)
|
|
1379
1401
|
])
|
|
1380
|
-
])
|
|
1381
|
-
|
|
1382
|
-
virtualScrollBars.y
|
|
1383
|
-
? h('div', {
|
|
1384
|
-
key: 'vy',
|
|
1402
|
+
]),
|
|
1403
|
+
h('div', {
|
|
1385
1404
|
ref: 'refScrollYVirtualElem',
|
|
1386
1405
|
class: 'vxe-table--scroll-y-virtual'
|
|
1387
1406
|
}, [
|
|
1407
|
+
h('div', {
|
|
1408
|
+
ref: 'refScrollYTopCornerElem',
|
|
1409
|
+
class: 'vxe-table--scroll-y-top-corner'
|
|
1410
|
+
}),
|
|
1388
1411
|
h('div', {
|
|
1389
1412
|
ref: 'refScrollYHandleElem',
|
|
1390
1413
|
class: 'vxe-table--scroll-y-handle',
|
|
1391
1414
|
on: {
|
|
1392
|
-
scroll:
|
|
1415
|
+
scroll: this.scrollYEvent
|
|
1393
1416
|
}
|
|
1394
1417
|
}, [
|
|
1395
1418
|
h('div', {
|
|
1396
1419
|
ref: 'refScrollYSpaceElem',
|
|
1397
1420
|
class: 'vxe-table--scroll-y-space'
|
|
1398
1421
|
})
|
|
1399
|
-
])
|
|
1422
|
+
]),
|
|
1423
|
+
h('div', {
|
|
1424
|
+
ref: 'refScrollYBottomCornerElem',
|
|
1425
|
+
class: 'vxe-table--scroll-y-bottom-corner'
|
|
1426
|
+
})
|
|
1400
1427
|
])
|
|
1401
|
-
|
|
1428
|
+
]),
|
|
1429
|
+
h('div', {
|
|
1430
|
+
key: 'vx',
|
|
1431
|
+
ref: 'refScrollXVirtualElem',
|
|
1432
|
+
class: 'vxe-table--scroll-x-virtual'
|
|
1433
|
+
}, [
|
|
1434
|
+
h('div', {
|
|
1435
|
+
ref: 'refScrollXHandleElem',
|
|
1436
|
+
class: 'vxe-table--scroll-x-handle',
|
|
1437
|
+
on: {
|
|
1438
|
+
scroll: this.scrollXEvent
|
|
1439
|
+
}
|
|
1440
|
+
}, [
|
|
1441
|
+
h('div', {
|
|
1442
|
+
ref: 'refScrollXSpaceElem',
|
|
1443
|
+
class: 'vxe-table--scroll-x-space'
|
|
1444
|
+
})
|
|
1445
|
+
]),
|
|
1446
|
+
h('div', {
|
|
1447
|
+
ref: 'refScrollXRightCornerElem',
|
|
1448
|
+
class: 'vxe-table--scroll-x-right-corner'
|
|
1449
|
+
})
|
|
1450
|
+
]),
|
|
1402
1451
|
/**
|
|
1403
1452
|
* 空数据
|
|
1404
1453
|
*/
|
|
1405
1454
|
h('div', {
|
|
1406
1455
|
key: 'tn',
|
|
1407
|
-
ref: '
|
|
1456
|
+
ref: 'refEmptyPlaceholder',
|
|
1408
1457
|
class: 'vxe-table--empty-placeholder'
|
|
1409
1458
|
}, [
|
|
1410
1459
|
h('div', {
|
|
@@ -1423,19 +1472,19 @@ export default {
|
|
|
1423
1472
|
*/
|
|
1424
1473
|
h('div', {
|
|
1425
1474
|
key: 'cl',
|
|
1475
|
+
ref: 'refCellResizeBar',
|
|
1426
1476
|
class: 'vxe-table--resizable-bar',
|
|
1427
1477
|
style: overflowX
|
|
1428
1478
|
? {
|
|
1429
1479
|
'padding-bottom': `${scrollbarHeight}px`
|
|
1430
1480
|
}
|
|
1431
|
-
:
|
|
1432
|
-
ref: 'resizeBar'
|
|
1481
|
+
: undefined
|
|
1433
1482
|
}, resizableOpts.showDragTip
|
|
1434
1483
|
? [
|
|
1435
1484
|
h('div', {
|
|
1436
1485
|
ref: 'refCellResizeTip',
|
|
1437
1486
|
class: 'vxe-table--resizable-number-tip'
|
|
1438
|
-
}
|
|
1487
|
+
})
|
|
1439
1488
|
]
|
|
1440
1489
|
: []),
|
|
1441
1490
|
/**
|
|
@@ -1486,7 +1535,7 @@ export default {
|
|
|
1486
1535
|
filterStore
|
|
1487
1536
|
}
|
|
1488
1537
|
})
|
|
1489
|
-
:
|
|
1538
|
+
: renderEmptyElement($xeTable),
|
|
1490
1539
|
/**
|
|
1491
1540
|
* 导入
|
|
1492
1541
|
*/
|
|
@@ -1498,7 +1547,7 @@ export default {
|
|
|
1498
1547
|
storeData: this.importStore
|
|
1499
1548
|
}
|
|
1500
1549
|
})
|
|
1501
|
-
:
|
|
1550
|
+
: renderEmptyElement($xeTable),
|
|
1502
1551
|
/**
|
|
1503
1552
|
* 导出
|
|
1504
1553
|
*/
|
|
@@ -1510,20 +1559,20 @@ export default {
|
|
|
1510
1559
|
storeData: this.exportStore
|
|
1511
1560
|
}
|
|
1512
1561
|
})
|
|
1513
|
-
:
|
|
1562
|
+
: renderEmptyElement($xeTable),
|
|
1514
1563
|
/**
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1564
|
+
* 快捷菜单
|
|
1565
|
+
*/
|
|
1566
|
+
isMenu
|
|
1518
1567
|
? h(TableMenuPanelComponent, {
|
|
1519
1568
|
key: 'tm',
|
|
1520
|
-
ref: '
|
|
1569
|
+
ref: 'refTableMenu',
|
|
1521
1570
|
props: {
|
|
1522
|
-
ctxMenuStore,
|
|
1523
|
-
ctxMenuOpts
|
|
1571
|
+
ctxMenuStore: this.ctxMenuStore,
|
|
1572
|
+
ctxMenuOpts: this.ctxMenuOpts
|
|
1524
1573
|
}
|
|
1525
1574
|
})
|
|
1526
|
-
:
|
|
1575
|
+
: renderEmptyElement($xeTable),
|
|
1527
1576
|
/**
|
|
1528
1577
|
* 拖拽提示
|
|
1529
1578
|
*/
|
|
@@ -1535,13 +1584,13 @@ export default {
|
|
|
1535
1584
|
VxeUITooltipComponent
|
|
1536
1585
|
? h(VxeUITooltipComponent, {
|
|
1537
1586
|
key: 'ctp',
|
|
1538
|
-
ref: '
|
|
1587
|
+
ref: 'refCommTooltip',
|
|
1539
1588
|
props: {
|
|
1540
1589
|
isArrow: false,
|
|
1541
1590
|
enterable: false
|
|
1542
1591
|
}
|
|
1543
1592
|
})
|
|
1544
|
-
:
|
|
1593
|
+
: renderEmptyElement($xeTable),
|
|
1545
1594
|
/**
|
|
1546
1595
|
* 工具提示
|
|
1547
1596
|
*/
|
|
@@ -1549,22 +1598,22 @@ export default {
|
|
|
1549
1598
|
? h(VxeUITooltipComponent, {
|
|
1550
1599
|
key: 'btp',
|
|
1551
1600
|
ref: 'tooltip',
|
|
1552
|
-
props: Object.assign({},
|
|
1601
|
+
props: Object.assign({}, tooltipOpts, tooltipStore.currOpts)
|
|
1553
1602
|
})
|
|
1554
|
-
:
|
|
1603
|
+
: renderEmptyElement($xeTable),
|
|
1555
1604
|
/**
|
|
1556
1605
|
* 校验提示
|
|
1557
1606
|
*/
|
|
1558
1607
|
VxeUITooltipComponent && this.editRules && validOpts.showMessage && (validOpts.message === 'default' ? !height : validOpts.message === 'tooltip')
|
|
1559
1608
|
? h(VxeUITooltipComponent, {
|
|
1560
1609
|
key: 'vtp',
|
|
1561
|
-
ref: '
|
|
1610
|
+
ref: 'refValidTooltip',
|
|
1562
1611
|
class: [{
|
|
1563
1612
|
'old-cell-valid': editRules && getConfig().cellVaildMode === 'obsolete'
|
|
1564
1613
|
}, 'vxe-table--valid-error'],
|
|
1565
|
-
props: validOpts.message === 'tooltip' || tableData.length === 1 ?
|
|
1614
|
+
props: validOpts.message === 'tooltip' || tableData.length === 1 ? Object.assign({ isArrow: false }, tooltipOpts) : {}
|
|
1566
1615
|
})
|
|
1567
|
-
:
|
|
1616
|
+
: renderEmptyElement($xeTable)
|
|
1568
1617
|
])
|
|
1569
1618
|
])
|
|
1570
1619
|
},
|