Checkpoint - Quote page models now opening programatically

This commit is contained in:
Leah Schumann 2023-01-31 08:37:14 -05:00
parent 3abb66cf8e
commit 9f363c5ed9
4 changed files with 14 additions and 17 deletions

View file

@ -53,7 +53,7 @@ https://safelite.atlassian.net/wiki/spaces/DC/pages/76644418/Button+Question+Com
:lastValuePushedToGa="lastValuePushedToGa"
:setLastValuePushedToGa="setLastValuePushedToGa"
:suppressError="suppressError"
@openModal="openModal"
@nestedComponentEvent="handleNestedComponentEvent"
v-model="selectedValues" />
<!-- For nested questions -->
<transition name="fade" mode="out-in">
@ -215,9 +215,10 @@ export default {
setLastValuePushedToGa(lastValuePushedToGa) {
this.lastValuePushedToGa = lastValuePushedToGa;
},
openModal(modalName) {
this.$emit("openModal", modalName);
}
handleNestedComponentEvent(event) {
const eventName = event.eventName;
this.$emit(`${eventName}`, event.args);
},
},
components: {
listButton,

View file

@ -320,7 +320,6 @@ export default {
}
function fillInAddress(place) {
console.log("fillInAddress");
if (!place) {
place = autocomplete.getPlace();
}
@ -416,11 +415,6 @@ export default {
}
},
},
"addressModel.streetAddress": {
handler(newValue, oldValue) {
console.log(`I got changed from ${oldValue} to ${newValue}`);
},
},
},
components: {
textboxQuestion,

View file

@ -1,5 +1,6 @@
<template>
<buttonQuestion ref="buttonQuestion"
<buttonQuestion
ref="buttonQuestion"
:answers="servicePackageAnswers"
:groupName="groupName"
buttonTypeString="servicePackageRadio"
@ -142,7 +143,6 @@ export default {
shouldDisplayTierTwoPackage() {
return this.frontWipersApplicableForTierTwo || this.rearWiperApplicableForTierTwo;
},
},
methods: {
processIfStatements,

View file

@ -32,9 +32,14 @@
linkType="text"
:text="getRouterLinkDisplayTextFromCopy(copy)"
href="#!"
@click-event="$emit('openModal', getRouterLinkRouteFromCopy(copy))"
@click-event="
$emit('nestedComponentEvent', {
eventName: 'openModal',
args: getRouterLinkRouteFromCopy(copy),
})
"
:data-bs-target="'#' + getRouterLinkRouteFromCopy(copy)"
aria-label="Modal window" />
aria-label="Modal window" />
<!-- <textLink
linkType="text"
:text="getRouterLinkDisplayTextFromCopy(copy)"
@ -95,9 +100,6 @@ export default {
.split(/(?:<li(?:.*?)>)|(?:<\/li>)/g)
.filter((lineItem) => lineItem);
},
openModal(modalName) {
this.$emit("openModal", modalName);
}
},
};
</script>