AppointmentTypeString removal
We don't need this currently because there is no distinction between inshop and dropoff currently
This commit is contained in:
parent
fac44ed8df
commit
371849e924
2 changed files with 21 additions and 33 deletions
|
|
@ -106,7 +106,6 @@
|
|||
</div>
|
||||
<shopQuestionPopup
|
||||
v-if="isShopQuestionDisplayed"
|
||||
:appointmentType="appointmentType"
|
||||
:modelValue="{
|
||||
zipCode: zipCode,
|
||||
state: state,
|
||||
|
|
|
|||
|
|
@ -119,12 +119,11 @@ export default {
|
|||
selectedProviderNumber: null, // Revisit this, maybe not too hard
|
||||
lastSearchedZip: "", // zip refactor
|
||||
lastSuccessfulZip: "", // zip refactor
|
||||
displayInvalidZipAlert: false,
|
||||
displayNoShopsAlert: false,
|
||||
displayInvalidZipAlert: false, // part of big refactor of asyn calls
|
||||
displayNoShopsAlert: false, // part of big refactor of asyn calls
|
||||
};
|
||||
},
|
||||
props: {
|
||||
appointmentType: String,
|
||||
shopProviderData: Object,
|
||||
modelValue: {
|
||||
type: Object,
|
||||
|
|
@ -176,7 +175,9 @@ export default {
|
|||
availabilityRatingCallback: getAvailabilityRating,
|
||||
startDate: formattedStartDate,
|
||||
endDate: formattedEndDate,
|
||||
shopAppointmentType: this.appointmentType,
|
||||
// Used for availability indicators, could be refactored out of any availability indicator
|
||||
// logic if/when we are sure we'll never have separate drop off/ in shop logic
|
||||
shopAppointmentType: AppointmentTypeStrings.IN_SHOP_OR_DROP_OFF,
|
||||
};
|
||||
},
|
||||
displaySeeMoreLocationsLink() {
|
||||
|
|
@ -243,27 +244,23 @@ export default {
|
|||
if (logFirstShopsDisplayed) {
|
||||
gaAction = this.GaActions.SHOPS_FIRST_DISPLAYED;
|
||||
}
|
||||
if (
|
||||
this.appointmentType === AppointmentTypeStrings.IN_SHOP ||
|
||||
this.appointmentType === AppointmentTypeStrings.DROP_OFF ||
|
||||
this.appointmentType === AppointmentTypeStrings.IN_SHOP_OR_DROP_OFF
|
||||
) {
|
||||
var shops = mappedData.map((shop) => {
|
||||
if (shop.value.length > 5 && shop.value.startsWith("00")) {
|
||||
return shop.value.substring(1);
|
||||
} else {
|
||||
return shop.value;
|
||||
}
|
||||
});
|
||||
|
||||
var joinedShops = shops.join(",");
|
||||
if (!joinedShops) {
|
||||
joinedShops = "no-shops";
|
||||
var shops = mappedData.map((shop) => {
|
||||
if (shop.value.length > 5 && shop.value.startsWith("00")) {
|
||||
return shop.value.substring(1);
|
||||
} else {
|
||||
return shop.value;
|
||||
}
|
||||
});
|
||||
|
||||
this.pushEventToGA(this.GaCategories.SERVICE_LOCATION, gaAction, joinedShops, true);
|
||||
var joinedShops = shops.join(",");
|
||||
if (!joinedShops) {
|
||||
joinedShops = "no-shops";
|
||||
}
|
||||
|
||||
this.pushEventToGA(this.GaCategories.SERVICE_LOCATION, gaAction, joinedShops, true);
|
||||
|
||||
|
||||
if (this.answers.length === 0) {
|
||||
this.answers = mappedData;
|
||||
} else {
|
||||
|
|
@ -353,22 +350,12 @@ export default {
|
|||
}
|
||||
this.localShopProviderData = result.data;
|
||||
this.updateShopsForZip(this.internalModel.zipCode);
|
||||
if (this.appointmentType === AppointmentTypeStrings.MOBILE) {
|
||||
this.selectedProvider = new Provider(
|
||||
this.shopProviderData.mobileProviderNumber
|
||||
);
|
||||
} else {
|
||||
this.selectedProvider = new Provider();
|
||||
}
|
||||
this.selectedProvider = new Provider();
|
||||
});
|
||||
}
|
||||
}
|
||||
},
|
||||
updateShopsForZip(zipCode) {
|
||||
if (!this.appointmentType) {
|
||||
this.answers = [];
|
||||
return;
|
||||
}
|
||||
this.lastSearchedZip = zipCode;
|
||||
if (!zipCode) {
|
||||
this.answers = [];
|
||||
|
|
@ -420,7 +407,9 @@ export default {
|
|||
availabilityRatingCallback: getAvailabilityRating,
|
||||
startDate: formattedStartDate,
|
||||
endDate: formattedEndDate,
|
||||
shopAppointmentType: this.appointmentType,
|
||||
// Used for availability indicators, could be refactored out of any availability indicator
|
||||
// logic if/when we are sure we'll never have separate drop off/ in shop logic
|
||||
shopAppointmentType: AppointmentTypeStrings.IN_SHOP_OR_DROP_OFF,
|
||||
},
|
||||
value: shopProvider.providerNumber,
|
||||
};
|
||||
|
|
|
|||
Loading…
Reference in a new issue