Save service package amounts in page data
This commit is contained in:
parent
54a1e36165
commit
dc6af2b3ba
2 changed files with 15 additions and 1 deletions
|
|
@ -561,8 +561,12 @@ export default {
|
|||
skipToInsurance: null,
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
async mounted() {
|
||||
this.attachCustomEventsForAnalytics();
|
||||
|
||||
await this.$nextTick();
|
||||
|
||||
this.$refs.servicePackage.savePackageInfoToPageData();
|
||||
},
|
||||
computed: {
|
||||
lineItemsCloneForWatcher() {
|
||||
|
|
|
|||
|
|
@ -44,6 +44,7 @@ import {
|
|||
import { containsRecalParts, getItemsWithoutRecalParts } from "@/helpers/recal-helper";
|
||||
import experimentMixin from "@/mixins/experiment-mixin.js";
|
||||
import { experimentSettings } from "@/constants/experiments";
|
||||
import { savePageData } from "@/router/methods/helpers/save-page-data";
|
||||
|
||||
export default {
|
||||
name: "servicePackageQuestion",
|
||||
|
|
@ -434,6 +435,15 @@ export default {
|
|||
return null;
|
||||
}
|
||||
},
|
||||
async savePackageInfoToPageData() {
|
||||
const answers = this.servicePackageAnswers;
|
||||
const toLog = answers.map((ans) => ({
|
||||
packageName: ans.buttonLabel,
|
||||
price: ans.buttonAuxillaryCopy,
|
||||
}));
|
||||
|
||||
await savePageData(this.pageName, toLog);
|
||||
},
|
||||
},
|
||||
components: {
|
||||
buttonQuestion,
|
||||
|
|
|
|||
Loading…
Reference in a new issue