<div @dblclick="inputUP(scope.row._id)" v-show="ISinput!==scope.row._id">{{scope.row.paixu}}</div>
<el-input
v-model="scope.row.paixu"
placeholder="请输入内容"
v-show="ISinput===scope.row._id"
v-focus
@blur="blurIpunt"></el-input>
directives: {
focus:function (el) {
el.children[0].focus();
}
},
data() {
return {
ISinput:'',
}
}
methods: {
// 失去焦点
blurIpunt () {
this.ISinput = ''
},
//双击
inputUP (ISinput) {
this.ISinput = ISinput
},
}
网友评论