From e3954194df16676f23894594fdd4cdd0e4816dc6 Mon Sep 17 00:00:00 2001 From: Chloe Herd Date: Wed, 20 Aug 2025 15:29:03 -0400 Subject: [PATCH] Only mark email popup as skippable after forward nav from quote. --- src/layouts/quote/quote.spec.js | 5 +++++ src/layouts/quote/quote.vue | 6 +++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/src/layouts/quote/quote.spec.js b/src/layouts/quote/quote.spec.js index f555b6c16..a3f3687f7 100644 --- a/src/layouts/quote/quote.spec.js +++ b/src/layouts/quote/quote.spec.js @@ -10,6 +10,7 @@ import { experimentSettings } from "@/constants/experiments"; import experimentMixin from "@/mixins/experiment-mixin.js"; import baseMixin from "@/mixins/base-mixin.js"; import { containsLineItemWithPartType } from "../../helpers/service-package-helper"; +import { savePageData } from "../../router/methods/helpers/save-page-data"; jest.mock("@/store", () => ({ commit: jest.fn(), // Mock store.commit @@ -90,6 +91,10 @@ jest.mock("@/mixins/base-mixin", () => ({ }, })); +jest.mock("@/router/methods/helpers/save-page-data", () => ({ + savePageData: jest.fn(), +})); + const mockExperimentSettings = experimentSettings; jest.mock("@/mixins/experiment-mixin.js", () => ({ diff --git a/src/layouts/quote/quote.vue b/src/layouts/quote/quote.vue index 51b542fbf..6e62392b3 100644 --- a/src/layouts/quote/quote.vue +++ b/src/layouts/quote/quote.vue @@ -673,14 +673,12 @@ export default { async closeSaveProgressPopup() { this.showSaveProgressPopup = false; - savePageData(this.pageName, { saveProgressPopupSkipped: true }, true); - if (this.skipToInsurance) { // skip ahead now if in IGQ skip experiment await this.skip(true, externalParamPackageLabels.GLASS_ONLY); } }, - forwardButtonAction() { + async forwardButtonAction() { this.dispatchStoreAction( this.storeActions.SAVE_PAYMENT_TYPE, this.isInsuranceSelected, @@ -751,6 +749,8 @@ export default { false ); + await savePageData(this.pageName, { saveProgressPopupSkipped: true }, true); + const payment = this.$store.getters.payment; if (payment.isInsurance) { this.$router.navigateWithSaving(