CASH-1077 | Remove extra zip call
This commit is contained in:
parent
d94f5c03f6
commit
339a2343de
1 changed files with 6 additions and 12 deletions
|
|
@ -257,21 +257,15 @@ export default {
|
||||||
this.modal.closeModal();
|
this.modal.closeModal();
|
||||||
},
|
},
|
||||||
async onSearchZip(event) {
|
async onSearchZip(event) {
|
||||||
this.isLoading = true;
|
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
if (this.localZipCode) {
|
if (!this.localZipCode) {
|
||||||
this.zipCodeData = await this.getZipCodeData(this.localZipCode, "service-location");
|
|
||||||
} else {
|
|
||||||
this.zipCodeData = {
|
this.zipCodeData = {
|
||||||
containsMilitaryBase: false,
|
isValid: false
|
||||||
isServiceable: false,
|
}
|
||||||
isValid: false,
|
return;
|
||||||
state: "",
|
|
||||||
zipCode: this.localZipCode,
|
|
||||||
zipCodeCtu: "",
|
|
||||||
};
|
|
||||||
this.isLoading = false;
|
|
||||||
}
|
}
|
||||||
|
this.isLoading = true;
|
||||||
|
this.zipCodeData = await this.getZipCodeData(this.localZipCode, "service-location");
|
||||||
// Add zipCode to zipCodeData as it does not come back from endpoint
|
// Add zipCode to zipCodeData as it does not come back from endpoint
|
||||||
this.zipCodeData.zipCode = this.localZipCode;
|
this.zipCodeData.zipCode = this.localZipCode;
|
||||||
if (this.zipCodeData.isValid) {
|
if (this.zipCodeData.isValid) {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue