Merge pull request #2534 from Safelite/feature/Digital/CASH-709
CASH-709
This commit is contained in:
commit
da02109e35
2 changed files with 9 additions and 3 deletions
|
|
@ -235,13 +235,12 @@ export default {
|
||||||
this.displayMismatchStateAndZipAlert = false;
|
this.displayMismatchStateAndZipAlert = false;
|
||||||
},
|
},
|
||||||
async setMobileLocation() {
|
async setMobileLocation() {
|
||||||
this.resetAlerts();
|
|
||||||
this.setMobileLocationInvalid(true);
|
|
||||||
// Validate the Zip Code
|
// Validate the Zip Code
|
||||||
if (
|
if (
|
||||||
this.internalModel.addressQuestions.zipCode === "" ||
|
this.internalModel.addressQuestions.zipCode === "" ||
|
||||||
this.internalModel.addressQuestions.zipCode.length !== 5
|
this.internalModel.addressQuestions.zipCode.length !== 5
|
||||||
) {
|
) {
|
||||||
|
this.setMobileLocationInvalid(true);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const zipCodeData = await this.getZipCodeData(
|
const zipCodeData = await this.getZipCodeData(
|
||||||
|
|
@ -250,15 +249,22 @@ export default {
|
||||||
);
|
);
|
||||||
|
|
||||||
if (!zipCodeData.isValid) {
|
if (!zipCodeData.isValid) {
|
||||||
|
this.displayMismatchStateAndZipAlert = false;
|
||||||
this.displayInvalidZipAlert = true;
|
this.displayInvalidZipAlert = true;
|
||||||
|
this.setMobileLocationInvalid(true);
|
||||||
return;
|
return;
|
||||||
} else if (zipCodeData.state != this.internalModel.addressQuestions.state) {
|
} else if (zipCodeData.state != this.internalModel.addressQuestions.state) {
|
||||||
|
this.displayInvalidZipAlert = false;
|
||||||
this.displayMismatchStateAndZipAlert = true;
|
this.displayMismatchStateAndZipAlert = true;
|
||||||
|
this.setMobileLocationInvalid(true);
|
||||||
return;
|
return;
|
||||||
} else if (
|
} else if (
|
||||||
this.internalModel.addressQuestions.zipCode !==
|
this.internalModel.addressQuestions.zipCode !==
|
||||||
this.modelValue.addressQuestions.zipCode
|
this.modelValue.addressQuestions.zipCode
|
||||||
) {
|
) {
|
||||||
|
//reset alerts
|
||||||
|
this.resetAlerts();
|
||||||
|
|
||||||
// retrieve mobile fee part
|
// retrieve mobile fee part
|
||||||
const serviceZipCode = this.internalModel.addressQuestions.zipCode;
|
const serviceZipCode = this.internalModel.addressQuestions.zipCode;
|
||||||
const mobileFeePart = await getPricedMobileFeePart(
|
const mobileFeePart = await getPricedMobileFeePart(
|
||||||
|
|
|
||||||
|
|
@ -57,7 +57,7 @@ export default {
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
.modal-dialog {
|
.mobile-location-questions {
|
||||||
.question-text {
|
.question-text {
|
||||||
& > span {
|
& > span {
|
||||||
text-align: left;
|
text-align: left;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue