From 5084c7cde97ede4c3258e43377e00371b03388f3 Mon Sep 17 00:00:00 2001 From: Josh Dassinger Date: Wed, 4 Oct 2023 11:53:12 -0500 Subject: [PATCH 01/14] SSR-706 Fix Missing Fields in Save Session Adds Claim Number Adds Policy State --- src/store/index.js | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/store/index.js b/src/store/index.js index 20b48012..7f5ed853 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -107,7 +107,8 @@ const getDefaultState = () => ({ isInsurance: true, // TODO delete; irrelevant to ISS insuranceCoverage: { isVerified: false, - coverageStatus: coverageStatuses.PENDING + coverageStatus: coverageStatuses.PENDING, + claimNumber: null }, parentAccountNumber: 0 }, @@ -455,12 +456,14 @@ export const useMainStore = defineStore({ }).then((response) => { const registerClaimFailed = response.data.isError; order.payment.insuranceCoverage.isVerified = !registerClaimFailed; + order.payment.insuranceCoverage.claimNumber = null; if (registerClaimFailed) { this.order.payment.insuranceCoverage.coverageStatus = coverageStatuses.PENDING; } else if (this.policy.noCoverage) { this.order.payment.insuranceCoverage.coverageStatus = coverageStatuses.NO_COMP; } else { this.order.payment.insuranceCoverage.coverageStatus = coverageStatuses.VERIFIED; + this.order.payment.insuranceCoverage.claimNumber = response.data.claimNumber; } return resolve(response); }, (error) => { @@ -862,7 +865,8 @@ export const useMainStore = defineStore({ policyFirstName: customer.firstName, policyLastName: customer.lastName, policyPhoneNumber: customer.phoneNumber, - policyEmail: customer.emailAddress + policyEmail: customer.emailAddress, + policyState: customer.address.state }, policyNumber: policy.policyNumber, policyZipCode: policy.policyZipCode, @@ -893,7 +897,8 @@ export const useMainStore = defineStore({ payment: { InsuranceCoverage: { isVerified: payment.insuranceCoverage?.isVerified ?? false, - coverageStatus: payment.insuranceCoverage?.coverageStatus + coverageStatus: payment.insuranceCoverage?.coverageStatus, + claimNumber: payment.insuranceCoverage?.claimNumber }, isInsurance: payment.isInsurance ?? true, parentAccountNumber: this.issConfig.parentAccountNumber From 3b4f120943461b8a16f543f98f59edaeb6942d32 Mon Sep 17 00:00:00 2001 From: Josh Dassinger Date: Wed, 4 Oct 2023 12:30:21 -0500 Subject: [PATCH 02/14] SSR-706 Fix Store Unit Tests --- src/store/store.spec.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/store/store.spec.js b/src/store/store.spec.js index bd8a5f2a..9ada327b 100644 --- a/src/store/store.spec.js +++ b/src/store/store.spec.js @@ -615,7 +615,10 @@ describe('Store', () => { firstName: getRandomString(6, 6), lastName: getRandomString(6, 6), emailAddress: getRandomString(6, 6), - phoneNumber: getRandomString(6, 6) + phoneNumber: getRandomString(6, 6), + address: { + state: getRandomString(2, 2) + } }; const policy = { policyNumber: getRandomString(6, 6), From 0bef00dfa78e0ad3c7b99c8cd4b70269fd2d878c Mon Sep 17 00:00:00 2001 From: Josh Dassinger Date: Thu, 5 Oct 2023 08:21:24 -0500 Subject: [PATCH 03/14] SSR-706 Add Unit Tests for field changes --- src/store/index.js | 1 + src/store/store.spec.js | 8 ++++++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/store/index.js b/src/store/index.js index 7f5ed853..fe335f26 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -469,6 +469,7 @@ export const useMainStore = defineStore({ }, (error) => { this.order.payment.insuranceCoverage.isVerified = false; this.order.payment.insuranceCoverage.coverageStatus = coverageStatuses.PENDING; + this.order.payment.insuranceCoverage.claimNumber = null; return reject(error); }); }); diff --git a/src/store/store.spec.js b/src/store/store.spec.js index 9ada327b..895c7e0d 100644 --- a/src/store/store.spec.js +++ b/src/store/store.spec.js @@ -396,6 +396,7 @@ describe('Store', () => { expect(globalMethods.callHttpClient).toHaveBeenCalled(); expect(store.payment.insuranceCoverage.isVerified).toBe(true); expect(store.payment.insuranceCoverage.coverageStatus).toBe(coverageStatuses.NO_COMP); + expect(store.payment.insuranceCoverage.claimNumber).toBe(null); }); it('successful response with coverage => isVerified true and coverage status verified', async () => { @@ -422,11 +423,12 @@ describe('Store', () => { expect(globalMethods.callHttpClient).toHaveBeenCalled(); expect(store.payment.insuranceCoverage.isVerified).toBe(true); expect(store.payment.insuranceCoverage.coverageStatus).toBe(coverageStatuses.VERIFIED); + expect(store.payment.insuranceCoverage.claimNumber).toBe(response.data.claimNumber); }); it('Call to client returns exception, resulting in object with error property being returned', async () => { // Arrange - expect.assertions(4); + expect.assertions(5); const error = 'this is the error'; globalMethods.callHttpClient = jest.fn().mockReturnValue(Promise.reject(error)); @@ -439,6 +441,7 @@ describe('Store', () => { expect(globalMethods.callHttpClient).toHaveBeenCalled(); expect(store.payment.insuranceCoverage.isVerified).toBe(false); expect(store.payment.insuranceCoverage.coverageStatus).toBe(coverageStatuses.PENDING); + expect(store.payment.insuranceCoverage.claimNumber).toBe(null); }); }); @@ -645,7 +648,8 @@ describe('Store', () => { policyFirstName: customer.firstName, policyLastName: customer.lastName, policyPhoneNumber: customer.phoneNumber, - policyEmail: customer.emailAddress + policyEmail: customer.emailAddress, + policyState: customer.address.state }), policyNumber: policy.policyNumber, policyZipCode: policy.policyZipCode, From fcfd46d40fce1c18bd0795a98cc517af4191f561 Mon Sep 17 00:00:00 2001 From: Bill Richardson Date: Thu, 5 Oct 2023 11:22:10 -0400 Subject: [PATCH 04/14] add a couple missing getters --- src/store/index.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/store/index.js b/src/store/index.js index 1e8e95de..91ba5f56 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -11,7 +11,7 @@ import applicationConfig from '@/constants/application-config'; import issPageValues from '@/router/router-constants/issPage-values'; import damageLocationsSelected from '@/constants/damage-locations-selected'; import coverageStatuses from '@/constants/coverage-statuses'; -import { PREMIUM_FEE_PART_TYPE } from '@/constants/schedule-constants'; +import { AppointmentTypeStrings, PREMIUM_FEE_PART_TYPE } from '@/constants/schedule-constants'; import getDateDifferenceInDays from '@/helpers/date-helper'; const storeId = 'main'; @@ -192,6 +192,8 @@ export const useMainStore = defineStore({ payment: (state) => state.order.payment, policy: (state) => state.order.policy, hasAnyNonWindshieldGlassParts: (state) => !state.order.policy.isDamageGlassOnly, + isMobileAppointment: (state) => state.order.serviceLocation.appointmentType === AppointmentTypeStrings.MOBILE, + isDropOffAppointment: (state) => state.order.serviceLocation.appointmentType === AppointmentTypeStrings.DROP_OFF, isClaimRegistrationRequired: (state) => state.issConfig.isClaimRegistrationRequired, eventBusItem: (state) => (eventCategory, eventSubCategory) => { const matchedEvent = state.applicationUser.eventBus.find(({ category, subCategory }) => category === eventCategory && subCategory === eventSubCategory); From 19bc2e7d2d02bc4946893325764d3c02c8e748f9 Mon Sep 17 00:00:00 2001 From: Bill Richardson Date: Thu, 5 Oct 2023 11:31:18 -0400 Subject: [PATCH 05/14] tests for isMobileAppointment --- src/store/store.spec.js | 39 ++++++++++++++++++++++++++++++++++++++- 1 file changed, 38 insertions(+), 1 deletion(-) diff --git a/src/store/store.spec.js b/src/store/store.spec.js index bd8a5f2a..f736806b 100644 --- a/src/store/store.spec.js +++ b/src/store/store.spec.js @@ -4,6 +4,7 @@ import globalMethods from '@/global-methods.js'; import { getRandomString, getRandomGuid, getRandomInt, getRandomBoolean } from '@/helpers/data-generation.js'; import coverageStatuses from '@/constants/coverage-statuses.js'; import { endpoints } from '@/constants/endpoints'; +import { AppointmentTypeStrings } from '@/constants/schedule-constants'; describe('Store', () => { let store; @@ -994,7 +995,7 @@ describe('Store', () => { describe('updatePolicyITACFlag method', () => { it('updatePolicyITACFlag updates policy.isITAC flag in store', () => { - // Assert + // Arrange const moqIsITAC = getRandomBoolean(); // Act @@ -1004,4 +1005,40 @@ describe('Store', () => { expect(store.order.policy.isITAC).toEqual(moqIsITAC); }); }); + + describe('isMobileAppointment', () => { + it('Should return true for mobile appointments', () => { + // Arrange + + // Act + store.updateServiceLocation({ + appointmentType: AppointmentTypeStrings.MOBILE + }); + + // Assert + expect(store.isMobileAppointment).toBe(true); + }); + + it('Should return false for non-mobile appointments', () => { + // Arrange + + // Act + store.updateServiceLocation({ + appointmentType: AppointmentTypeStrings.IN_SHOP + }); + + // Assert + expect(store.isMobileAppointment).toBe(false); + }); + + it('Should return false for null appointments', () => { + // Arrange + + // Act + store.updateServiceLocation({ appointmentType: null }); + + // Assert + expect(store.isMobileAppointment).toBe(false); + }); + }); }); From e7e5251c56293078bbb3ce3054fbc3d25b3a00b3 Mon Sep 17 00:00:00 2001 From: "US\\katie.kroell" Date: Thu, 5 Oct 2023 11:34:42 -0400 Subject: [PATCH 06/14] when menu modal is open, overlap all other components on the page --- src/iss-components/site-header/menu-modal/menu-modal.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/iss-components/site-header/menu-modal/menu-modal.vue b/src/iss-components/site-header/menu-modal/menu-modal.vue index 3c248abf..ddeee120 100644 --- a/src/iss-components/site-header/menu-modal/menu-modal.vue +++ b/src/iss-components/site-header/menu-modal/menu-modal.vue @@ -162,7 +162,7 @@ export default { border-top: 1px solid $gray-300; overflow-x: visible; overflow-y: visible; - z-index: 2; + z-index: 3; .modal-body { padding: 2rem; .ccpa-icon { From 121cda7182682d0df1f7ee5846b371b1b35933bf Mon Sep 17 00:00:00 2001 From: Bill Richardson Date: Thu, 5 Oct 2023 11:42:05 -0400 Subject: [PATCH 07/14] Include Mobile_Insurance --- src/store/index.js | 3 ++- src/store/store.spec.js | 48 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 50 insertions(+), 1 deletion(-) diff --git a/src/store/index.js b/src/store/index.js index 91ba5f56..79a600e0 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -192,7 +192,8 @@ export const useMainStore = defineStore({ payment: (state) => state.order.payment, policy: (state) => state.order.policy, hasAnyNonWindshieldGlassParts: (state) => !state.order.policy.isDamageGlassOnly, - isMobileAppointment: (state) => state.order.serviceLocation.appointmentType === AppointmentTypeStrings.MOBILE, + isMobileAppointment: (state) => state.order.serviceLocation.appointmentType === AppointmentTypeStrings.MOBILE + || state.order.serviceLocation.appointmentType === AppointmentTypeStrings.MOBILE_INSURANCE, isDropOffAppointment: (state) => state.order.serviceLocation.appointmentType === AppointmentTypeStrings.DROP_OFF, isClaimRegistrationRequired: (state) => state.issConfig.isClaimRegistrationRequired, eventBusItem: (state) => (eventCategory, eventSubCategory) => { diff --git a/src/store/store.spec.js b/src/store/store.spec.js index f736806b..aea99622 100644 --- a/src/store/store.spec.js +++ b/src/store/store.spec.js @@ -1019,6 +1019,18 @@ describe('Store', () => { expect(store.isMobileAppointment).toBe(true); }); + it('Should return true for mobile-insurance appointments', () => { + // Arrange + + // Act + store.updateServiceLocation({ + appointmentType: AppointmentTypeStrings.MOBILE_INSURANCE + }); + + // Assert + expect(store.isMobileAppointment).toBe(true); + }); + it('Should return false for non-mobile appointments', () => { // Arrange @@ -1041,4 +1053,40 @@ describe('Store', () => { expect(store.isMobileAppointment).toBe(false); }); }); + + describe('isDropoffAppointment', () => { + it('Should return true for drop-off appointments', () => { + // Arrange + + // Act + store.updateServiceLocation({ + appointmentType: AppointmentTypeStrings.DROP_OFF + }); + + // Assert + expect(store.isDropOffAppointment).toBe(true); + }); + + it('Should return false for non-drop-off appointments', () => { + // Arrange + + // Act + store.updateServiceLocation({ + appointmentType: AppointmentTypeStrings.MOBILE + }); + + // Assert + expect(store.isDropOffAppointment).toBe(false); + }); + + it('Should return false for null appointments', () => { + // Arrange + + // Act + store.updateServiceLocation({ appointmentType: null }); + + // Assert + expect(store.isDropOffAppointment).toBe(false); + }); + }); }); From a20e8e2aaf332f637da3b1e443f3b361097a8850 Mon Sep 17 00:00:00 2001 From: Bill Richardson Date: Thu, 5 Oct 2023 10:53:34 -0400 Subject: [PATCH 08/14] add timeSlotModalQuestion to schedule --- src/layouts/schedule-page/schedule-page.vue | 45 +++++++++++++++------ src/store/index.js | 27 +++++++++++-- src/store/store.spec.js | 6 ++- 3 files changed, 60 insertions(+), 18 deletions(-) diff --git a/src/layouts/schedule-page/schedule-page.vue b/src/layouts/schedule-page/schedule-page.vue index 624acf75..e898b7dc 100644 --- a/src/layouts/schedule-page/schedule-page.vue +++ b/src/layouts/schedule-page/schedule-page.vue @@ -29,7 +29,25 @@ class="text-link-small" :customSelectableDatesCallback="getAvailableDatesMethod" validationRules="date-required" - @date-clicked="openInshopTimeSlotsModal" /> + @dateClicked="openInshopTimeSlotsModal" /> + item.partType === PREMIUM_FEE_PART_TYPE); if (removeEarlyBirdIndex >= 0) { supportingItems.splice(removeEarlyBirdIndex, 1); - this.dispatchStoreAction( - this.storeActions.SAVE_SUPPORTING_ITEMS_SUPPRESSING_STATE_RESETTING, - supportingItems, - false - ); + this.mainStore.saveSupportingItemsSuppressingStateResetting(supportingItems); } } }, @@ -429,7 +446,9 @@ export default { this.$router.navigate(this.navigationScenarios.CLICKED_BACK, this.$route); }, forwardButtonAction() { - // validate and save here + this.updateSupportingItems(); + this.mainStore.saveSchedule(this.selectedTimeSlotInfo.timeSlot); + this.$router.navigate(this.navigationScenarios.CLICKED_FORWARD, this.$route); } } diff --git a/src/store/index.js b/src/store/index.js index 79a600e0..ee056617 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -138,7 +138,8 @@ const getDefaultState = () => ({ startTime: null, endTime: null, routeCode: null, - jobMaxMinutes: null + jobMaxMinutes: null, + jobMinMinutes: null }, referralNumber: null, referralDate: null, @@ -999,7 +1000,8 @@ export const useMainStore = defineStore({ startTime: schedule.startTime, endTime: schedule.endTime, routeCode: schedule.routeCode, - jobMaxMinutes: schedule.jobMaxMinutes + jobMaxMinutes: schedule.jobMaxMinutes, + jobMinMinutes: schedule.jobMinMinutes }, referralDate: this.order.referralDate, referralNumber: this.order.referralNumber?.toString(), @@ -1193,7 +1195,7 @@ export const useMainStore = defineStore({ this.order.schedule.endTime = null; this.order.schedule.routeCode = null; this.order.schedule.jobMaxMinutes = null; - // this.order.schedule.jobMinMinutes = null; + this.order.schedule.jobMinMinutes = null; // premium appointment fee used on schedule page also needs reset when schedule is reset const { supportingItems } = this.order.lineItems; @@ -1398,6 +1400,10 @@ export const useMainStore = defineStore({ this.order.lineItems.glassParts = glassParts; }, saveSupportingItems(supportingItems) { + // TODO: RESET_SERVICE_LOCATION_STATE_AND_DEPENDENCIES + this.order.lineItems.supportingItems = supportingItems; + }, + saveSupportingItemsSuppressingStateResetting(supportingItems) { this.order.lineItems.supportingItems = supportingItems; }, saveVaps(vaps) { @@ -1477,6 +1483,21 @@ export const useMainStore = defineStore({ }); }, + // Schedule Actions + saveSchedule(scheduleInfo) { + this.updateSchedule(scheduleInfo); + }, + updateSchedule(scheduleInfo) { + if (scheduleInfo) { + this.order.schedule.date = scheduleInfo.date; + this.order.schedule.startTime = scheduleInfo.startTime; + this.order.schedule.endTime = scheduleInfo.endTime; + this.order.schedule.routeCode = scheduleInfo.routeCode; + this.order.schedule.jobMaxMinutes = scheduleInfo.jobMaxMinutes; + this.order.schedule.jobMinMinutes = scheduleInfo.jobMinMinutes; + } + }, + // Analytics Actions logExperimentExposure({ userId, sessionKey, pageName, experiment }) { return globalMethods.callHttpClient({ diff --git a/src/store/store.spec.js b/src/store/store.spec.js index aea99622..3aec63ef 100644 --- a/src/store/store.spec.js +++ b/src/store/store.spec.js @@ -799,7 +799,8 @@ describe('Store', () => { startTime: getRandomString(6, 6), endTime: getRandomString(6, 6), routeCode: getRandomString(6, 6), - jobMaxMinutes: getRandomString(6, 6) + jobMaxMinutes: getRandomString(6, 6), + jobMinMinutes: getRandomString(6, 6) }; store.order.schedule = schedule; globalMethods.callHttpClient = jest.fn().mockReturnValue(Promise.resolve({})); @@ -815,7 +816,8 @@ describe('Store', () => { startTime: schedule.startTime, endTime: schedule.endTime, routeCode: schedule.routeCode, - jobMaxMinutes: schedule.jobMaxMinutes + jobMaxMinutes: schedule.jobMaxMinutes, + jobMinMinutes: schedule.jobMinMinutes }) }) })); From 3fed3bd3e0d53a283a02c7d8709a84c881df53c0 Mon Sep 17 00:00:00 2001 From: Bill Richardson Date: Thu, 5 Oct 2023 16:02:27 -0400 Subject: [PATCH 09/14] update path --- src/layouts/schedule-page/schedule-page.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/layouts/schedule-page/schedule-page.vue b/src/layouts/schedule-page/schedule-page.vue index e898b7dc..379462ca 100644 --- a/src/layouts/schedule-page/schedule-page.vue +++ b/src/layouts/schedule-page/schedule-page.vue @@ -65,6 +65,7 @@ import siteHeader from '@/iss-components/site-header/site-header.vue'; import siteSubHeader from '@/iss-components/site-sub-header/site-sub-header.vue'; import locationAlerts from '@/layouts/schedule-page/location-alerts/location-alerts.vue'; import datePicker from '@/digital-components/date-picker/date-picker.vue'; +import timeSlotModalQuestion from '@/layouts/schedule-page/time-slot-modal-question/time-slot-modal-question.vue'; import siteFooter from '@/iss-components/site-footer/site-footer.vue'; import textBlock from '@/digital-components/text-block/text-block.vue'; @@ -87,7 +88,6 @@ import BaseFormMixin from '@/mixins/base-form-mixin.js'; import errorMessages from '@/constants/error-messages'; import { required } from '@/helpers/validation-rules'; import { useMainStore } from '@/store'; -import timeSlotModalQuestion from './time-slot-modal-question/time-slot-modal-question.vue'; // DEFINE VALIDATION RULES defineRule('date-required', required(errorMessages.DATE_REQUIRED)); From c3a2143ffae0321b3dcd39da9f918e633faa8f10 Mon Sep 17 00:00:00 2001 From: Bill Richardson Date: Thu, 5 Oct 2023 13:55:48 -0400 Subject: [PATCH 10/14] include mobile_insurance in mobile checks --- src/layouts/schedule-page/schedule-page.vue | 7 +++++-- src/store/index.js | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/src/layouts/schedule-page/schedule-page.vue b/src/layouts/schedule-page/schedule-page.vue index 379462ca..fd7ed442 100644 --- a/src/layouts/schedule-page/schedule-page.vue +++ b/src/layouts/schedule-page/schedule-page.vue @@ -130,7 +130,8 @@ const getAvailableDates = async ( apiEndDate = apiEndDateLimit; } - if (appointmentType === AppointmentTypeStrings.MOBILE) { + if (appointmentType === AppointmentTypeStrings.MOBILE + || appointmentType === AppointmentTypeStrings.MOBILE_INSURANCE) { storeActionConfig = { storeAction: GET_MOBILE_TIME_SLOTS, payload: { @@ -311,7 +312,8 @@ export default { const serviceLocationPreReqs = serviceLocation.zipCode && serviceLocation.zipCodeCtu && serviceLocation.appointmentType - && (serviceLocation.appointmentType === AppointmentTypeStrings.MOBILE + && ((serviceLocation.appointmentType === AppointmentTypeStrings.MOBILE + || serviceLocation.appointmentType === AppointmentTypeStrings.MOBILE_INSURANCE) || serviceLocation.provider.providerNumber); const paymentInfo = useMainStore().payment.isInsurance !== null; const supportingItems = useMainStore().lineItems.supportingItems !== null; @@ -319,6 +321,7 @@ export default { useMainStore().order.damage.isRepair || (useMainStore().order.lineItems?.glassParts != null && useMainStore().order.lineItems.glassParts.length > 0); + return serviceLocationPreReqs && paymentInfo && supportingItems && damageInfo; }, setData(initialShopTimeSlotsResponse) { diff --git a/src/store/index.js b/src/store/index.js index f498548b..08985695 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -641,7 +641,7 @@ export const useMainStore = defineStore({ startDate, endDate, applicationName: applicationConfig.APPLICATION_NAME, - parentAccountNumber: this.payment.parentAccountNumber, + parentAccountNumber: 167132, // this.payment.parentAccountNumber, carId: vehicle.carId, lineItems, glassPieces, From 6baa2f7d63fdc3289faafca3b21c00556e6ed234 Mon Sep 17 00:00:00 2001 From: Bill Richardson Date: Thu, 5 Oct 2023 16:10:11 -0400 Subject: [PATCH 11/14] use issConfig accountNumber --- src/store/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/store/index.js b/src/store/index.js index 08985695..a95c652d 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -641,7 +641,7 @@ export const useMainStore = defineStore({ startDate, endDate, applicationName: applicationConfig.APPLICATION_NAME, - parentAccountNumber: 167132, // this.payment.parentAccountNumber, + parentAccountNumber: this.issConfig.parentAccountNumber, carId: vehicle.carId, lineItems, glassPieces, From 40d427584264c6a71e38181e277da8338f74add9 Mon Sep 17 00:00:00 2001 From: Bill Richardson Date: Thu, 5 Oct 2023 16:36:46 -0400 Subject: [PATCH 12/14] update to use issConfig parentNumber --- src/store/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/store/index.js b/src/store/index.js index a95c652d..39df9e1a 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -641,7 +641,7 @@ export const useMainStore = defineStore({ startDate, endDate, applicationName: applicationConfig.APPLICATION_NAME, - parentAccountNumber: this.issConfig.parentAccountNumber, + parentAccountNumber: this.issConfig.parentAccountNumber, // this.payment.parentAccountNumber, carId: vehicle.carId, lineItems, glassPieces, @@ -703,7 +703,7 @@ export const useMainStore = defineStore({ endDate, shopAppointmentType, applicationName: applicationConfig.APPLICATION_NAME, - parentAccountNumber: 167132, // this.payment.parentAccountNumber, + parentAccountNumber: this.issConfig.parentAccountNumber, // this.payment.parentAccountNumber, carId: vehicle.carId, lineItems, glassPieces, From bf45490281d03974ec3c9d35f99ad8f2ca4e5cb3 Mon Sep 17 00:00:00 2001 From: Bill Richardson Date: Thu, 5 Oct 2023 17:00:15 -0400 Subject: [PATCH 13/14] change mobile_insurance to mobile_not_itac --- src/constants/schedule-constants.js | 2 +- src/layouts/schedule-page/schedule-page.vue | 4 ++-- .../appointment-type-question.vue | 8 ++++---- src/layouts/service-location/service-location.vue | 4 ++-- .../service-location/shop-question/shop-question.vue | 2 +- src/store/index.js | 2 +- src/store/store.spec.js | 2 +- 7 files changed, 12 insertions(+), 12 deletions(-) diff --git a/src/constants/schedule-constants.js b/src/constants/schedule-constants.js index 35232c04..af0c6206 100644 --- a/src/constants/schedule-constants.js +++ b/src/constants/schedule-constants.js @@ -1,7 +1,7 @@ const AppointmentTypeStrings = { IN_SHOP: 'Inshop', MOBILE: 'Mobile', - MOBILE_INSURANCE: 'Mobile-Insurance', + MOBILE_NOT_ITAC: 'Mobile-Not-ITAC', DROP_OFF: 'Dropoff' }; const PREMIUM_FEE_PART_TYPE = 'EARLY BIRD'; diff --git a/src/layouts/schedule-page/schedule-page.vue b/src/layouts/schedule-page/schedule-page.vue index fd7ed442..76db7eff 100644 --- a/src/layouts/schedule-page/schedule-page.vue +++ b/src/layouts/schedule-page/schedule-page.vue @@ -131,7 +131,7 @@ const getAvailableDates = async ( } if (appointmentType === AppointmentTypeStrings.MOBILE - || appointmentType === AppointmentTypeStrings.MOBILE_INSURANCE) { + || appointmentType === AppointmentTypeStrings.MOBILE_NOT_ITAC) { storeActionConfig = { storeAction: GET_MOBILE_TIME_SLOTS, payload: { @@ -313,7 +313,7 @@ export default { && serviceLocation.zipCodeCtu && serviceLocation.appointmentType && ((serviceLocation.appointmentType === AppointmentTypeStrings.MOBILE - || serviceLocation.appointmentType === AppointmentTypeStrings.MOBILE_INSURANCE) + || serviceLocation.appointmentType === AppointmentTypeStrings.MOBILE_NOT_ITAC) || serviceLocation.provider.providerNumber); const paymentInfo = useMainStore().payment.isInsurance !== null; const supportingItems = useMainStore().lineItems.supportingItems !== null; diff --git a/src/layouts/service-location/appointment-type-question/appointment-type-question.vue b/src/layouts/service-location/appointment-type-question/appointment-type-question.vue index c8eb4d56..3a4ffd96 100644 --- a/src/layouts/service-location/appointment-type-question/appointment-type-question.vue +++ b/src/layouts/service-location/appointment-type-question/appointment-type-question.vue @@ -59,7 +59,7 @@ export default { ? this.answersFromCms.filter((answer) => ( (answer.Name === AppointmentTypeStrings.IN_SHOP && shouldShowInshop) || (answer.Name === AppointmentTypeStrings.MOBILE && shouldShowMobile) - || (answer.Name === AppointmentTypeStrings.MOBILE_INSURANCE && shouldShowMobileInsurance) + || (answer.Name === AppointmentTypeStrings.MOBILE_NOT_ITAC && shouldShowMobileInsurance) || (answer.Name === AppointmentTypeStrings.DROP_OFF && shouldShowDropoff) )) : []; @@ -86,12 +86,12 @@ export default { if ( newValue.length === 1 && newValue.findIndex((answer) => (answer.Name === AppointmentTypeStrings.MOBILE - || answer.Name === AppointmentTypeStrings.MOBILE_INSURANCE)) !== -1 + || answer.Name === AppointmentTypeStrings.MOBILE_NOT_ITAC)) !== -1 ) { if (this.isITAC) { this.selectedValues = AppointmentTypeStrings.MOBILE; } else { - this.selectedValues = AppointmentTypeStrings.MOBILE_INSURANCE; + this.selectedValues = AppointmentTypeStrings.MOBILE_NOT_ITAC; } } }, @@ -103,7 +103,7 @@ export default { if (this.isITAC) { this.selectedValues = AppointmentTypeStrings.MOBILE; } else { - this.selectedValues = AppointmentTypeStrings.MOBILE_INSURANCE; + this.selectedValues = AppointmentTypeStrings.MOBILE_NOT_ITAC; } } } diff --git a/src/layouts/service-location/service-location.vue b/src/layouts/service-location/service-location.vue index d0b8af66..62484df8 100644 --- a/src/layouts/service-location/service-location.vue +++ b/src/layouts/service-location/service-location.vue @@ -262,7 +262,7 @@ export default { if (newValue.zipCode !== this.zipCode) { if (!(this.selectedAppointmentType === AppointmentTypeStrings.MOBILE - || this.selectedAppointmentType === AppointmentTypeStrings.MOBILE_INSURANCE)) { + || this.selectedAppointmentType === AppointmentTypeStrings.MOBILE_NOT_ITAC)) { this.selectedAppointmentType = null; } this.selectedProvider = null; @@ -293,7 +293,7 @@ export default { }, isMobileLocationDisplayed() { return this.selectedAppointmentType === AppointmentTypeStrings.MOBILE - || this.selectedAppointmentType === AppointmentTypeStrings.MOBILE_INSURANCE; + || this.selectedAppointmentType === AppointmentTypeStrings.MOBILE_NOT_ITAC; }, requiresInshopRecalibration() { // Specifically check for isRecalibrationServiceableMobile === false, not null or true. diff --git a/src/layouts/service-location/shop-question/shop-question.vue b/src/layouts/service-location/shop-question/shop-question.vue index 220f4ad4..59ded30c 100644 --- a/src/layouts/service-location/shop-question/shop-question.vue +++ b/src/layouts/service-location/shop-question/shop-question.vue @@ -142,7 +142,7 @@ export default { await nextTick(); - if (newValue !== AppointmentTypeStrings.MOBILE && newValue !== AppointmentTypeStrings.MOBILE_INSURANCE) { + if (newValue !== AppointmentTypeStrings.MOBILE && newValue !== AppointmentTypeStrings.MOBILE_NOT_ITAC) { this.getNextShopsFromList(); } } diff --git a/src/store/index.js b/src/store/index.js index 39df9e1a..6c40ab5b 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -195,7 +195,7 @@ export const useMainStore = defineStore({ policy: (state) => state.order.policy, hasAnyNonWindshieldGlassParts: (state) => !state.order.policy.isDamageGlassOnly, isMobileAppointment: (state) => state.order.serviceLocation.appointmentType === AppointmentTypeStrings.MOBILE - || state.order.serviceLocation.appointmentType === AppointmentTypeStrings.MOBILE_INSURANCE, + || state.order.serviceLocation.appointmentType === AppointmentTypeStrings.MOBILE_NOT_ITAC, isDropOffAppointment: (state) => state.order.serviceLocation.appointmentType === AppointmentTypeStrings.DROP_OFF, isClaimRegistrationRequired: (state) => state.issConfig.isClaimRegistrationRequired, eventBusItem: (state) => (eventCategory, eventSubCategory) => { diff --git a/src/store/store.spec.js b/src/store/store.spec.js index 7c4fc37c..9e30df93 100644 --- a/src/store/store.spec.js +++ b/src/store/store.spec.js @@ -1033,7 +1033,7 @@ describe('Store', () => { // Act store.updateServiceLocation({ - appointmentType: AppointmentTypeStrings.MOBILE_INSURANCE + appointmentType: AppointmentTypeStrings.MOBILE_NOT_ITAC }); // Assert From e42ef9c9ea86cc97ad3f974c31c8365ca1dcb726 Mon Sep 17 00:00:00 2001 From: Bill Richardson Date: Thu, 5 Oct 2023 17:03:21 -0400 Subject: [PATCH 14/14] consistency --- .../appointment-type-question/appointment-type-question.vue | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/layouts/service-location/appointment-type-question/appointment-type-question.vue b/src/layouts/service-location/appointment-type-question/appointment-type-question.vue index 3a4ffd96..dc7dadb2 100644 --- a/src/layouts/service-location/appointment-type-question/appointment-type-question.vue +++ b/src/layouts/service-location/appointment-type-question/appointment-type-question.vue @@ -52,14 +52,14 @@ export default { }, answersToDisplay() { const shouldShowMobile = this.isServiceableMobile && this.isITAC; - const shouldShowMobileInsurance = this.isServiceableMobile && !this.isITAC; + const shouldShowMobileNotITAC = this.isServiceableMobile && !this.isITAC; const shouldShowInshop = this.isServiceableInshop; const shouldShowDropoff = this.isServiceableInshop && !useMainStore().damage.isRepair; return this.answersFromCms ? this.answersFromCms.filter((answer) => ( (answer.Name === AppointmentTypeStrings.IN_SHOP && shouldShowInshop) || (answer.Name === AppointmentTypeStrings.MOBILE && shouldShowMobile) - || (answer.Name === AppointmentTypeStrings.MOBILE_NOT_ITAC && shouldShowMobileInsurance) + || (answer.Name === AppointmentTypeStrings.MOBILE_NOT_ITAC && shouldShowMobileNotITAC) || (answer.Name === AppointmentTypeStrings.DROP_OFF && shouldShowDropoff) )) : [];