解决办法使用:
@click.stop阻止事件冒泡
表头绑定了每一列的默认事件
<el-table
stripe
:data="data"
@row-click="
row => {
reportUZX(row.name, row.degree, row.studentName, row.userId)
}
"
>
对操作栏按钮绑定监听@click.stop,阻止事件冒泡,发挥按钮功能
<el-table-column label="操作">
<template slot-scope="scope">
<el-button
class="operate"
:disabled="scope.row.reExamStatus === 1"
@click.stop="setReExam(scope.row.id)"
>
允许重考
</el-button>
</template>
</el-table-column>