<span :class="activeCode == 1 ? 'tableBottomActive2' : 'tableBottomActive3'" @click="selectAll(1)">
全选
</span>
<span :class="activeCode == 2 ? 'tableBottomActive2' : 'tableBottomActive3'" @click="selectAll(2)">
反选
</span>
export default {
data(){
return {
activeCode:1,
}
},
},
selectAll:function(active){
this.activeCode = active
}
.tableBottomActive2 {
display: inline-block;
text-align: center;
line-height: 34px;
cursor: pointer;
width: 80px;
height: 34px;
background: #EDF2FC;
border: 1px solid #2B60F8;
color: #2B60F8;
margin-left: -4px;
}
.tableBottomActive3 {
display: inline-block;
text-align: center;
line-height: 34px;
cursor: pointer;
width: 80px;
height: 34px;
border: 1px solid #AFC3FA;
margin-left: -4px;
}