<el-form ref="ruleForm"></el-form>
editForm(formName) {
const { supplierName, userName, userPhone } = this.ruleForm
if (supplierName && userName && userPhone) {
//执行校验成功的相关操作
} else {
this.$refs[formName].validateField(['supplierName', 'userName', 'userPhone'])
}
},
网友评论