Merge pull request #1815 from Safelite/feature/Digital/CSR-2039
CSR-2039
This commit is contained in:
commit
5fce807c5b
5 changed files with 2 additions and 10 deletions
|
|
@ -105,16 +105,12 @@ export async function getImplicitNavigation(toRoute) {
|
|||
Used to navigate to the heritage funnel with the correct query string and url.
|
||||
*/
|
||||
|
||||
export async function navigateToHeritageFunnel({ shouldSaveSession, pageNameToLog, loadingModal }) {
|
||||
export async function navigateToHeritageFunnel({ shouldSaveSession, pageNameToLog }) {
|
||||
// Create the order (or save existing order) when navigating to Heritage Funnel.
|
||||
if (shouldSaveSession) {
|
||||
await saveSession({ pageNameToLog: pageNameToLog, shouldAwaitSaveSessionQueue: true });
|
||||
}
|
||||
|
||||
if (loadingModal && loadingModal.showModal) {
|
||||
loadingModal.showModal();
|
||||
}
|
||||
|
||||
var heritageParms = {
|
||||
corid: store.getters.order.referralCorrelationId,
|
||||
src: "concept-funnel",
|
||||
|
|
|
|||
|
|
@ -554,7 +554,7 @@ describe("navigateToHeritageFunnel", () => {
|
|||
router.navigateToExternalUrl = jest.fn();
|
||||
|
||||
// Act
|
||||
await navigateToHeritageFunnel({ loadingModal: null, shouldSaveSession: true });
|
||||
await navigateToHeritageFunnel({ shouldSaveSession: true });
|
||||
|
||||
// Assert
|
||||
expect(saveSessionFunction).toHaveBeenCalled();
|
||||
|
|
|
|||
|
|
@ -9,7 +9,6 @@ import { storeActions } from "@/constants/store-actions";
|
|||
import { storeMutations } from "@/constants/store-mutations";
|
||||
import { navigationScenarios } from "@/router/router-constants/navigation-scenarios";
|
||||
import store from "@/store";
|
||||
import { navigateToHeritageFunnel } from "@/helpers/heritage-integration/navigation-helper";
|
||||
import { experimentSettings } from "@/constants/experiments";
|
||||
|
||||
jest.mock("@/helpers/damage-helper", () => ({
|
||||
|
|
|
|||
|
|
@ -79,7 +79,6 @@ import { fetchCmsContentForPage } from "@/helpers/cms-content-helper";
|
|||
import baseMixin from "@/mixins/base-mixin.js";
|
||||
import { storeActions } from "@/constants/store-actions";
|
||||
import { settleAllPromises } from "@/helpers/layout-helper";
|
||||
import { navigateToHeritageFunnel } from "@/helpers/heritage-integration/navigation-helper";
|
||||
import { splitCopyOnCMSPlaceHolder } from "@/helpers/cms-content-helper";
|
||||
import {
|
||||
calcDaysBetweenDates,
|
||||
|
|
|
|||
|
|
@ -458,13 +458,11 @@ export default {
|
|||
navigateToHeritageFunnel({
|
||||
shouldSaveSession: true,
|
||||
pageNameToLog: currentPage,
|
||||
loadingModal: self.$refs.loadingModal,
|
||||
});
|
||||
} else if (payment.isInsurance && payment.insuranceCoverage.isVerified) {
|
||||
navigateToHeritageFunnel({
|
||||
shouldSaveSession: true,
|
||||
pageNameToLog: currentPage,
|
||||
loadingModal: self.$refs.loadingModal,
|
||||
});
|
||||
} else {
|
||||
self.$router.navigateWithSaving(
|
||||
|
|
|
|||
Loading…
Reference in a new issue