Element-UI Table 表格尾部的合计行,当固定表头时,不显示

2024-10-30 13:07:02

一. 问题

根据 Element UI 文档要求,实现合计行,固定表头,需要如下配置:

<el-table
  ref="tableRef"
  show-summary
  :height="height"
  ...
>

实现合计行后,当固定表头(设置height)时,发现合计行不显示。

二. 解决方案

通过查看文档,发现:

export default {
updated() {
    this.$nextTick(() => {
      this.$refs.tableRef.doLayout()
    })
  }
}

目录

相关推荐
关于调用微软Bing API推送链接时,报:errorcode 3 message ERROR!!! InvalidApiKey如何调用百度和微软必应链接收录APIMac安装nvm时,各种问题总结react-app-rewired中如何设置ant-design主题,以及不生效问题Variable @primary-color-hover is undefinedAnt-Design-Vue Form 中,对于多选下拉表表单时,重置时,表单未正确展示