关于表格隐藏和非隐藏列的bug
在表格的设置里,把某一列隐藏再取消隐藏后,这一列还是被隐藏着的
src/components/ma-crud/components/setting.vue
//强制刷新下columns的内容 const changeColumn = (ev, type, name) => { const column = columns.value.find(item => item.dataIndex === name) switch (type) { case 'order': if (ev === 'page') { column.sortable = { sortDirections: ['ascend', 'descend'], sorter: false } } else if (ev === 'serve') { column.sortable = { sortDirections: ['ascend', 'descend'], sorter: true } } else { column.sortable = undefined } break } // 强制刷新 columns columns.value = [...columns.value]; }
Hi, @PandaJu. I'm Dosu, and I'm helping the MineAdmin-Vue team manage their backlog. I'm marking this issue as stale.
Issue Summary:
- You reported a bug where a column in the table settings remains hidden despite attempts to unhide it.
- User westng provided a code snippet from
src/components/ma-crud/components/setting.vue. - The snippet includes a
changeColumnfunction that updates sortable properties and refreshes the columns array. - The issue appears to be resolved with the provided code snippet.
Next Steps:
- Please confirm if this issue is still relevant to the latest version of the MineAdmin-Vue repository. If so, you can keep the discussion open by commenting here.
- Otherwise, this issue will be automatically closed in 7 days.
Thank you for your understanding and contribution!