vxe-table 3.15.39 → 3.15.41
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 +73 -49
- package/es/{iconfont.1749800510225.ttf → iconfont.1750153781820.ttf} +0 -0
- package/es/iconfont.1750153781820.woff +0 -0
- package/es/iconfont.1750153781820.woff2 +0 -0
- package/es/index.css +1 -1
- package/es/index.min.css +1 -1
- package/es/locale/lang/ar-EG.js +6 -0
- package/es/locale/lang/de-DE.js +6 -0
- package/es/locale/lang/en-US.js +6 -0
- package/es/locale/lang/es-ES.js +6 -0
- package/es/locale/lang/fr-FR.js +6 -0
- package/es/locale/lang/hu-HU.js +6 -0
- package/es/locale/lang/hy-AM.js +6 -0
- package/es/locale/lang/id-ID.js +6 -0
- package/es/locale/lang/it-IT.js +6 -0
- package/es/locale/lang/ja-JP.js +6 -0
- package/es/locale/lang/ko-KR.js +6 -0
- package/es/locale/lang/ms-MY.js +6 -0
- package/es/locale/lang/nb-NO.js +6 -0
- package/es/locale/lang/pt-BR.js +6 -0
- package/es/locale/lang/ru-RU.js +6 -0
- package/es/locale/lang/th-TH.js +6 -0
- package/es/locale/lang/ug-CN.js +6 -0
- package/es/locale/lang/uk-UA.js +6 -0
- package/es/locale/lang/uz-UZ.js +6 -0
- package/es/locale/lang/vi-VN.js +6 -0
- package/es/locale/lang/zh-CHT.js +6 -0
- package/es/locale/lang/zh-CN.js +6 -0
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/table/module/custom/mixin.js +29 -3
- package/es/table/module/custom/panel.js +118 -105
- package/es/table/src/body.js +8 -5
- package/es/table/src/cell.js +12 -12
- package/es/table/src/methods.js +34 -26
- package/es/table/src/props.js +32 -8
- package/es/table/src/table.js +57 -38
- package/es/table/style.css +22 -3
- package/es/table/style.min.css +1 -1
- package/es/toolbar/src/toolbar.js +163 -63
- package/es/ui/index.js +12 -1
- package/es/ui/src/log.js +1 -1
- package/es/vxe-table/style.css +22 -3
- package/es/vxe-table/style.min.css +1 -1
- package/lib/grid/src/grid.js +81 -82
- package/lib/grid/src/grid.min.js +1 -1
- package/lib/{iconfont.1749800510225.ttf → iconfont.1750153781820.ttf} +0 -0
- package/lib/iconfont.1750153781820.woff +0 -0
- package/lib/iconfont.1750153781820.woff2 +0 -0
- package/lib/index.css +1 -1
- package/lib/index.min.css +1 -1
- package/lib/index.umd.js +495 -288
- package/lib/index.umd.min.js +1 -1
- package/lib/locale/lang/ar-EG.js +6 -0
- package/lib/locale/lang/ar-EG.min.js +1 -1
- package/lib/locale/lang/ar-EG.umd.js +6 -0
- package/lib/locale/lang/de-DE.js +6 -0
- package/lib/locale/lang/de-DE.min.js +1 -1
- package/lib/locale/lang/de-DE.umd.js +6 -0
- package/lib/locale/lang/en-US.js +6 -0
- package/lib/locale/lang/en-US.min.js +1 -1
- package/lib/locale/lang/en-US.umd.js +6 -0
- package/lib/locale/lang/es-ES.js +6 -0
- package/lib/locale/lang/es-ES.min.js +1 -1
- package/lib/locale/lang/es-ES.umd.js +6 -0
- package/lib/locale/lang/fr-FR.js +6 -0
- package/lib/locale/lang/fr-FR.min.js +1 -1
- package/lib/locale/lang/fr-FR.umd.js +6 -0
- package/lib/locale/lang/hu-HU.js +6 -0
- package/lib/locale/lang/hu-HU.min.js +1 -1
- package/lib/locale/lang/hu-HU.umd.js +6 -0
- package/lib/locale/lang/hy-AM.js +6 -0
- package/lib/locale/lang/hy-AM.min.js +1 -1
- package/lib/locale/lang/hy-AM.umd.js +6 -0
- package/lib/locale/lang/id-ID.js +6 -0
- package/lib/locale/lang/id-ID.min.js +1 -1
- package/lib/locale/lang/id-ID.umd.js +6 -0
- package/lib/locale/lang/it-IT.js +6 -0
- package/lib/locale/lang/it-IT.min.js +1 -1
- package/lib/locale/lang/it-IT.umd.js +6 -0
- package/lib/locale/lang/ja-JP.js +6 -0
- package/lib/locale/lang/ja-JP.min.js +1 -1
- package/lib/locale/lang/ja-JP.umd.js +6 -0
- package/lib/locale/lang/ko-KR.js +6 -0
- package/lib/locale/lang/ko-KR.min.js +1 -1
- package/lib/locale/lang/ko-KR.umd.js +6 -0
- package/lib/locale/lang/ms-MY.js +6 -0
- package/lib/locale/lang/ms-MY.min.js +1 -1
- package/lib/locale/lang/ms-MY.umd.js +6 -0
- package/lib/locale/lang/nb-NO.js +6 -0
- package/lib/locale/lang/nb-NO.min.js +1 -1
- package/lib/locale/lang/nb-NO.umd.js +6 -0
- package/lib/locale/lang/pt-BR.js +6 -0
- package/lib/locale/lang/pt-BR.min.js +1 -1
- package/lib/locale/lang/pt-BR.umd.js +6 -0
- package/lib/locale/lang/ru-RU.js +6 -0
- package/lib/locale/lang/ru-RU.min.js +1 -1
- package/lib/locale/lang/ru-RU.umd.js +6 -0
- package/lib/locale/lang/th-TH.js +6 -0
- package/lib/locale/lang/th-TH.min.js +1 -1
- package/lib/locale/lang/th-TH.umd.js +6 -0
- package/lib/locale/lang/ug-CN.js +6 -0
- package/lib/locale/lang/ug-CN.min.js +1 -1
- package/lib/locale/lang/ug-CN.umd.js +6 -0
- package/lib/locale/lang/uk-UA.js +6 -0
- package/lib/locale/lang/uk-UA.min.js +1 -1
- package/lib/locale/lang/uk-UA.umd.js +6 -0
- package/lib/locale/lang/uz-UZ.js +6 -0
- package/lib/locale/lang/uz-UZ.min.js +1 -1
- package/lib/locale/lang/uz-UZ.umd.js +6 -0
- package/lib/locale/lang/vi-VN.js +6 -0
- package/lib/locale/lang/vi-VN.min.js +1 -1
- package/lib/locale/lang/vi-VN.umd.js +6 -0
- package/lib/locale/lang/zh-CHT.js +6 -0
- package/lib/locale/lang/zh-CHT.min.js +1 -1
- package/lib/locale/lang/zh-CHT.umd.js +6 -0
- package/lib/locale/lang/zh-CN.js +6 -0
- package/lib/locale/lang/zh-CN.min.js +1 -1
- package/lib/locale/lang/zh-CN.umd.js +6 -0
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/table/module/custom/mixin.js +32 -5
- package/lib/table/module/custom/mixin.min.js +1 -1
- package/lib/table/module/custom/panel.js +14 -2
- package/lib/table/module/custom/panel.min.js +1 -1
- package/lib/table/src/body.js +11 -11
- package/lib/table/src/body.min.js +1 -1
- package/lib/table/src/cell.js +14 -14
- package/lib/table/src/cell.min.js +1 -1
- package/lib/table/src/methods.js +38 -25
- package/lib/table/src/methods.min.js +1 -1
- package/lib/table/src/props.js +32 -8
- package/lib/table/src/table.js +64 -50
- package/lib/table/src/table.min.js +1 -1
- package/lib/table/style/style.css +22 -3
- package/lib/table/style/style.min.css +1 -1
- package/lib/toolbar/src/toolbar.js +189 -88
- package/lib/toolbar/src/toolbar.min.js +1 -1
- package/lib/ui/index.js +12 -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/lib/vxe-table/style/style.css +22 -3
- package/lib/vxe-table/style/style.min.css +1 -1
- package/package.json +1 -1
- package/packages/grid/src/grid.ts +93 -54
- package/packages/locale/lang/ar-EG.ts +6 -0
- package/packages/locale/lang/de-DE.ts +6 -0
- package/packages/locale/lang/en-US.ts +6 -0
- package/packages/locale/lang/es-ES.ts +6 -0
- package/packages/locale/lang/fr-FR.ts +6 -0
- package/packages/locale/lang/hu-HU.ts +6 -0
- package/packages/locale/lang/hy-AM.ts +6 -0
- package/packages/locale/lang/id-ID.ts +6 -0
- package/packages/locale/lang/it-IT.ts +6 -0
- package/packages/locale/lang/ja-JP.ts +6 -0
- package/packages/locale/lang/ko-KR.ts +6 -0
- package/packages/locale/lang/ms-MY.ts +6 -0
- package/packages/locale/lang/nb-NO.ts +6 -0
- package/packages/locale/lang/pt-BR.ts +6 -0
- package/packages/locale/lang/ru-RU.ts +6 -0
- package/packages/locale/lang/th-TH.ts +6 -0
- package/packages/locale/lang/ug-CN.ts +6 -0
- package/packages/locale/lang/uk-UA.ts +6 -0
- package/packages/locale/lang/uz-UZ.ts +6 -0
- package/packages/locale/lang/vi-VN.ts +6 -0
- package/packages/locale/lang/zh-CHT.ts +6 -0
- package/packages/locale/lang/zh-CN.ts +6 -0
- package/packages/table/module/custom/mixin.ts +27 -3
- package/packages/table/module/custom/panel.ts +119 -106
- package/packages/table/src/body.ts +13 -10
- package/packages/table/src/cell.ts +12 -12
- package/packages/table/src/methods.ts +35 -26
- package/packages/table/src/props.ts +32 -8
- package/packages/table/src/table.ts +76 -49
- package/packages/toolbar/src/toolbar.ts +167 -62
- package/packages/ui/index.ts +11 -0
- package/styles/components/icon.scss +13 -1
- package/styles/components/table-module/custom.scss +9 -2
- package/styles/icon/iconfont.ttf +0 -0
- package/styles/icon/iconfont.woff +0 -0
- package/styles/icon/iconfont.woff2 +0 -0
- package/es/iconfont.1749800510225.woff +0 -0
- package/es/iconfont.1749800510225.woff2 +0 -0
- package/lib/iconfont.1749800510225.woff +0 -0
- package/lib/iconfont.1749800510225.woff2 +0 -0
|
@@ -46,13 +46,16 @@ function initPages ($xeGrid: VxeGridConstructor & VxeGridPrivateMethods, propKey
|
|
|
46
46
|
}
|
|
47
47
|
}
|
|
48
48
|
|
|
49
|
-
function renderDefaultForm (h: CreateElement, $xeGrid:
|
|
49
|
+
function renderDefaultForm (h: CreateElement, $xeGrid: VxeGridConstructor & VxeGridPrivateMethods) {
|
|
50
50
|
const VxeUIFormComponent = VxeUI.getComponent<VxeFormComponent>('VxeForm')
|
|
51
51
|
const props = $xeGrid
|
|
52
52
|
const slots = $xeGrid.$scopedSlots
|
|
53
|
+
const reactData = $xeGrid as unknown as GridReactData
|
|
53
54
|
|
|
54
55
|
const { proxyConfig, formConfig } = props
|
|
55
|
-
const {
|
|
56
|
+
const { formData } = reactData
|
|
57
|
+
const proxyOpts = $xeGrid.computeProxyOpts
|
|
58
|
+
const formOpts = $xeGrid.computeFormOpts
|
|
56
59
|
if (isEnableConf(formConfig) && formOpts.items && formOpts.items.length) {
|
|
57
60
|
const formSlots: any = {}
|
|
58
61
|
if (!formOpts.inited) {
|
|
@@ -81,10 +84,10 @@ function renderDefaultForm (h: CreateElement, $xeGrid: any) {
|
|
|
81
84
|
data: proxyConfig && proxyOpts.form ? formData : formOpts.data
|
|
82
85
|
}),
|
|
83
86
|
on: {
|
|
84
|
-
submit: $xeGrid.submitEvent,
|
|
85
|
-
reset: $xeGrid.resetEvent,
|
|
86
|
-
collapse: $xeGrid.collapseEvent,
|
|
87
|
-
'submit-invalid': $xeGrid.submitInvalidEvent
|
|
87
|
+
submit: ($xeGrid as any).submitEvent,
|
|
88
|
+
reset: ($xeGrid as any).resetEvent,
|
|
89
|
+
collapse: ($xeGrid as any).collapseEvent,
|
|
90
|
+
'submit-invalid': ($xeGrid as any).submitInvalidEvent
|
|
88
91
|
},
|
|
89
92
|
scopedSlots: formSlots
|
|
90
93
|
})
|
|
@@ -132,29 +135,52 @@ const getConfigSlot = ($xeGrid: VxeGridConstructor & VxeGridPrivateMethods, slot
|
|
|
132
135
|
return slotConf
|
|
133
136
|
}
|
|
134
137
|
|
|
135
|
-
function getToolbarSlots (
|
|
136
|
-
const
|
|
138
|
+
function getToolbarSlots ($xeGrid: VxeGridConstructor & VxeGridPrivateMethods) {
|
|
139
|
+
const slots = $xeGrid.$scopedSlots
|
|
140
|
+
|
|
141
|
+
const toolbarOpts = $xeGrid.computeToolbarOpts
|
|
137
142
|
const toolbarOptSlots = toolbarOpts.slots
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
143
|
+
const toolbarSlots: {
|
|
144
|
+
buttons?(params: any): any
|
|
145
|
+
buttonPrefix?(params: any): any
|
|
146
|
+
buttonSuffix?(params: any): any
|
|
147
|
+
tools?(params: any): any
|
|
148
|
+
toolPrefix?(params: any): any
|
|
149
|
+
toolSuffix?(params: any): any
|
|
150
|
+
} = {}
|
|
151
|
+
if (slots.buttons && (!toolbarOptSlots || toolbarOptSlots.buttons !== 'buttons')) {
|
|
142
152
|
warnLog('vxe.error.reqProp', ['toolbar-config.slots.buttons'])
|
|
143
153
|
}
|
|
144
|
-
if (
|
|
154
|
+
if (slots.tools && (!toolbarOptSlots || toolbarOptSlots.tools !== 'tools')) {
|
|
145
155
|
warnLog('vxe.error.reqProp', ['toolbar-config.slots.tools'])
|
|
146
156
|
}
|
|
147
157
|
if (toolbarOptSlots) {
|
|
148
|
-
buttonsSlot = getFuncSlot(
|
|
149
|
-
|
|
158
|
+
const buttonsSlot = getFuncSlot($xeGrid, toolbarOptSlots, 'buttons')
|
|
159
|
+
const buttonPrefixSlot = getFuncSlot($xeGrid, toolbarOptSlots, 'buttonPrefix')
|
|
160
|
+
const buttonSuffixSlot = getFuncSlot($xeGrid, toolbarOptSlots, 'buttonSuffix')
|
|
161
|
+
const toolsSlot = getFuncSlot($xeGrid, toolbarOptSlots, 'tools')
|
|
162
|
+
const toolPrefixSlot = getFuncSlot($xeGrid, toolbarOptSlots, 'toolPrefix')
|
|
163
|
+
const toolSuffixSlot = getFuncSlot($xeGrid, toolbarOptSlots, 'toolSuffix')
|
|
150
164
|
if (buttonsSlot) {
|
|
151
|
-
|
|
165
|
+
toolbarSlots.buttons = buttonsSlot
|
|
166
|
+
}
|
|
167
|
+
if (buttonPrefixSlot) {
|
|
168
|
+
toolbarSlots.buttonPrefix = buttonPrefixSlot
|
|
169
|
+
}
|
|
170
|
+
if (buttonSuffixSlot) {
|
|
171
|
+
toolbarSlots.buttonSuffix = buttonSuffixSlot
|
|
152
172
|
}
|
|
153
173
|
if (toolsSlot) {
|
|
154
|
-
|
|
174
|
+
toolbarSlots.tools = toolsSlot
|
|
175
|
+
}
|
|
176
|
+
if (toolPrefixSlot) {
|
|
177
|
+
toolbarSlots.toolPrefix = toolPrefixSlot
|
|
178
|
+
}
|
|
179
|
+
if (toolSuffixSlot) {
|
|
180
|
+
toolbarSlots.toolSuffix = toolSuffixSlot
|
|
155
181
|
}
|
|
156
182
|
}
|
|
157
|
-
return
|
|
183
|
+
return toolbarSlots
|
|
158
184
|
}
|
|
159
185
|
|
|
160
186
|
function getTableOns (_vm: any) {
|
|
@@ -197,9 +223,12 @@ function pageChangeEvent ($xeGrid: VxeGridConstructor & VxeGridPrivateMethods, p
|
|
|
197
223
|
/**
|
|
198
224
|
* 渲染表单
|
|
199
225
|
*/
|
|
200
|
-
function renderForm (h: CreateElement,
|
|
201
|
-
const
|
|
202
|
-
const
|
|
226
|
+
function renderForm (h: CreateElement, $xeGrid: VxeGridConstructor & VxeGridPrivateMethods) {
|
|
227
|
+
const slots = $xeGrid.$scopedSlots
|
|
228
|
+
const props = $xeGrid
|
|
229
|
+
|
|
230
|
+
const { formConfig } = props
|
|
231
|
+
const formSlot = slots.form
|
|
203
232
|
const hasForm = !!(formSlot || isEnableConf(formConfig))
|
|
204
233
|
|
|
205
234
|
if (hasForm) {
|
|
@@ -207,18 +236,22 @@ function renderForm (h: CreateElement, _vm: any) {
|
|
|
207
236
|
key: 'form',
|
|
208
237
|
ref: 'refFormWrapper',
|
|
209
238
|
class: 'vxe-grid--form-wrapper'
|
|
210
|
-
}, formSlot ? formSlot.call(
|
|
239
|
+
}, formSlot ? formSlot.call($xeGrid, { $grid: $xeGrid }) : renderDefaultForm(h, $xeGrid))
|
|
211
240
|
}
|
|
212
|
-
return
|
|
241
|
+
return renderEmptyElement($xeGrid)
|
|
213
242
|
}
|
|
214
243
|
|
|
215
244
|
/**
|
|
216
245
|
* 渲染工具栏
|
|
217
246
|
*/
|
|
218
|
-
function renderToolbar (h: CreateElement,
|
|
219
|
-
const
|
|
220
|
-
const
|
|
247
|
+
function renderToolbar (h: CreateElement, $xeGrid: VxeGridConstructor & VxeGridPrivateMethods) {
|
|
248
|
+
const slots = $xeGrid.$scopedSlots
|
|
249
|
+
const props = $xeGrid
|
|
250
|
+
|
|
251
|
+
const { toolbarConfig } = props
|
|
252
|
+
const toolbarSlot = slots.toolbar
|
|
221
253
|
const hasToolbar = !!(toolbarSlot || isEnableConf(toolbarConfig) || toolbar)
|
|
254
|
+
const toolbarOpts = $xeGrid.computeToolbarOpts
|
|
222
255
|
|
|
223
256
|
if (hasToolbar) {
|
|
224
257
|
return h('div', {
|
|
@@ -226,62 +259,67 @@ function renderToolbar (h: CreateElement, _vm: any) {
|
|
|
226
259
|
ref: 'refToolbarWrapper',
|
|
227
260
|
class: 'vxe-grid--toolbar-wrapper'
|
|
228
261
|
}, toolbarSlot
|
|
229
|
-
? toolbarSlot.call(
|
|
262
|
+
? toolbarSlot.call($xeGrid, { $grid: $xeGrid })
|
|
230
263
|
: [
|
|
231
264
|
h(VxeToolbarComponent, {
|
|
232
|
-
props: Object.assign({},
|
|
265
|
+
props: Object.assign({}, toolbarOpts, { slots: undefined }),
|
|
233
266
|
ref: 'xToolbar',
|
|
234
|
-
scopedSlots: getToolbarSlots(
|
|
267
|
+
scopedSlots: getToolbarSlots($xeGrid)
|
|
235
268
|
})
|
|
236
269
|
]
|
|
237
270
|
)
|
|
238
271
|
}
|
|
239
|
-
return
|
|
272
|
+
return renderEmptyElement($xeGrid)
|
|
240
273
|
}
|
|
241
274
|
|
|
242
275
|
/**
|
|
243
276
|
* 渲染表格顶部区域
|
|
244
277
|
*/
|
|
245
|
-
function renderTop (h: CreateElement,
|
|
246
|
-
const
|
|
247
|
-
|
|
278
|
+
function renderTop (h: CreateElement, $xeGrid: VxeGridConstructor & VxeGridPrivateMethods) {
|
|
279
|
+
const slots = $xeGrid.$scopedSlots
|
|
280
|
+
|
|
281
|
+
const topSlot = slots.top
|
|
248
282
|
|
|
249
283
|
return topSlot
|
|
250
284
|
? h('div', {
|
|
251
285
|
key: 'top',
|
|
252
286
|
ref: 'refTopWrapper',
|
|
253
287
|
class: 'vxe-grid--top-wrapper'
|
|
254
|
-
}, topSlot.call(
|
|
255
|
-
:
|
|
288
|
+
}, topSlot.call($xeGrid, { $grid: $xeGrid }))
|
|
289
|
+
: renderEmptyElement($xeGrid)
|
|
256
290
|
}
|
|
257
291
|
|
|
258
|
-
function renderTableLeft (h: CreateElement,
|
|
259
|
-
const
|
|
260
|
-
|
|
292
|
+
function renderTableLeft (h: CreateElement, $xeGrid: VxeGridConstructor & VxeGridPrivateMethods) {
|
|
293
|
+
const slots = $xeGrid.$scopedSlots
|
|
294
|
+
|
|
295
|
+
const leftSlot = slots.left
|
|
261
296
|
if (leftSlot) {
|
|
262
297
|
return h('div', {
|
|
263
298
|
class: 'vxe-grid--left-wrapper'
|
|
264
|
-
}, leftSlot({ $grid:
|
|
299
|
+
}, leftSlot({ $grid: $xeGrid }))
|
|
265
300
|
}
|
|
266
|
-
return
|
|
301
|
+
return renderEmptyElement($xeGrid)
|
|
267
302
|
}
|
|
268
303
|
|
|
269
|
-
function renderTableRight (h: CreateElement,
|
|
270
|
-
const
|
|
271
|
-
|
|
304
|
+
function renderTableRight (h: CreateElement, $xeGrid: VxeGridConstructor & VxeGridPrivateMethods) {
|
|
305
|
+
const slots = $xeGrid.$scopedSlots
|
|
306
|
+
|
|
307
|
+
const rightSlot = slots.right
|
|
272
308
|
if (rightSlot) {
|
|
273
309
|
return h('div', {
|
|
274
310
|
class: 'vxe-grid--right-wrapper'
|
|
275
|
-
}, rightSlot({ $grid:
|
|
311
|
+
}, rightSlot({ $grid: $xeGrid }))
|
|
276
312
|
}
|
|
277
|
-
return
|
|
313
|
+
return renderEmptyElement($xeGrid)
|
|
278
314
|
}
|
|
279
315
|
|
|
280
316
|
/**
|
|
281
317
|
* 渲染表格
|
|
282
318
|
*/
|
|
283
|
-
function renderTable (h: CreateElement,
|
|
284
|
-
const
|
|
319
|
+
function renderTable (h: CreateElement, $xeGrid: VxeGridConstructor & VxeGridPrivateMethods) {
|
|
320
|
+
const slots = $xeGrid.$scopedSlots
|
|
321
|
+
|
|
322
|
+
const tableProps = $xeGrid.computeTableProps
|
|
285
323
|
|
|
286
324
|
return h('div', {
|
|
287
325
|
class: 'vxe-grid--table-wrapper'
|
|
@@ -289,8 +327,8 @@ function renderTable (h: CreateElement, _vm: any) {
|
|
|
289
327
|
h('vxe-table', {
|
|
290
328
|
key: 'table',
|
|
291
329
|
props: tableProps,
|
|
292
|
-
on: getTableOns(
|
|
293
|
-
scopedSlots:
|
|
330
|
+
on: getTableOns($xeGrid),
|
|
331
|
+
scopedSlots: slots,
|
|
294
332
|
ref: 'xTable'
|
|
295
333
|
})
|
|
296
334
|
])
|
|
@@ -299,17 +337,18 @@ function renderTable (h: CreateElement, _vm: any) {
|
|
|
299
337
|
/**
|
|
300
338
|
* 渲染表格底部区域
|
|
301
339
|
*/
|
|
302
|
-
function renderBottom (h: CreateElement,
|
|
303
|
-
const
|
|
304
|
-
|
|
340
|
+
function renderBottom (h: CreateElement, $xeGrid: VxeGridConstructor & VxeGridPrivateMethods) {
|
|
341
|
+
const slots = $xeGrid.$scopedSlots
|
|
342
|
+
|
|
343
|
+
const bottomSlot = slots.bottom
|
|
305
344
|
|
|
306
345
|
return bottomSlot
|
|
307
346
|
? h('div', {
|
|
308
347
|
key: 'bottom',
|
|
309
348
|
ref: 'refBottomWrapper',
|
|
310
349
|
class: 'vxe-grid--bottom-wrapper'
|
|
311
|
-
}, bottomSlot.call(
|
|
312
|
-
:
|
|
350
|
+
}, bottomSlot.call($xeGrid, { $grid: $xeGrid }))
|
|
351
|
+
: renderEmptyElement($xeGrid)
|
|
313
352
|
}
|
|
314
353
|
|
|
315
354
|
/**
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: 'Erfolgreich ersetzt {0} Zellen'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: '分组',
|
|
564
|
+
values: '值'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'Einfrierensäule',
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: 'Successfully replaced {0} cells'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: 'Group',
|
|
564
|
+
values: 'Values'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'Freeze column',
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: 'Reemplazó con éxito {0} celdas'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: '分组',
|
|
564
|
+
values: '值'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'Columna de congelación',
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: 'Cellules {0} remplacées avec succès'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: '分组',
|
|
564
|
+
values: '值'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'Colonne de gel',
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: 'Sikeresen cserélte a {0} sejteket'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: '分组',
|
|
564
|
+
values: '值'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'Fagyasztási oszlop',
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: 'Berhasil menggantikan {0} sel'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: '分组',
|
|
564
|
+
values: '值'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'Kolom beku',
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: 'Sostituire correttamente le celle {0}'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: '分组',
|
|
564
|
+
values: '值'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'Colonna di congelamento',
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: '{0} sel berjaya diganti'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: '分组',
|
|
564
|
+
values: '值'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'Lajur membekukan',
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: 'Vellykket erstattet {0} celler'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: '分组',
|
|
564
|
+
values: '值'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'Frysekolonne',
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: 'Células substituídas com sucesso {0}'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: '分组',
|
|
564
|
+
values: '值'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'Coluna de congelamento',
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: 'Успешно заменен {0} ячейки'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: '分组',
|
|
564
|
+
values: '值'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'Замораживание колонки',
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: 'جەمئىي {0} دانە ئۇچۇر ئالماشتۇرۇلدى'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: '分组',
|
|
564
|
+
values: '值'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'قۇر توڭلىتىش',
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: 'Успішно замінив {0} комірок'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: '分组',
|
|
564
|
+
values: '值'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'Заморожування стовпчика',
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: '{0} hujayralar muvaffaqiyatli almashtirildi'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: '分组',
|
|
564
|
+
values: '值'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'Muzlatish ustuni',
|
|
@@ -558,6 +558,12 @@ export default {
|
|
|
558
558
|
replaceSuccess: 'Đã thay thế thành công {0} ô'
|
|
559
559
|
}
|
|
560
560
|
},
|
|
561
|
+
extendPivotTable: {
|
|
562
|
+
aggregation: {
|
|
563
|
+
grouping: '分组',
|
|
564
|
+
values: '值'
|
|
565
|
+
}
|
|
566
|
+
},
|
|
561
567
|
filterComplexInput: {
|
|
562
568
|
menus: {
|
|
563
569
|
fixedColumn: 'Đóng băng cột',
|
|
@@ -54,7 +54,8 @@ export default {
|
|
|
54
54
|
const $xeTable = this as VxeTableConstructor & VxeTablePrivateMethods
|
|
55
55
|
const reactData = $xeTable as unknown as TableReactData
|
|
56
56
|
|
|
57
|
-
const {
|
|
57
|
+
const { customColumnList, aggHandleFields, rowGroupList } = reactData
|
|
58
|
+
const customOpts = $xeTable.computeCustomOpts
|
|
58
59
|
const { allowVisible, allowSort, allowFixed, allowResizable } = customOpts
|
|
59
60
|
XEUtils.eachTree(customColumnList, (column, index, items, path, parentColumn) => {
|
|
60
61
|
if (parentColumn) {
|
|
@@ -86,7 +87,18 @@ export default {
|
|
|
86
87
|
setTimeout(() => {
|
|
87
88
|
reactData.isDragColMove = false
|
|
88
89
|
}, 1000)
|
|
89
|
-
return $xeTable.saveCustomStore('confirm')
|
|
90
|
+
return $xeTable.saveCustomStore('confirm').then(() => {
|
|
91
|
+
if (($xeTable as any).handlePivotTableAggregateData) {
|
|
92
|
+
if (rowGroupList.length !== aggHandleFields.length || rowGroupList.some((conf, i) => conf.field !== aggHandleFields[i])) {
|
|
93
|
+
// 改动聚合分组
|
|
94
|
+
if (aggHandleFields.length) {
|
|
95
|
+
$xeTable.setRowGroups(aggHandleFields)
|
|
96
|
+
} else {
|
|
97
|
+
$xeTable.clearRowGroups()
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
})
|
|
90
102
|
},
|
|
91
103
|
_cancelCustom () {
|
|
92
104
|
const $xeTable = this as VxeTableConstructor & VxeTablePrivateMethods
|
|
@@ -122,6 +134,7 @@ export default {
|
|
|
122
134
|
const reactData = $xeTable as unknown as TableReactData
|
|
123
135
|
const internalData = $xeTable as unknown as TableInternalData
|
|
124
136
|
|
|
137
|
+
const { rowGroupList } = reactData
|
|
125
138
|
const { collectColumn } = internalData
|
|
126
139
|
const customOpts = $xeTable.computeCustomOpts
|
|
127
140
|
const { checkMethod } = customOpts
|
|
@@ -148,7 +161,18 @@ export default {
|
|
|
148
161
|
})
|
|
149
162
|
reactData.isCustomStatus = false
|
|
150
163
|
$xeTable.saveCustomStore('reset')
|
|
151
|
-
return $xeTable.handleCustom()
|
|
164
|
+
return $xeTable.handleCustom().then(() => {
|
|
165
|
+
if (($xeTable as any).handlePivotTableAggregateData) {
|
|
166
|
+
const rowGroupFields = $xeTable.computeRowGroupFields
|
|
167
|
+
if (rowGroupFields ? rowGroupFields.length : rowGroupList.length) {
|
|
168
|
+
if (rowGroupFields && rowGroupFields.length) {
|
|
169
|
+
$xeTable.setRowGroups(rowGroupFields)
|
|
170
|
+
} else {
|
|
171
|
+
$xeTable.clearRowGroups()
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
})
|
|
152
176
|
},
|
|
153
177
|
_toggleCustomAllCheckbox () {
|
|
154
178
|
const { customStore } = this
|