Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
submit () {
if (this.valid()) {
api.saveContact(this.form).then(res => {
AlertModule.show({content: '提交成功'})
console.log(res)
})
} else {
AlertModule.show({content: '请填写完整信息'})
}
},
valid () {
}).catch(err => {
AlertModule.show({
title: '',
content: err.data.msg
})
})