看一下写法,会报错
TIM截图20210518170858.pngprivate toggleSelection(rows: any) {
rows.forEach((row: any) => {
this.$refs.articleTable.toggleRowSelection(row);
})
}
修改为以下
private toggleSelection(rows: any) {
const form = this.$refs.articleTable as ElTable
rows.forEach((row: any) => {
form.toggleRowSelection(row);
})
}
网友评论