|
@@ -9,7 +9,7 @@
|
|
|
<div v-for="(i, index) in listContent" :key="index + 'q'">
|
|
|
<div class="choosePerTxt" :style="{ display: choosePer.includes(i.id) ? '' : 'none' }">
|
|
|
{{ i.name }}
|
|
|
- <img @click.stop="delStu(i.id)" src="@/assets/images/eva/cha.png" alt="" />
|
|
|
+ <img v-if="num !== 1" @click.stop="delStu(i.id)" src="@/assets/images/eva/cha.png" alt="" />
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -65,7 +65,7 @@ export default {
|
|
|
// 判断学生是否被选中
|
|
|
choose(e) {
|
|
|
console.log(e)
|
|
|
- const arr = this.num * 1
|
|
|
+ const arr = this.num
|
|
|
if (arr !== 1) {
|
|
|
if (this.choosePer.includes(e.id)) return
|
|
|
this.choosePer.push(e.id)
|
|
@@ -78,8 +78,8 @@ export default {
|
|
|
// 删除学生
|
|
|
delStu(e) {
|
|
|
// console.log('删除学生', e)
|
|
|
- const iii = this.choosePer.indexOf(e)
|
|
|
- this.choosePer.splice(iii, 1)
|
|
|
+ const i = this.choosePer.indexOf(e)
|
|
|
+ this.choosePer.splice(i, 1)
|
|
|
},
|
|
|
// 此方法在父元素中被调用
|
|
|
fuClick() {
|