CASH-201 | Switch to query parameter
This commit is contained in:
parent
37cd5f01bf
commit
738e6a108d
3 changed files with 18 additions and 15 deletions
|
|
@ -101,7 +101,7 @@ export default {
|
|||
return !!this.parentAccountNumber;
|
||||
},
|
||||
payWithCashButtonCopy() {
|
||||
return "Pay on my own";
|
||||
return this.getCmsContent("PayWithCashWidget", "Text");
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
|
@ -122,8 +122,11 @@ export default {
|
|||
},
|
||||
backButtonAction(forceCashSelectionOnQuote) {
|
||||
// Go back to Quote page
|
||||
if (forceCashSelectionOnQuote)
|
||||
this.$route.params['forceCashSelection'] = true;
|
||||
if (forceCashSelectionOnQuote) {
|
||||
this.$router.navigateWithoutSaving(this.navigationScenarios.CLICKED_BACK, this.$route, {"isCashSelected": true});
|
||||
return;
|
||||
}
|
||||
|
||||
this.$router.navigateWithoutSaving(this.navigationScenarios.CLICKED_BACK, this.$route);
|
||||
},
|
||||
async forwardButtonAction() {
|
||||
|
|
|
|||
|
|
@ -293,7 +293,7 @@ describe("quote.vue", () => {
|
|||
await quote.beforeRouteEnter.call(
|
||||
wrapper.vm,
|
||||
{ query: { fmgPage: "quote" } },
|
||||
{params:{}},
|
||||
undefined,
|
||||
(c) => c(wrapper.vm)
|
||||
);
|
||||
|
||||
|
|
@ -345,7 +345,7 @@ describe("quote.vue", () => {
|
|||
await quote.beforeRouteEnter.call(
|
||||
wrapper.vm,
|
||||
{ query: { fmgPage: "quote" } },
|
||||
{params:{}},
|
||||
undefined,
|
||||
(c) => c(wrapper.vm)
|
||||
);
|
||||
//Assert
|
||||
|
|
@ -388,7 +388,7 @@ describe("quote.vue", () => {
|
|||
await quote.beforeRouteEnter.call(
|
||||
wrapper.vm,
|
||||
{ query: { fmgPage: "quote" } },
|
||||
{params:{}},
|
||||
undefined,
|
||||
(c) => c(wrapper.vm)
|
||||
);
|
||||
|
||||
|
|
@ -432,7 +432,7 @@ describe("quote.vue", () => {
|
|||
await quote.beforeRouteEnter.call(
|
||||
wrapper.vm,
|
||||
{ query: { fmgPage: "quote", isInsurance: false } },
|
||||
{params:{}},
|
||||
undefined,
|
||||
(c) => c(wrapper.vm)
|
||||
);
|
||||
|
||||
|
|
@ -478,7 +478,7 @@ describe("quote.vue", () => {
|
|||
await quote.beforeRouteEnter.call(
|
||||
wrapper.vm,
|
||||
{ query: { fmgPage: "quote" } },
|
||||
{params:{}},
|
||||
undefined,
|
||||
(c) => c(wrapper.vm)
|
||||
);
|
||||
|
||||
|
|
@ -523,7 +523,7 @@ describe("quote.vue", () => {
|
|||
await quote.beforeRouteEnter.call(
|
||||
wrapper.vm,
|
||||
{ query: { fmgPage: "quote" } },
|
||||
{params:{}},
|
||||
undefined,
|
||||
(c) => c(wrapper.vm)
|
||||
);
|
||||
|
||||
|
|
@ -570,7 +570,7 @@ describe("quote.vue", () => {
|
|||
await quote.beforeRouteEnter.call(
|
||||
wrapper.vm,
|
||||
{ query: { fmgPage: "quote" } },
|
||||
{params:{}},
|
||||
undefined,
|
||||
(c) => c(wrapper.vm)
|
||||
);
|
||||
|
||||
|
|
@ -618,7 +618,7 @@ describe("quote.vue", () => {
|
|||
await quote.beforeRouteEnter.call(
|
||||
wrapper.vm,
|
||||
{ query: { fmgPage: "quote" } },
|
||||
{params:{}},
|
||||
undefined,
|
||||
(c) => c(wrapper.vm)
|
||||
);
|
||||
|
||||
|
|
@ -662,7 +662,7 @@ describe("quote.vue", () => {
|
|||
await quote.beforeRouteEnter.call(
|
||||
wrapper.vm,
|
||||
{ query: { fmgPage: "quote" } },
|
||||
{params:{}},
|
||||
undefined,
|
||||
(c) => c(wrapper.vm)
|
||||
);
|
||||
//Assert
|
||||
|
|
@ -783,7 +783,7 @@ describe("quote.vue", () => {
|
|||
await quote.beforeRouteEnter.call(
|
||||
wrapper.vm,
|
||||
{ query: { fmgPage: "quote" } },
|
||||
{params:{}},
|
||||
undefined,
|
||||
nextFunction
|
||||
);
|
||||
await nextTick();
|
||||
|
|
|
|||
|
|
@ -328,8 +328,8 @@ export default {
|
|||
}
|
||||
|
||||
const getIsInsuranceSelectedValue = (availableLineItems, insuranceThreshold) => {
|
||||
// routeParam checked here is set on insurance-selection "Pay on my own" link click
|
||||
if (from.params.forceCashSelection) {
|
||||
// query param checked here is set on insurance-selection "Pay on my own" link click
|
||||
if (to.query?.isCashSelected || to.query?.iscashselected) {
|
||||
return false;
|
||||
}
|
||||
const serviceLocationState = store.getters.order.serviceLocation.state;
|
||||
|
|
|
|||
Loading…
Reference in a new issue