Element table check box echoes error report

toggleRowSelection always reports an error
Cannot read properties of undefined (reading 'toggleRowSelection')
because toggleRowSelection must be selected in the dom before it can be called
. Solution: add nextTick

this.$nextTick(() => {
    
    
// this.$refs.leftTable.toggleRowSelection(row, true)
})

おすすめ

転載: blog.csdn.net/q249859693/article/details/127928012