forked from Ruderverein-Donau-Linz/rowt
reservations
This commit is contained in:
@ -7,6 +7,7 @@ export interface choiceMap {
|
||||
|
||||
let choiceObjects: choiceMap = {};
|
||||
let boat_in_ottensheim = true;
|
||||
let boat_reserved_today= true;
|
||||
|
||||
document.addEventListener("DOMContentLoaded", function () {
|
||||
changeTheme();
|
||||
@ -116,6 +117,7 @@ interface ChoiceBoatEvent extends Event {
|
||||
owner: number;
|
||||
default_destination: string;
|
||||
boat_in_ottensheim: boolean;
|
||||
boat_reserved_today: boolean;
|
||||
};
|
||||
};
|
||||
}
|
||||
@ -134,7 +136,13 @@ function selectBoatChange() {
|
||||
boatSelect.addEventListener(
|
||||
"addItem",
|
||||
function (e) {
|
||||
|
||||
const event = e as ChoiceBoatEvent;
|
||||
boat_reserved_today = event.detail.customProperties.boat_reserved_today;
|
||||
console.log(event.detail.customProperties);
|
||||
if (boat_reserved_today){
|
||||
alert(event.detail.label+' wurde heute reserviert. Bitte kontrolliere, dass du die Reservierung nicht störst.');
|
||||
}
|
||||
boat_in_ottensheim = event.detail.customProperties.boat_in_ottensheim;
|
||||
|
||||
const amount_seats = event.detail.customProperties.amount_seats;
|
||||
|
Reference in New Issue
Block a user