Element table clicks the icon in a single column to switch

problem description:
I wrote a table in element. The first column is an expansion icon (figure 1)
I switched through v-if, but now clicking on this icon in a row will change the state (figure 2)

I want to know how to change the status of the currently clicked icon without changing other icons?

[before the expansion of figure 1]

clipboard.png

2

clipboard.png

[the following is the related code]

<span v-if="scope.row.expand" class="expandIcon" @click="handleCheck(scope.$index,scope.row);getSkuData(scope.row)">
    <i v-if="plusIcon" class="el-icon-plus"/>
    <i v-if="!plusIcon" class="el-icon-minus"/>
</span>
export default {
  data() {
    return {
        plusIcon: true
    }
  },
  methods: {
    handleCheck(index, row) {
      const $table = this.$refs.table;
      $table.toggleRowExpansion(row);
      $table.toggleRowSelection(row);
      this.plusIcon = !this.plusIcon;
    },
  }
}

Thank you!

Jun.30,2022
The

plusIcon field is placed in the scope.row object, and then scope.row.plusIcon? 'el-icon-plus':' el-icon-minus' shows icon


I have the same problem, but I click and click events and switch icons. How to solve this?

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1eb0d0d-480be.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1eb0d0d-480be.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?