el-table 不触发指定列点击事件

vue yekong 464℃

避免el-table cell-click事件触发指定列

<el-table
      :data="tableData"
      stripe
      @cell-click="godetail"
      class="table">
      <el-table-column
        prop="id"
        width="100"
        :column-key="0"
        label="编号">
      </el-table-column>
     <el-table-column
        prop="comment"
        :column-key="1"
        label="备注">
        <template slot-scope="scope">
          <div class="tableinfo">
          <comment :comment="scope.row.comment" :vin="scope.row.vin"></comment>
          </div>
        </template>
      </el-table-column>
    </el-table>
godetail (row, column) {
      if(column.columnKey==0){
        this.$router.push({
          path: '/detail',
          query: { id: row.id }
        })
      }
    },
喜欢 (0)