Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: 表格组件(vxe-table)固定列与横向滚动配置失效 #5058

Closed
5 tasks done
xiguaniubi2023 opened this issue Dec 6, 2024 · 1 comment · Fixed by #5066
Closed
5 tasks done

Bug: 表格组件(vxe-table)固定列与横向滚动配置失效 #5058

xiguaniubi2023 opened this issue Dec 6, 2024 · 1 comment · Fixed by #5066
Assignees

Comments

@xiguaniubi2023
Copy link

Version

Vben Admin V5

Describe the bug?

基于最新版本V5.5.0版本的(vxe-table)固定列fixed与横向滚动scrollX配置失效 官方DEMO同样存在问题

Reproduction

<script lang="ts" setup> import type { VbenFormProps } from '#/adapter/form'; import type { VxeGridProps } from '#/adapter/vxe-table'; import { Page } from '@vben/common-ui'; import { message } from 'ant-design-vue'; import { useVbenVxeGrid } from '#/adapter/vxe-table'; import { getExampleTableApi } from '#/api'; interface RowType { category: string; color: string; id: string; price: string; productName: string; releaseDate: string; } const formOptions: VbenFormProps = { // 默认展开 collapsed: false, schema: [ { component: 'Input', defaultValue: '1', fieldName: 'category', label: 'Category', }, { component: 'Input', fieldName: 'productName', label: 'ProductName', }, { component: 'Input', fieldName: 'price', label: 'Price', }, { component: 'Select', componentProps: { allowClear: true, options: [ { label: 'Color1', value: '1', }, { label: 'Color2', value: '2', }, ], placeholder: '请选择', }, fieldName: 'color', label: 'Color', }, { component: 'DatePicker', fieldName: 'datePicker', label: 'Date', }, ], // 控制表单是否显示折叠按钮 showCollapseButton: true, // 是否在字段值改变时提交表单 submitOnChange: true, // 按下回车时是否提交表单 submitOnEnter: false, }; const gridOptions: VxeGridProps = { checkboxConfig: { highlight: true, labelField: 'name', }, columns: [ { title: '序号', type: 'seq', width: 50 }, { align: 'left', title: 'Name', type: 'checkbox', width: 400 }, { field: 'category', title: 'Category', width: 400 }, { field: 'color', title: 'Color', width: 400 }, { field: 'productName', title: 'Product Name', width: 400 }, { field: 'price', title: 'Price', width: 400 }, { field: 'releaseDate', fixed: 'right', formatter: 'formatDateTime', title: 'Date', width: 400, }, ], height: 'auto', keepSource: true, pagerConfig: {}, proxyConfig: { ajax: { query: async ({ page }, formValues) => { message.success(`Query params: ${JSON.stringify(formValues)}`); return await getExampleTableApi({ page: page.currentPage, pageSize: page.pageSize, ...formValues, }); }, }, }, scrollX: { gt: 0, }, toolbarConfig: { custom: true, enabled: true, refresh: true, zoom: true, }, }; const [Grid] = useVbenVxeGrid({ formOptions, gridOptions }); </script>

System Info

System:
    OS: macOS 15.1.1
    CPU: (12) arm64 Apple M2 Max
    Memory: 5.29 GB / 32.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 22.11.0 - ~/.nvm/versions/node/v22.11.0/bin/node
    Yarn: 1.22.22 - ~/.nvm/versions/node/v22.11.0/bin/yarn
    npm: 10.9.0 - ~/.nvm/versions/node/v22.11.0/bin/npm
    pnpm: 9.14.4 - ~/.nvm/versions/node/v22.11.0/bin/pnpm
  Browsers:
    Chrome: 131.0.6778.109
    Safari: 18.1.1

Relevant log output

Validations

@mynetfan
Copy link
Collaborator

mynetfan commented Dec 6, 2024

#5027 问题相同,PR中已处理,等待合并

@mynetfan mynetfan self-assigned this Dec 6, 2024
@mynetfan mynetfan mentioned this issue Dec 7, 2024
16 tasks
@github-actions github-actions bot locked and limited conversation to collaborators Dec 22, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants