Browse Source

fix: the vxeUI global configuration does not take effect (#4574)

pull/4577/head
Vben 1 year ago
committed by GitHub
parent
commit
9ad4f96e38
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 5
      packages/effects/plugins/src/vxe-table/use-vxe-grid.vue

5
packages/effects/plugins/src/vxe-table/use-vxe-grid.vue

@ -63,6 +63,8 @@ const options = computed(() => {
const slotActions = slots['toolbar-actions']?.();
const slotTools = slots['toolbar-tools']?.();
const globalGridConfig = VxeUI?.getConfig()?.grid ?? {};
const forceUseToolbarOptions = showToolbar.value
? {
toolbarConfig: {
@ -79,6 +81,7 @@ const options = computed(() => {
{},
forceUseToolbarOptions,
toRaw(gridOptions.value),
globalGridConfig,
),
);
@ -205,7 +208,7 @@ async function init() {
}
// form vben-formformConfig
const formConfig = options.value.formConfig;
const formConfig = gridOptions.value?.formConfig;
if (formConfig) {
console.warn(
'[Vben Vxe Table]: The formConfig in the grid is not supported, please use the `formOptions` props',

Loading…
Cancel
Save