Add 'Reisen-Alert' button in place of booking button when hidden

This commit is contained in:
Björn Fromme
2020-03-05 12:59:28 +01:00
parent 734946d3c7
commit 6c5ea3956a
8 changed files with 35 additions and 5 deletions
@@ -73,6 +73,7 @@
<td class="dates-table__cell dates-table__cell--buttons hidden-xs">
<button v-if="row.available || row.isHideBookingButton" class="button button--small" @click="loadPriceTable(row.dateUid)">Details</button>
<a :href="row.bookingUrl" target="_blank" v-if="row.available && !row.isHideBookingButton" class="button button--small button--action">Buchen</a>
<a :href="travelAlertUrl" v-if="row.isHideBookingButton" class="button button--small button--mute">Reisen-Alert</a>
<span v-if="!row.available && !row.isHideBookingButton" class="label label-default">ausgebucht</span>
</td>
</tr>
@@ -143,6 +144,10 @@
showHeader: {
type: Boolean,
default: true
},
travelAlertUrl: {
type: String,
required: true
}
},
data () {
@@ -77,6 +77,8 @@
<td class="hidden-xs hidden-md">
<a class="button button--small button--action" v-if="row.roomAvailable && !row.isHideBookingButton"
:href="row.bookingUrl" target="_blank">Buchen</a>
<a class="button button--small button--mute" v-if="row.isHideBookingButton"
:href="travelAlertUrl">Reisen-Alert</a>
<span v-if="!row.roomAvailable && !row.isHideBookingButton" class="label label-default">ausgebucht</span>
</td>
</tr>
@@ -132,8 +134,12 @@
default: false
},
showHeader: {
typoe: Boolean,
type: Boolean,
default: true
},
travelAlertUrl: {
type: String,
required: true
}
},
data () {
@@ -78,6 +78,11 @@
color: white;
}
&--mute {
background-color: $color-grey-dark;
color: white;
}
.button-group &:not(:last-of-type) {
margin-right: 8px;
}
@@ -159,6 +159,7 @@
:alt-label="altLabel"
hotel-name="{hotel.name}"
:bookable="bookable"
travel-alert-url="{f:uri.typolink(parameter: settings.travelAlertPageUid)}"
></dates-table>
</template>
<f:if condition="{isProductWithNoInfoConcept}">
@@ -175,8 +176,12 @@
<!-- /Dates -->
<!-- Prices -->
<div v-cloak v-show="!loading && priceTableShow">
<price-table :price-table-rows="priceTableRows" :services-included="servicesIncluded"
:date-label="dateLabel" :single-date="singleDate"></price-table>
<price-table :price-table-rows="priceTableRows"
:services-included="servicesIncluded"
:date-label="dateLabel"
:single-date="singleDate"
travel-alert-url="{f:uri.typolink(parameter: settings.travelAlertPageUid)}"
></price-table>
<f:alias map="{currentPageUid: 1}">
<f:render partial="Product/Details" arguments="{_all}"/>
</f:alias>