Add validation for textInput on blur

This commit is contained in:
leigh-mil 2019-02-12 11:01:27 -05:00
parent 6dec26c93c
commit 87905c07f4
2 changed files with 5 additions and 0 deletions

View File

@ -84,6 +84,10 @@ export default {
}
},
onBlur: function(e) {
this._checkIfValid({ value: e.target.value, invalidate: true })
},
//
_checkIfValid: function({ value, invalidate = false }) {
// Validate the value

View File

@ -64,6 +64,7 @@
<masked-input
v-on:input='onInput'
v-on:blur='onBlur'
v-on:change='onChange'
v-bind:value='value'
v-bind:mask='mask'