<el-input style="width: 60px" v-model="scope.row.gain" onkeyup="value=value.replace(/[^\d]/g,'')" @change="((val)=>{ inputChange(val, scope.$index) })"/>%
只需要假如下面的属性就可以了
οnkeyup="value=value.replace(/[^\d]/g,'')"
<el-input style="width: 60px" v-model="scope.row.gain" onkeyup="value=value.replace(/[^\d]/g,'')" @change="((val)=>{ inputChange(val, scope.$index) })"/>%
只需要假如下面的属性就可以了
οnkeyup="value=value.replace(/[^\d]/g,'')"