this.$refs[formName].validate((valid) => {
if (valid) {
//...
} else {
this.nextTick(()=>{
var isError= document.getElementsByClassName("is-error");
isError[0].querySelector('input').focus();
})
return false;
}
}
element验证不通过焦点自动跳转
猜你喜欢
转载自blog.csdn.net/weixin_39308542/article/details/91381875
今日推荐
周排行