elementUI table固定列渲染错位


1、问题

问题

3、解决

官方

1、可以在获取数据的方法中添加 this.$refs.multipleTable.doLayout()

注意: 是在获取到数据之后

/**获取列表数据**/
      GET_ContractList() {
        API_Purchase[fn](this.params).then(response => {
          this.loading = false
          if (response.code && response.code === 200) {
            const list = response.data.records
            list.forEach(item => {
              if (item.rate) {
                item.rate = Number(item.rate) * 100
              }
            })
            this.tableData = {
              ...response.data,
              records: list
            }
            //
            this.$refs.multipleTable.doLayout()
          } else {
            this.$message.error(response.msg || '系统错误,请联系客服')
          }
        })


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM