<el-input type="password" v-model="form.oldPass "></el-input>
</el-form-item>
<el-form-item label="新密码" prop="password ">
<el-input type="password" v-model="form.password"></el-input>
</el-form-item>
<el-form-item label="确认密码" prop="checkPass ">
<el-input type="password" show-password v-model="form.checkPass"></el-input>
</el-form-item>
-------
<script>
//...
oldPass:[
{ required: true, message: '密码不能为空', trigger: 'blur' }
],
password: [
{ validator: vPass, required: true,trigger: 'blur' }
],
checkPass: [
{validator: vPass2, required: true, trigger: 'blur' }
]
</script>
e
这样label前是没有*号的,也无法校验-----就tm因为prop属性值内不能加空格,否则无效
如prop="username"正确,prop="username "错误
网友评论