16.07 Register - Submit Form if Valid

This commit is contained in:
Fredrick W. Warren 2021-02-12 15:17:25 -08:00
parent 1a10b0c9c7
commit 47f441a3d8

View File

@ -17,6 +17,7 @@
class="col" class="col"
label="Email" label="Email"
stack-label stack-label
ref="email"
/> />
</div> </div>
<div class="row q-mb-md"> <div class="row q-mb-md">
@ -29,6 +30,7 @@
class="col" class="col"
label="Password" label="Password"
stack-label stack-label
ref="password"
/> />
</div> </div>
<div class="row q-mb-md"> <div class="row q-mb-md">
@ -60,7 +62,11 @@ export default {
resetForm () { resetForm () {
}, },
submitForm () { submitForm () {
console.log('Bang Bang! My baby shot me down') this.$refs.email.validate()
this.$refs.password.validate()
if (!this.$refs.email.hasError && !this.$refs.password.hasError) {
console.log('Bang Bang')
}
} }
} }
} }