Fixed bug that was clearing out Vin when re-focusing field after blurring away.
This commit is contained in:
parent
b1328b7cdc
commit
a32b401418
1 changed files with 7 additions and 2 deletions
|
|
@ -187,6 +187,7 @@ export default {
|
||||||
invalidZip: '',
|
invalidZip: '',
|
||||||
vinPopulatedOnPageLoad: this.getVinFromStore()?.length > 0,
|
vinPopulatedOnPageLoad: this.getVinFromStore()?.length > 0,
|
||||||
initialVin: this.getVinFromStore(),
|
initialVin: this.getVinFromStore(),
|
||||||
|
vinTouched: false,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
|
|
@ -250,8 +251,12 @@ export default {
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
setVinTouched() {
|
setVinTouched() {
|
||||||
this.vinMask = "XXXXXXXXXXXXXXXXX";
|
if (!this.vinTouched) {
|
||||||
this.vin = this.initialVin;
|
this.vinMask = "XXXXXXXXXXXXXXXXX";
|
||||||
|
this.vin = this.initialVin;
|
||||||
|
}
|
||||||
|
|
||||||
|
this.vinTouched = true;
|
||||||
},
|
},
|
||||||
setupVinMask() {
|
setupVinMask() {
|
||||||
const lastSixChars = this.initialVin.substring(11, this.initialVin.length);
|
const lastSixChars = this.initialVin.substring(11, this.initialVin.length);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue