diff --git a/public/typo3conf/ext/ep_theme/Resources/Private/Assets/js/components/GroupsPriceCalculator.vue b/public/typo3conf/ext/ep_theme/Resources/Private/Assets/js/components/GroupsPriceCalculator.vue index ab70e8e2..c9597eef 100644 --- a/public/typo3conf/ext/ep_theme/Resources/Private/Assets/js/components/GroupsPriceCalculator.vue +++ b/public/typo3conf/ext/ep_theme/Resources/Private/Assets/js/components/GroupsPriceCalculator.vue @@ -8,6 +8,10 @@ +

+ Einzelne Nächte sind nur auf Anfrage buchbar +

@@ -153,7 +157,7 @@
- Jetzt buchen + Jetzt buchenanfragen
@@ -230,13 +234,15 @@
-
@@ -256,7 +262,6 @@ import 'dayjs/locale/de' import 'flatpickr'; import {German} from 'flatpickr/dist/l10n/de'; import Vue from 'vue'; -import axios from 'axios'; export default { name: 'GroupsPriceCalculator', @@ -404,30 +409,31 @@ export default { )) this.processing = true; this.submitted = false; - axios({ - url: this.endpoint, - method: 'POST', - data: formData, - }).then(response => { - if ('validation' === response.data.status) { - this.formErrors = response.data.errors; - } else { - this.submitted = true; - window.dataLayer = window.dataLayer || []; - dataLayer.push({ - 'event': 'Preisberechnung' - }) - } - }).catch(error => { - }).finally(() => { - this.processing = false; - }); + fetch(this.endpoint, { method: 'POST', body: formData }) + .then(response => response.json()) + .then((json) => { + if ('validation' === json.status) { + this.formErrors = json.errors + } else { + this.submitted = true; + window.dataLayer = window.dataLayer || []; + dataLayer.push({ + 'event': 'Preisberechnung' + }) + } + }) + .finally(() => { + this.processing = false + }) } }, computed: { nightsCount() { return this.selectedRange.length; }, + forceInquiry() { + return 1 === this.selectedRange.length + }, rangeFormatted() { if (null === this.selectedFrom || null === this.selectedTo) { return '-';