vxe-table 3.18.0-beta.3 → 3.18.0-beta.4
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 +2 -2
- package/es/style.css +1 -1
- package/es/table/module/custom/mixin.js +10 -3
- package/es/table/module/custom/panel.js +23 -2
- package/es/table/module/keyboard/mixin.js +2 -2
- package/es/table/src/methods.js +39 -11
- package/es/table/src/table.js +9 -1
- package/es/table/src/util.js +1 -0
- package/es/toolbar/src/toolbar.js +42 -23
- package/es/ui/index.js +1 -1
- package/es/ui/src/log.js +1 -1
- package/lib/grid/src/grid.js +2 -2
- package/lib/grid/src/grid.min.js +1 -1
- package/lib/index.umd.js +136 -39
- package/lib/index.umd.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/table/module/custom/mixin.js +10 -3
- package/lib/table/module/custom/mixin.min.js +1 -1
- package/lib/table/module/custom/panel.js +25 -2
- package/lib/table/module/custom/panel.min.js +1 -1
- package/lib/table/module/keyboard/mixin.js +2 -2
- package/lib/table/module/keyboard/mixin.min.js +1 -1
- package/lib/table/src/methods.js +42 -11
- package/lib/table/src/methods.min.js +1 -1
- package/lib/table/src/table.js +9 -1
- package/lib/table/src/table.min.js +1 -1
- package/lib/table/src/util.js +1 -0
- package/lib/table/src/util.min.js +1 -1
- package/lib/toolbar/src/toolbar.js +43 -16
- package/lib/toolbar/src/toolbar.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/grid/src/grid.ts +2 -2
- package/packages/table/module/custom/mixin.ts +10 -3
- package/packages/table/module/custom/panel.ts +24 -2
- package/packages/table/module/keyboard/mixin.ts +2 -2
- package/packages/table/src/methods.ts +39 -11
- package/packages/table/src/table.ts +10 -1
- package/packages/table/src/util.ts +2 -0
- package/packages/toolbar/src/toolbar.ts +43 -23
- /package/es/{iconfont.1755253931426.ttf → iconfont.1755566131950.ttf} +0 -0
- /package/es/{iconfont.1755253931426.woff → iconfont.1755566131950.woff} +0 -0
- /package/es/{iconfont.1755253931426.woff2 → iconfont.1755566131950.woff2} +0 -0
- /package/lib/{iconfont.1755253931426.ttf → iconfont.1755566131950.ttf} +0 -0
- /package/lib/{iconfont.1755253931426.woff → iconfont.1755566131950.woff} +0 -0
- /package/lib/{iconfont.1755253931426.woff2 → iconfont.1755566131950.woff2} +0 -0
package/lib/ui/index.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,"__esModule",{value:!0}),exports.VXETable=void 0,Object.defineProperty(exports,"VxeUI",{enumerable:!0,get:function(){return _core.VxeUI}}),exports.version=exports.validators=exports.use=exports.t=exports.setup=exports.setTheme=exports.setLanguage=exports.setIcon=exports.setI18n=exports.setConfig=exports.saveFile=exports.renderer=exports.readFile=exports.print=exports.modal=exports.menus=exports.log=exports.interceptor=exports.globalResize=exports.globalEvents=exports.getTheme=exports.getIcon=exports.getI18n=exports.getConfig=exports.formats=exports.default=exports.config=exports.commands=exports.clipboard=exports._t=void 0;var _core=require("@vxe-ui/core"),_utils=require("./src/utils");let version=exports.version="3.18.0-beta.
|
|
1
|
+
Object.defineProperty(exports,"__esModule",{value:!0}),exports.VXETable=void 0,Object.defineProperty(exports,"VxeUI",{enumerable:!0,get:function(){return _core.VxeUI}}),exports.version=exports.validators=exports.use=exports.t=exports.setup=exports.setTheme=exports.setLanguage=exports.setIcon=exports.setI18n=exports.setConfig=exports.saveFile=exports.renderer=exports.readFile=exports.print=exports.modal=exports.menus=exports.log=exports.interceptor=exports.globalResize=exports.globalEvents=exports.getTheme=exports.getIcon=exports.getI18n=exports.getConfig=exports.formats=exports.default=exports.config=exports.commands=exports.clipboard=exports._t=void 0;var _core=require("@vxe-ui/core"),_utils=require("./src/utils");let version=exports.version="3.18.0-beta.4",iconPrefix=(_core.VxeUI.version=version,_core.VxeUI.tableVersion=version,_core.VxeUI.setConfig({emptyCell:" ",table:{fit:!0,showHeader:!0,animat:!0,delayHover:250,autoResize:!0,padding:!0,minHeight:144,resizeConfig:{},resizableConfig:{dragMode:"auto",showDragTip:!0,isSyncAutoHeight:!0,isSyncAutoWidth:!0,minHeight:18},radioConfig:{strict:!0},rowDragConfig:{showIcon:!0,animation:!0,showGuidesStatus:!0,showDragTip:!0},columnDragConfig:{showIcon:!0,animation:!0,showGuidesStatus:!0,showDragTip:!0},checkboxConfig:{strict:!0},tooltipConfig:{enterable:!0},validConfig:{showMessage:!0,autoClear:!0,autoPos:!0,message:"inline",msgMode:"single",theme:"beautify"},columnConfig:{maxFixedSize:4},cellConfig:{padding:!0},headerCellConfig:{height:"unset"},footerCellConfig:{height:"unset"},customConfig:{allowVisible:!0,allowResizable:!0,allowFixed:!0,allowSort:!0,showFooter:!0,placement:"top-right",storeOptions:{visible:!0,resizable:!0,sort:!0,fixed:!0},modalOptions:{showMaximize:!0,mask:!0,lockView:!0,resize:!0,escClosable:!0},drawerOptions:{mask:!0,lockView:!0,escClosable:!0,resize:!0}},sortConfig:{showIcon:!0,allowClear:!0,allowBtn:!0,iconLayout:"vertical"},filterConfig:{multiple:!0,showIcon:!0},aggregateConfig:{padding:!0,rowField:"id",parentField:"_X_ROW_PARENT_KEY",childrenField:"_X_ROW_CHILDREN",mapChildrenField:"_X_ROW_CHILD_LIST",indent:20,showIcon:!0,maxGroupSize:4,showAggFuncTitle:!0},treeConfig:{padding:!0,rowField:"id",parentField:"parentId",childrenField:"children",hasChildField:"hasChild",mapChildrenField:"_X_ROW_CHILD",indent:20,showIcon:!0},expandConfig:{showIcon:!0,mode:"fixed"},editConfig:{showIcon:!0,showAsterisk:!0,autoFocus:!0},importConfig:{_typeMaps:{csv:1,html:1,xml:1,txt:1}},exportConfig:{_typeMaps:{csv:1,html:1,xml:1,txt:1}},printConfig:{},mouseConfig:{extension:!0},keyboardConfig:{isAll:!0,isEsc:!0},areaConfig:{autoClear:!0,selectCellByHeader:!0,selectCellByBody:!0,extendDirection:{top:!0,left:!0,bottom:!0,right:!0}},clipConfig:{isCopy:!0,isCut:!0,isPaste:!0},fnrConfig:{isFind:!0,isReplace:!0},virtualXConfig:{gt:24,preSize:0,oSize:0},virtualYConfig:{gt:100,preSize:1,oSize:0},scrollbarConfig:{x:{visible:!0},y:{visible:!0}}},grid:{formConfig:{enabled:!0},pagerConfig:{enabled:!0},toolbarConfig:{enabled:!0},proxyConfig:{enabled:!0,autoLoad:!0,showLoading:!0,showResponseMsg:!0,showActionMsg:!0,response:{list:null,result:"result",total:"page.total",message:"message"}}},toolbar:{},gantt:{}}),"vxe-table-icon-"),setTheme=(_core.VxeUI.setIcon({TABLE_SORT_ASC:iconPrefix+"caret-up",TABLE_SORT_DESC:iconPrefix+"caret-down",TABLE_FILTER_NONE:iconPrefix+"funnel",TABLE_FILTER_MATCH:iconPrefix+"funnel",TABLE_EDIT:iconPrefix+"edit",TABLE_TITLE_PREFIX:iconPrefix+"question-circle-fill",TABLE_TITLE_SUFFIX:iconPrefix+"question-circle-fill",TABLE_TREE_LOADED:iconPrefix+"spinner roll",TABLE_TREE_OPEN:iconPrefix+"caret-right rotate90",TABLE_TREE_CLOSE:iconPrefix+"caret-right",TABLE_EXPAND_LOADED:iconPrefix+"spinner roll",TABLE_EXPAND_OPEN:iconPrefix+"arrow-right rotate90",TABLE_EXPAND_CLOSE:iconPrefix+"arrow-right",TABLE_CHECKBOX_CHECKED:iconPrefix+"checkbox-checked-fill",TABLE_CHECKBOX_UNCHECKED:iconPrefix+"checkbox-unchecked",TABLE_CHECKBOX_INDETERMINATE:iconPrefix+"checkbox-indeterminate-fill",TABLE_CHECKBOX_DISABLED_UNCHECKED:iconPrefix+"checkbox-unchecked-fill",TABLE_RADIO_CHECKED:iconPrefix+"radio-checked-fill",TABLE_RADIO_UNCHECKED:iconPrefix+"radio-unchecked",TABLE_RADIO_DISABLED_UNCHECKED:iconPrefix+"radio-unchecked-fill",TABLE_CUSTOM_SORT:iconPrefix+"drag-handle",TABLE_MENU_OPTIONS:iconPrefix+"arrow-right",TABLE_DRAG_ROW:iconPrefix+"drag-handle",TABLE_DRAG_COLUMN:iconPrefix+"drag-handle",TABLE_DRAG_STATUS_ROW:iconPrefix+"sort",TABLE_DRAG_STATUS_SUB_ROW:iconPrefix+"add-sub",TABLE_DRAG_STATUS_AGG_GROUP:iconPrefix+"grouping",TABLE_DRAG_STATUS_AGG_VALUES:iconPrefix+"values",TABLE_DRAG_STATUS_COLUMN:iconPrefix+"swap",TABLE_DRAG_DISABLED:iconPrefix+"no-drop",TABLE_ROW_GROUP_OPEN:iconPrefix+"arrow-right rotate90",TABLE_ROW_GROUP_CLOSE:iconPrefix+"arrow-right",TABLE_AGGREGATE_GROUPING:iconPrefix+"grouping",TABLE_AGGREGATE_VALUES:iconPrefix+"values",TABLE_AGGREGATE_SORT:iconPrefix+"drag-handle",TABLE_AGGREGATE_DELETE:iconPrefix+"close",TOOLBAR_TOOLS_REFRESH:iconPrefix+"repeat",TOOLBAR_TOOLS_REFRESH_LOADING:iconPrefix+"repeat roll",TOOLBAR_TOOLS_IMPORT:iconPrefix+"upload",TOOLBAR_TOOLS_EXPORT:iconPrefix+"download",TOOLBAR_TOOLS_PRINT:iconPrefix+"print",TOOLBAR_TOOLS_FULLSCREEN:iconPrefix+"fullscreen",TOOLBAR_TOOLS_MINIMIZE:iconPrefix+"minimize",TOOLBAR_TOOLS_CUSTOM:iconPrefix+"custom-column",TOOLBAR_TOOLS_FIXED_LEFT:iconPrefix+"fixed-left",TOOLBAR_TOOLS_FIXED_LEFT_ACTIVE:iconPrefix+"fixed-left-fill",TOOLBAR_TOOLS_FIXED_RIGHT:iconPrefix+"fixed-right",TOOLBAR_TOOLS_FIXED_RIGHT_ACTIVE:iconPrefix+"fixed-right-fill"}),exports.setTheme=_core.VxeUI.setTheme),getTheme=exports.getTheme=_core.VxeUI.getTheme,setConfig=exports.setConfig=_core.VxeUI.setConfig,getConfig=exports.getConfig=_core.VxeUI.getConfig,setIcon=exports.setIcon=_core.VxeUI.setIcon,getIcon=exports.getIcon=_core.VxeUI.getIcon,setLanguage=exports.setLanguage=_core.VxeUI.setLanguage,setI18n=exports.setI18n=_core.VxeUI.setI18n,getI18n=exports.getI18n=_core.VxeUI.getI18n,globalEvents=exports.globalEvents=_core.VxeUI.globalEvents,globalResize=exports.globalResize=_core.VxeUI.globalResize,renderer=exports.renderer=_core.VxeUI.renderer,validators=exports.validators=_core.VxeUI.validators,menus=exports.menus=_core.VxeUI.menus,formats=exports.formats=_core.VxeUI.formats,commands=exports.commands=_core.VxeUI.commands,interceptor=exports.interceptor=_core.VxeUI.interceptor,clipboard=exports.clipboard=_core.VxeUI.clipboard,log=exports.log=_core.VxeUI.log,use=exports.use=_core.VxeUI.use,setup=e=>_core.VxeUI.setConfig(e),config=(exports.setup=setup,_core.VxeUI.setup=setup,e=>_core.VxeUI.setConfig(e)),t=(exports.config=config,_core.VxeUI.config=config,(e,o)=>_core.VxeUI.getI18n(e,o)),_t=(exports.t=t,_core.VxeUI.t=t,(e,o)=>(0,_utils.getFuncText)(e,o)),VXETable=(exports._t=_t,_core.VxeUI._t=_t,exports.VXETable=_core.VxeUI),saveFile=e=>_core.VxeUI.saveFile(e),readFile=(exports.saveFile=saveFile,e=>_core.VxeUI.readFile(e)),print=(exports.readFile=readFile,e=>_core.VxeUI.print(e)),modal=(exports.print=print,exports.modal={get(e){return _core.VxeUI.modal.get(e)},close(e){return _core.VxeUI.modal.close(e)},open(e){return _core.VxeUI.modal.open(e)},alert(e,o,i){return _core.VxeUI.modal.alert(e,o,i)},confirm(e,o,i){return _core.VxeUI.modal.confirm(e,o,i)},message(e,o){return _core.VxeUI.modal.message(e,o)},notification(e,o,i){return _core.VxeUI.modal.notification(e,o,i)}});var _default=exports.default=_core.VxeUI;
|
package/lib/ui/src/log.js
CHANGED
|
@@ -8,6 +8,6 @@ var _core = require("@vxe-ui/core");
|
|
|
8
8
|
const {
|
|
9
9
|
log
|
|
10
10
|
} = _core.VxeUI;
|
|
11
|
-
const version = `table v${"3.18.0-beta.
|
|
11
|
+
const version = `table v${"3.18.0-beta.4"}`;
|
|
12
12
|
const warnLog = exports.warnLog = log.create('warn', version);
|
|
13
13
|
const errLog = exports.errLog = log.create('error', version);
|
package/lib/ui/src/log.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,"__esModule",{value:!0}),exports.warnLog=exports.errLog=void 0;var _core=require("@vxe-ui/core");let log=_core.VxeUI.log,version="table v3.18.0-beta.
|
|
1
|
+
Object.defineProperty(exports,"__esModule",{value:!0}),exports.warnLog=exports.errLog=void 0;var _core=require("@vxe-ui/core");let log=_core.VxeUI.log,version="table v3.18.0-beta.4",warnLog=exports.warnLog=log.create("warn",version),errLog=exports.errLog=log.create("error",version);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vxe-table",
|
|
3
|
-
"version": "3.18.0-beta.
|
|
3
|
+
"version": "3.18.0-beta.4",
|
|
4
4
|
"description": "A PC-end table component based on Vxe UI, supporting copy-paste, data pivot table, and high-performance virtual list table solution.",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"update": "npm install --legacy-peer-deps",
|
|
@@ -414,7 +414,7 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
414
414
|
}
|
|
415
415
|
}
|
|
416
416
|
},
|
|
417
|
-
callSlot (slotFunc: any, params: any, h: CreateElement
|
|
417
|
+
callSlot (slotFunc: any, params: any, h: CreateElement) {
|
|
418
418
|
const $xeGrid = this
|
|
419
419
|
const slots = $xeGrid.$scopedSlots
|
|
420
420
|
|
|
@@ -423,7 +423,7 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
423
423
|
slotFunc = slots[slotFunc] || null
|
|
424
424
|
}
|
|
425
425
|
if (XEUtils.isFunction(slotFunc)) {
|
|
426
|
-
return getSlotVNs(slotFunc.call(this, params, h
|
|
426
|
+
return getSlotVNs(slotFunc.call(this, params, h))
|
|
427
427
|
}
|
|
428
428
|
}
|
|
429
429
|
return []
|
|
@@ -4,14 +4,21 @@ import { getColumnList } from '../../src/util'
|
|
|
4
4
|
import type { VxeColumnPropTypes, VxeTableConstructor, VxeTablePrivateMethods, VxeTableDefines, TableReactData, TableInternalData } from '../../../../types'
|
|
5
5
|
|
|
6
6
|
function calcMaxHeight ($xeTable: VxeTableConstructor & VxeTablePrivateMethods) {
|
|
7
|
+
const $xeGantt = $xeTable.$xeGantt
|
|
7
8
|
const reactData = $xeTable as unknown as TableReactData
|
|
8
9
|
|
|
9
10
|
const { customStore } = reactData
|
|
10
|
-
|
|
11
|
+
let wrapperEl = $xeTable.$refs.refElem as HTMLDivElement
|
|
11
12
|
// 判断面板不能大于表格高度
|
|
12
13
|
let tableHeight = 0
|
|
13
|
-
if (
|
|
14
|
-
|
|
14
|
+
if ($xeGantt) {
|
|
15
|
+
const ganttContainerElem = $xeGantt.$refs.refGanttContainerElem as HTMLDivElement
|
|
16
|
+
if (ganttContainerElem) {
|
|
17
|
+
wrapperEl = ganttContainerElem
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
if (wrapperEl) {
|
|
21
|
+
tableHeight = wrapperEl.clientHeight - 28
|
|
15
22
|
}
|
|
16
23
|
customStore.maxHeight = Math.max(88, tableHeight)
|
|
17
24
|
}
|
|
@@ -287,6 +287,7 @@ const renderSimplePanel = (h: CreateElement, _vm: any) => {
|
|
|
287
287
|
}
|
|
288
288
|
})
|
|
289
289
|
return h('div', {
|
|
290
|
+
ref: 'refElem',
|
|
290
291
|
key: 'simple',
|
|
291
292
|
class: ['vxe-table-custom-wrapper', `placement--${placement}`, {
|
|
292
293
|
'is--active': customStore.visible
|
|
@@ -440,7 +441,7 @@ const renderPopupPanel = (h: CreateElement, $xeTableCustomPanel: VxeTableCustomP
|
|
|
440
441
|
const VxeUIModalComponent = VxeUI.getComponent('VxeModal')
|
|
441
442
|
const VxeUIDrawerComponent = VxeUI.getComponent('VxeDrawer')
|
|
442
443
|
const VxeUIButtonComponent = VxeUI.getComponent('VxeButton')
|
|
443
|
-
const VxeUINumberInputComponent = VxeUI.getComponent('
|
|
444
|
+
const VxeUINumberInputComponent = VxeUI.getComponent('VxeNumberInput')
|
|
444
445
|
|
|
445
446
|
const _vm = $xeTableCustomPanel as any
|
|
446
447
|
const props = $xeTableCustomPanel
|
|
@@ -925,6 +926,8 @@ export default {
|
|
|
925
926
|
|
|
926
927
|
$xeTableCustomPanel.$nextTick(() => {
|
|
927
928
|
const $xeTable = $xeTableCustomPanel.$xeTable as VxeTableConstructor & VxeTablePrivateMethods
|
|
929
|
+
const $xeGantt = $xeTable.$xeGantt
|
|
930
|
+
const tableInternalData = $xeTable as unknown as TableInternalData
|
|
928
931
|
|
|
929
932
|
const { customOpts } = $xeTable
|
|
930
933
|
const { mode } = customOpts
|
|
@@ -938,13 +941,32 @@ export default {
|
|
|
938
941
|
errLog('vxe.error.reqComp', ['vxe-button'])
|
|
939
942
|
}
|
|
940
943
|
if (!VxeUINumberInputComponent) {
|
|
941
|
-
errLog('vxe.error.reqComp', ['vxe-input'])
|
|
944
|
+
errLog('vxe.error.reqComp', ['vxe-number-input'])
|
|
942
945
|
}
|
|
943
946
|
if (!VxeUIRadioGroupComponent) {
|
|
944
947
|
errLog('vxe.error.reqComp', ['vxe-radio-group'])
|
|
945
948
|
}
|
|
949
|
+
|
|
950
|
+
if ($xeGantt) {
|
|
951
|
+
const { teleportToWrapperElem } = tableInternalData
|
|
952
|
+
const el = $xeTableCustomPanel.$refs.refElem
|
|
953
|
+
if (el && teleportToWrapperElem) {
|
|
954
|
+
teleportToWrapperElem.appendChild(el)
|
|
955
|
+
}
|
|
956
|
+
}
|
|
946
957
|
})
|
|
947
958
|
},
|
|
959
|
+
beforeDestroy () {
|
|
960
|
+
const $xeTableCustomPanel = this as any
|
|
961
|
+
const $xeTable = $xeTableCustomPanel.$xeTable as VxeTableConstructor & VxeTablePrivateMethods
|
|
962
|
+
const $xeGantt = $xeTable.$xeGantt
|
|
963
|
+
if ($xeGantt) {
|
|
964
|
+
const el = $xeTableCustomPanel.$refs.refElem
|
|
965
|
+
if (el && el.parentElement) {
|
|
966
|
+
el.parentElement.removeChild(el)
|
|
967
|
+
}
|
|
968
|
+
}
|
|
969
|
+
},
|
|
948
970
|
render (h: CreateElement) {
|
|
949
971
|
const $xeTableCustomPanel = this as unknown as VxeTableCustomPanelConstructor
|
|
950
972
|
const $xeTable = $xeTableCustomPanel.$xeTable
|
|
@@ -346,8 +346,8 @@ export default {
|
|
|
346
346
|
const $xeTable = this as VxeTableConstructor & VxeTablePrivateMethods
|
|
347
347
|
|
|
348
348
|
const { editConfig, editOpts, handleSelected, checkboxConfig, checkboxOpts, mouseConfig, mouseOpts } = this
|
|
349
|
-
if (mouseConfig && mouseOpts.area && $xeTable.
|
|
350
|
-
return $xeTable.
|
|
349
|
+
if (mouseConfig && mouseOpts.area && $xeTable.triggerCellAreaModnEvent) {
|
|
350
|
+
return $xeTable.triggerCellAreaModnEvent(evnt, params)
|
|
351
351
|
} else {
|
|
352
352
|
if (checkboxConfig && checkboxOpts.range) {
|
|
353
353
|
this.handleCheckboxRangeEvent(evnt, params)
|
|
@@ -422,7 +422,7 @@ function updateScrollYStatus ($xeTable: VxeTableConstructor & VxeTablePrivateMet
|
|
|
422
422
|
// 如果gt为0,则总是启用
|
|
423
423
|
const scrollYLoad = (transform || !treeConfig) && !!virtualYOpts.enabled && virtualYOpts.gt > -1 && (virtualYOpts.gt === 0 || virtualYOpts.gt < allList.length)
|
|
424
424
|
reactData.scrollYLoad = scrollYLoad
|
|
425
|
-
if ($xeGanttView) {
|
|
425
|
+
if ($xeGanttView && $xeGanttView.handleUpdateSYStatus) {
|
|
426
426
|
$xeGanttView.handleUpdateSYStatus(scrollYLoad)
|
|
427
427
|
}
|
|
428
428
|
return scrollYLoad
|
|
@@ -1278,7 +1278,7 @@ function updateStyle ($xeTable: VxeTableConstructor & VxeTablePrivateMethods) {
|
|
|
1278
1278
|
if (mouseConfig && mouseOpts.selected && editStore.selected.row && editStore.selected.column) {
|
|
1279
1279
|
$xeTable.addCellSelectedClass()
|
|
1280
1280
|
}
|
|
1281
|
-
if ($xeGanttView) {
|
|
1281
|
+
if ($xeGanttView && $xeGanttView.handleUpdateStyle) {
|
|
1282
1282
|
$xeGanttView.handleUpdateStyle()
|
|
1283
1283
|
}
|
|
1284
1284
|
return $xeTable.$nextTick()
|
|
@@ -2884,7 +2884,7 @@ function handleLazyRecalculate ($xeTable: VxeTableConstructor & VxeTablePrivateM
|
|
|
2884
2884
|
handleRecalculateStyle($xeTable, reFull, reWidth, reHeight)
|
|
2885
2885
|
)
|
|
2886
2886
|
}
|
|
2887
|
-
if ($xeGanttView) {
|
|
2887
|
+
if ($xeGanttView && $xeGanttView.handleLazyRecalculate) {
|
|
2888
2888
|
$xeGanttView.handleLazyRecalculate()
|
|
2889
2889
|
}
|
|
2890
2890
|
internalData.rceTimeout = setTimeout(() => {
|
|
@@ -4071,7 +4071,7 @@ const Methods = {
|
|
|
4071
4071
|
})
|
|
4072
4072
|
reactData.tableData = tableData
|
|
4073
4073
|
internalData.visibleDataRowIdData = visibleDataRowIdMaps
|
|
4074
|
-
if ($xeGanttView) {
|
|
4074
|
+
if ($xeGanttView && $xeGanttView.updateViewData) {
|
|
4075
4075
|
$xeGanttView.updateViewData()
|
|
4076
4076
|
}
|
|
4077
4077
|
return $xeTable.$nextTick()
|
|
@@ -5062,6 +5062,32 @@ const Methods = {
|
|
|
5062
5062
|
}
|
|
5063
5063
|
return []
|
|
5064
5064
|
},
|
|
5065
|
+
/**
|
|
5066
|
+
* 只对 tree-config 有效,用于树形结构,获取指定行的层级
|
|
5067
|
+
*/
|
|
5068
|
+
getTreeRowLevel (rowOrRowid: any) {
|
|
5069
|
+
const $xeTable = this as VxeTableConstructor & VxeTablePrivateMethods
|
|
5070
|
+
const props = $xeTable
|
|
5071
|
+
const internalData = $xeTable as unknown as TableInternalData
|
|
5072
|
+
|
|
5073
|
+
const { treeConfig } = props
|
|
5074
|
+
const { fullAllDataRowIdData } = internalData
|
|
5075
|
+
if (rowOrRowid && treeConfig) {
|
|
5076
|
+
let rowid
|
|
5077
|
+
if (XEUtils.isString(rowOrRowid)) {
|
|
5078
|
+
rowid = rowOrRowid
|
|
5079
|
+
} else {
|
|
5080
|
+
rowid = getRowid($xeTable, rowOrRowid)
|
|
5081
|
+
}
|
|
5082
|
+
if (rowid) {
|
|
5083
|
+
const rest = fullAllDataRowIdData[rowid]
|
|
5084
|
+
if (rest) {
|
|
5085
|
+
return rest.level
|
|
5086
|
+
}
|
|
5087
|
+
}
|
|
5088
|
+
}
|
|
5089
|
+
return -1
|
|
5090
|
+
},
|
|
5065
5091
|
/**
|
|
5066
5092
|
* 只对 tree-config 有效,获取行的父级
|
|
5067
5093
|
*/
|
|
@@ -5081,7 +5107,9 @@ const Methods = {
|
|
|
5081
5107
|
}
|
|
5082
5108
|
if (rowid) {
|
|
5083
5109
|
const rest = fullAllDataRowIdData[rowid]
|
|
5084
|
-
|
|
5110
|
+
if (rest) {
|
|
5111
|
+
return rest.parent
|
|
5112
|
+
}
|
|
5085
5113
|
}
|
|
5086
5114
|
}
|
|
5087
5115
|
return null
|
|
@@ -7802,7 +7830,7 @@ const Methods = {
|
|
|
7802
7830
|
XEUtils.arrayEach(el.querySelectorAll(`[rowid="${getRowid($xeTable, row)}"]`), elem => addClass(elem, 'row--current'))
|
|
7803
7831
|
}
|
|
7804
7832
|
}
|
|
7805
|
-
if ($xeGanttView) {
|
|
7833
|
+
if ($xeGanttView && $xeGanttView.handleUpdateCurrentRow) {
|
|
7806
7834
|
$xeGanttView.handleUpdateCurrentRow(row)
|
|
7807
7835
|
}
|
|
7808
7836
|
return this.$nextTick()
|
|
@@ -7866,7 +7894,7 @@ const Methods = {
|
|
|
7866
7894
|
if (el) {
|
|
7867
7895
|
XEUtils.arrayEach(el.querySelectorAll('.row--current'), elem => removeClass(elem, 'row--current'))
|
|
7868
7896
|
}
|
|
7869
|
-
if ($xeGanttView) {
|
|
7897
|
+
if ($xeGanttView && $xeGanttView.handleUpdateCurrentRow) {
|
|
7870
7898
|
$xeGanttView.handleUpdateCurrentRow()
|
|
7871
7899
|
}
|
|
7872
7900
|
return $xeTable.$nextTick()
|
|
@@ -7940,7 +7968,7 @@ const Methods = {
|
|
|
7940
7968
|
XEUtils.arrayEach(el.querySelectorAll(`.vxe-body--row[rowid="${getRowid($xeTable, row)}"]`), elem => addClass(elem, 'row--hover'))
|
|
7941
7969
|
}
|
|
7942
7970
|
internalData.hoverRow = row
|
|
7943
|
-
if ($xeGanttView) {
|
|
7971
|
+
if ($xeGanttView && $xeGanttView.handleUpdateHoverRow) {
|
|
7944
7972
|
$xeGanttView.handleUpdateHoverRow(row)
|
|
7945
7973
|
}
|
|
7946
7974
|
},
|
|
@@ -7954,7 +7982,7 @@ const Methods = {
|
|
|
7954
7982
|
XEUtils.arrayEach(el.querySelectorAll('.vxe-body--row.row--hover'), elem => removeClass(elem, 'row--hover'))
|
|
7955
7983
|
}
|
|
7956
7984
|
internalData.hoverRow = null
|
|
7957
|
-
if ($xeGanttView) {
|
|
7985
|
+
if ($xeGanttView && $xeGanttView.handleUpdateHoverRow) {
|
|
7958
7986
|
$xeGanttView.handleUpdateHoverRow()
|
|
7959
7987
|
}
|
|
7960
7988
|
},
|
|
@@ -10807,7 +10835,7 @@ const Methods = {
|
|
|
10807
10835
|
if (isScrollXBig && mouseOpts.area) {
|
|
10808
10836
|
errLog('vxe.error.notProp', ['mouse-config.area'])
|
|
10809
10837
|
}
|
|
10810
|
-
if ($xeGanttView) {
|
|
10838
|
+
if ($xeGanttView && $xeGanttView.handleUpdateSXSpace) {
|
|
10811
10839
|
$xeGanttView.handleUpdateSXSpace()
|
|
10812
10840
|
}
|
|
10813
10841
|
return $xeTable.$nextTick(() => {
|
|
@@ -10932,7 +10960,7 @@ const Methods = {
|
|
|
10932
10960
|
if (isScrollYBig && mouseOpts.area) {
|
|
10933
10961
|
errLog('vxe.error.notProp', ['mouse-config.area'])
|
|
10934
10962
|
}
|
|
10935
|
-
if ($xeGanttView) {
|
|
10963
|
+
if ($xeGanttView && $xeGanttView.handleUpdateSYSpace) {
|
|
10936
10964
|
$xeGanttView.handleUpdateSYSpace()
|
|
10937
10965
|
}
|
|
10938
10966
|
return $xeTable.$nextTick().then(() => {
|
|
@@ -1607,7 +1607,7 @@ export default {
|
|
|
1607
1607
|
if (rowOpts.height && !this.showOverflow) {
|
|
1608
1608
|
warnLog('vxe.error.notProp', ['table.show-overflow'])
|
|
1609
1609
|
}
|
|
1610
|
-
if (!$xeTable.
|
|
1610
|
+
if (!$xeTable.triggerCellAreaModnEvent) {
|
|
1611
1611
|
if (props.areaConfig) {
|
|
1612
1612
|
warnLog('vxe.error.notProp', ['area-config'])
|
|
1613
1613
|
}
|
|
@@ -1783,12 +1783,21 @@ export default {
|
|
|
1783
1783
|
mounted () {
|
|
1784
1784
|
const $xeTable = this
|
|
1785
1785
|
const props = $xeTable
|
|
1786
|
+
const internalData = $xeTable as unknown as TableInternalData
|
|
1787
|
+
const $xeGantt = $xeTable.$xeGantt
|
|
1786
1788
|
|
|
1787
1789
|
const columnOpts = $xeTable.computeColumnOpts
|
|
1788
1790
|
const rowOpts = $xeTable.computeRowOpts
|
|
1789
1791
|
const customOpts = $xeTable.computeCustomOpts
|
|
1790
1792
|
const virtualYOpts = $xeTable.computeVirtualYOpts
|
|
1791
1793
|
|
|
1794
|
+
if ($xeGantt) {
|
|
1795
|
+
const classifyWrapperEl = $xeGantt.$refs.refClassifyWrapperElem as HTMLDivElement
|
|
1796
|
+
if (classifyWrapperEl) {
|
|
1797
|
+
internalData.teleportToWrapperElem = classifyWrapperEl
|
|
1798
|
+
}
|
|
1799
|
+
}
|
|
1800
|
+
|
|
1792
1801
|
if (columnOpts.drag || rowOpts.drag || customOpts.allowSort) {
|
|
1793
1802
|
initTpImg()
|
|
1794
1803
|
}
|
|
@@ -56,6 +56,9 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
56
56
|
inject: {
|
|
57
57
|
$xeGrid: {
|
|
58
58
|
default: null
|
|
59
|
+
},
|
|
60
|
+
$xeGantt: {
|
|
61
|
+
default: null
|
|
59
62
|
}
|
|
60
63
|
},
|
|
61
64
|
data () {
|
|
@@ -76,6 +79,7 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
76
79
|
...({} as {
|
|
77
80
|
computeSize(): VxeComponentSizeType
|
|
78
81
|
$xeGrid(): (VxeGridConstructor & GridPrivateMethods) | null
|
|
82
|
+
$xeGantt(): any
|
|
79
83
|
}),
|
|
80
84
|
computeRefreshOpts () {
|
|
81
85
|
const $xeToolbar = this
|
|
@@ -212,6 +216,8 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
212
216
|
const $xeToolbar = this
|
|
213
217
|
const reactData = $xeToolbar.reactData
|
|
214
218
|
const $xeGrid = $xeToolbar.$xeGrid
|
|
219
|
+
const $xeGantt = $xeToolbar.$xeGantt
|
|
220
|
+
const $xeGGWrapper = $xeGrid || $xeGantt
|
|
215
221
|
|
|
216
222
|
const { isRefresh } = reactData
|
|
217
223
|
const refreshOpts = $xeToolbar.computeRefreshOpts
|
|
@@ -226,9 +232,9 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
226
232
|
} catch (e) {
|
|
227
233
|
reactData.isRefresh = false
|
|
228
234
|
}
|
|
229
|
-
} else if ($
|
|
235
|
+
} else if ($xeGGWrapper) {
|
|
230
236
|
reactData.isRefresh = true
|
|
231
|
-
$
|
|
237
|
+
$xeGGWrapper.triggerToolbarCommitEvent({ code: refreshOpts.code || 'reload' }, $event).catch(() => {}).then(() => {
|
|
232
238
|
reactData.isRefresh = false
|
|
233
239
|
})
|
|
234
240
|
}
|
|
@@ -237,9 +243,11 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
237
243
|
zoomEvent ({ $event }: any) {
|
|
238
244
|
const $xeToolbar = this
|
|
239
245
|
const $xeGrid = $xeToolbar.$xeGrid
|
|
246
|
+
const $xeGantt = $xeToolbar.$xeGantt
|
|
247
|
+
const $xeGGWrapper = $xeGrid || $xeGantt
|
|
240
248
|
|
|
241
|
-
if ($
|
|
242
|
-
$
|
|
249
|
+
if ($xeGGWrapper) {
|
|
250
|
+
$xeGGWrapper.triggerZoomEvent($event)
|
|
243
251
|
} else {
|
|
244
252
|
warnLog('vxe.error.notProp', ['zoom'])
|
|
245
253
|
}
|
|
@@ -356,6 +364,8 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
356
364
|
const $xeToolbar = this
|
|
357
365
|
const internalData = $xeToolbar.internalData
|
|
358
366
|
const $xeGrid = $xeToolbar.$xeGrid
|
|
367
|
+
const $xeGantt = $xeToolbar.$xeGantt
|
|
368
|
+
const $xeGGWrapper = $xeGrid || $xeGantt
|
|
359
369
|
|
|
360
370
|
const { $event } = eventParams
|
|
361
371
|
const { connectTable } = internalData
|
|
@@ -363,11 +373,11 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
363
373
|
const { code } = item
|
|
364
374
|
if (code) {
|
|
365
375
|
$xeToolbar.handleDefaultCodeEvent(eventParams, item, () => {
|
|
366
|
-
if ($
|
|
367
|
-
$
|
|
376
|
+
if ($xeGGWrapper) {
|
|
377
|
+
$xeGGWrapper.triggerToolbarBtnEvent(item, $event)
|
|
368
378
|
} else {
|
|
369
379
|
const gCommandOpts = commands.get(code)
|
|
370
|
-
const params = { code, button: item, $table: $table as VxeTableConstructor, $grid: $xeGrid, $gantt:
|
|
380
|
+
const params = { code, button: item, $table: $table as VxeTableConstructor, $grid: $xeGrid, $gantt: $xeGantt, $event }
|
|
371
381
|
if (gCommandOpts) {
|
|
372
382
|
const tCommandMethod = gCommandOpts.tableCommandMethod || gCommandOpts.commandMethod
|
|
373
383
|
if (tCommandMethod) {
|
|
@@ -385,6 +395,8 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
385
395
|
const $xeToolbar = this
|
|
386
396
|
const internalData = $xeToolbar.internalData
|
|
387
397
|
const $xeGrid = $xeToolbar.$xeGrid
|
|
398
|
+
const $xeGantt = $xeToolbar.$xeGantt
|
|
399
|
+
const $xeGGWrapper = $xeGrid || $xeGantt
|
|
388
400
|
|
|
389
401
|
const { $event } = eventParams
|
|
390
402
|
const { connectTable } = internalData
|
|
@@ -392,11 +404,11 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
392
404
|
const { code } = item
|
|
393
405
|
if (code) {
|
|
394
406
|
$xeToolbar.handleDefaultCodeEvent(eventParams, item, () => {
|
|
395
|
-
if ($
|
|
396
|
-
$
|
|
407
|
+
if ($xeGGWrapper) {
|
|
408
|
+
$xeGGWrapper.triggerToolbarTolEvent(item, $event)
|
|
397
409
|
} else {
|
|
398
410
|
const gCommandOpts = commands.get(code)
|
|
399
|
-
const params = { code, button: null, tool: item, $table: $table as VxeTableConstructor, $grid: $xeGrid, $gantt:
|
|
411
|
+
const params = { code, button: null, tool: item, $table: $table as VxeTableConstructor, $grid: $xeGrid, $gantt: $xeGantt, $event }
|
|
400
412
|
if (gCommandOpts) {
|
|
401
413
|
const tCommandMethod = gCommandOpts.tableCommandMethod || gCommandOpts.commandMethod
|
|
402
414
|
if (tCommandMethod) {
|
|
@@ -467,6 +479,7 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
467
479
|
const slots = $xeToolbar.$scopedSlots
|
|
468
480
|
const internalData = $xeToolbar.internalData
|
|
469
481
|
const $xeGrid = $xeToolbar.$xeGrid
|
|
482
|
+
const $xeGantt = $xeToolbar.$xeGantt
|
|
470
483
|
|
|
471
484
|
const { buttons } = props
|
|
472
485
|
const { connectTable } = internalData
|
|
@@ -475,7 +488,7 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
475
488
|
const buttonSuffixSlot = slots.buttonSuffix || slots['button-suffix']
|
|
476
489
|
const btnVNs: VxeComponentSlotType[] = []
|
|
477
490
|
if (buttonPrefixSlot) {
|
|
478
|
-
btnVNs.push(...getSlotVNs(buttonPrefixSlot.call($xeToolbar, { buttons: buttons || [], $grid: $xeGrid, $table: $table })))
|
|
491
|
+
btnVNs.push(...getSlotVNs(buttonPrefixSlot.call($xeToolbar, { buttons: buttons || [], $grid: $xeGrid, $gantt: $xeGantt, $table: $table })))
|
|
479
492
|
}
|
|
480
493
|
if (buttons) {
|
|
481
494
|
buttons.forEach((item) => {
|
|
@@ -484,7 +497,7 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
484
497
|
const compConf = buttonRender ? renderer.get(buttonRender.name) : null
|
|
485
498
|
if (buttonRender && compConf && compConf.renderToolbarButton) {
|
|
486
499
|
const toolbarButtonClassName = compConf.toolbarButtonClassName
|
|
487
|
-
const params = { $grid: $xeGrid, $table: $table!, button: item }
|
|
500
|
+
const params = { $grid: $xeGrid, $gantt: $xeGantt, $table: $table!, button: item }
|
|
488
501
|
btnVNs.push(
|
|
489
502
|
h('span', {
|
|
490
503
|
class: ['vxe-button--item', toolbarButtonClassName ? (XEUtils.isFunction(toolbarButtonClassName) ? toolbarButtonClassName(params) : toolbarButtonClassName) : '']
|
|
@@ -529,7 +542,7 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
529
542
|
})
|
|
530
543
|
}
|
|
531
544
|
if (buttonSuffixSlot) {
|
|
532
|
-
btnVNs.push(...getSlotVNs(buttonSuffixSlot.call($xeToolbar, { buttons: buttons || [], $grid: $xeGrid, $table: $table })))
|
|
545
|
+
btnVNs.push(...getSlotVNs(buttonSuffixSlot.call($xeToolbar, { buttons: buttons || [], $grid: $xeGrid, $gantt: $xeGantt, $table: $table })))
|
|
533
546
|
}
|
|
534
547
|
return btnVNs
|
|
535
548
|
},
|
|
@@ -545,6 +558,7 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
545
558
|
const slots = $xeToolbar.$scopedSlots
|
|
546
559
|
const internalData = $xeToolbar.internalData
|
|
547
560
|
const $xeGrid = $xeToolbar.$xeGrid
|
|
561
|
+
const $xeGantt = $xeToolbar.$xeGantt
|
|
548
562
|
|
|
549
563
|
const { tools } = props
|
|
550
564
|
const { connectTable } = internalData
|
|
@@ -553,7 +567,7 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
553
567
|
const toolSuffixSlot = slots.toolSuffix || slots['tool-suffix']
|
|
554
568
|
const btnVNs: VxeComponentSlotType[] = []
|
|
555
569
|
if (toolPrefixSlot) {
|
|
556
|
-
btnVNs.push(...getSlotVNs(toolPrefixSlot.call($xeToolbar, { tools: tools || [], $grid: $xeGrid, $table: $table })))
|
|
570
|
+
btnVNs.push(...getSlotVNs(toolPrefixSlot.call($xeToolbar, { tools: tools || [], $grid: $xeGrid, $gantt: $xeGantt, $table: $table })))
|
|
557
571
|
}
|
|
558
572
|
if (tools) {
|
|
559
573
|
tools.forEach((item, tIndex) => {
|
|
@@ -563,7 +577,7 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
563
577
|
const compConf = toolRender ? renderer.get(rdName) : null
|
|
564
578
|
if (toolRender && compConf && compConf.renderToolbarTool) {
|
|
565
579
|
const toolbarToolClassName = compConf.toolbarToolClassName
|
|
566
|
-
const params = { $grid: $xeGrid, $table: $table!, tool: item }
|
|
580
|
+
const params = { $grid: $xeGrid, $gantt: $xeGantt, $table: $table!, tool: item }
|
|
567
581
|
btnVNs.push(
|
|
568
582
|
h('span', {
|
|
569
583
|
key: rdName as string,
|
|
@@ -610,7 +624,7 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
610
624
|
})
|
|
611
625
|
}
|
|
612
626
|
if (toolSuffixSlot) {
|
|
613
|
-
btnVNs.push(...getSlotVNs(toolSuffixSlot.call($xeToolbar, { tools: tools || [], $grid: $xeGrid, $table: $table })))
|
|
627
|
+
btnVNs.push(...getSlotVNs(toolSuffixSlot.call($xeToolbar, { tools: tools || [], $grid: $xeGrid, $gantt: $xeGantt, $table: $table })))
|
|
614
628
|
}
|
|
615
629
|
return btnVNs
|
|
616
630
|
},
|
|
@@ -705,15 +719,17 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
705
719
|
|
|
706
720
|
const $xeToolbar = this
|
|
707
721
|
const $xeGrid = $xeToolbar.$xeGrid
|
|
722
|
+
const $xeGantt = $xeToolbar.$xeGantt
|
|
723
|
+
const $xeGGWrapper = $xeGrid || $xeGantt
|
|
708
724
|
|
|
709
725
|
const zoomOpts = $xeToolbar.computeZoomOpts
|
|
710
|
-
return $
|
|
726
|
+
return $xeGGWrapper && VxeUIButtonComponent
|
|
711
727
|
? h(VxeUIButtonComponent, {
|
|
712
728
|
key: 'zoom',
|
|
713
729
|
props: {
|
|
714
730
|
circle: true,
|
|
715
|
-
icon: $
|
|
716
|
-
title: getI18n(`vxe.toolbar.zoom${$
|
|
731
|
+
icon: $xeGGWrapper.isMaximized() ? (zoomOpts.iconOut || getIcon().TOOLBAR_TOOLS_MINIMIZE) : (zoomOpts.iconIn || getIcon().TOOLBAR_TOOLS_FULLSCREEN),
|
|
732
|
+
title: getI18n(`vxe.toolbar.zoom${$xeGGWrapper.isMaximized() ? 'Out' : 'In'}`)
|
|
717
733
|
},
|
|
718
734
|
on: {
|
|
719
735
|
click: $xeToolbar.zoomEvent
|
|
@@ -763,6 +779,8 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
763
779
|
const slots = $xeToolbar.$scopedSlots
|
|
764
780
|
const internalData = $xeToolbar.internalData
|
|
765
781
|
const $xeGrid = $xeToolbar.$xeGrid
|
|
782
|
+
const $xeGantt = $xeToolbar.$xeGantt
|
|
783
|
+
const $xeGGWrapper = $xeGrid || $xeGantt
|
|
766
784
|
|
|
767
785
|
const { perfect, loading, refresh, zoom, custom, className } = props
|
|
768
786
|
const { connectTable } = internalData
|
|
@@ -780,10 +798,10 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
780
798
|
}, [
|
|
781
799
|
h('div', {
|
|
782
800
|
class: 'vxe-buttons--wrapper'
|
|
783
|
-
}, buttonsSlot ? buttonsSlot({ $grid: $xeGrid, $table: $table }) : $xeToolbar.renderLeftBtns(h)),
|
|
801
|
+
}, buttonsSlot ? buttonsSlot({ $grid: $xeGrid, $gantt: $xeGantt, $table: $table }) : $xeToolbar.renderLeftBtns(h)),
|
|
784
802
|
h('div', {
|
|
785
803
|
class: 'vxe-tools--wrapper'
|
|
786
|
-
}, toolsSlot ? toolsSlot({ $grid: $xeGrid, $table: $table }) : $xeToolbar.renderRightTools(h)),
|
|
804
|
+
}, toolsSlot ? toolsSlot({ $grid: $xeGrid, $gantt: $xeGantt, $table: $table }) : $xeToolbar.renderRightTools(h)),
|
|
787
805
|
h('div', {
|
|
788
806
|
class: 'vxe-tools--operate'
|
|
789
807
|
}, [
|
|
@@ -791,7 +809,7 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
791
809
|
props.export ? $xeToolbar.renderToolExport(h) : renderEmptyElement($xeToolbar),
|
|
792
810
|
props.print ? $xeToolbar.renderToolPrint(h) : renderEmptyElement($xeToolbar),
|
|
793
811
|
refresh ? $xeToolbar.renderToolRefresh(h) : renderEmptyElement($xeToolbar),
|
|
794
|
-
zoom && $
|
|
812
|
+
zoom && $xeGGWrapper ? $xeToolbar.renderToolZoom(h) : renderEmptyElement($xeToolbar),
|
|
795
813
|
custom ? $xeToolbar.renderToolCustom(h) : renderEmptyElement($xeToolbar)
|
|
796
814
|
])
|
|
797
815
|
])
|
|
@@ -801,12 +819,14 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
801
819
|
const $xeToolbar = this
|
|
802
820
|
const props = $xeToolbar
|
|
803
821
|
const $xeGrid = $xeToolbar.$xeGrid
|
|
822
|
+
const $xeGantt = $xeToolbar.$xeGantt
|
|
823
|
+
const $xeGGWrapper = $xeGrid || $xeGantt
|
|
804
824
|
|
|
805
825
|
$xeToolbar.$nextTick(() => {
|
|
806
826
|
const refreshOpts = $xeToolbar.computeRefreshOpts
|
|
807
827
|
const $xeTable = $xeToolbar.fintTable() as any
|
|
808
828
|
const queryMethod = refreshOpts.queryMethod || refreshOpts.query
|
|
809
|
-
if (props.refresh && !$
|
|
829
|
+
if (props.refresh && !$xeGGWrapper && !queryMethod) {
|
|
810
830
|
warnLog('vxe.error.notFunc', ['queryMethod'])
|
|
811
831
|
}
|
|
812
832
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|