Fix search result ajax request being sent multiple times
This commit is contained in:
+6
-4
@@ -2,7 +2,7 @@
|
||||
<div class="boardtypeselect">
|
||||
<div class="checkbox" v-for="boardType of boardTypesOptions">
|
||||
<label>
|
||||
<input type="checkbox" v-model.number="boardTypesSelected" :value="boardType.uid">
|
||||
<input type="checkbox" v-model.number="boardTypesSelected" :value="boardType.uid" @change="notifySelected">
|
||||
<span class="cr"><i class="cr-icon glyphicon glyphicon-ok"></i></span>
|
||||
{{ boardType.label }}
|
||||
</label>
|
||||
@@ -29,12 +29,14 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
notifySelected () {
|
||||
this.$emit('selected', this.boardTypesSelected);
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
boardTypes (value) {
|
||||
this.boardTypesSelected = value;
|
||||
},
|
||||
boardTypesSelected (value) {
|
||||
this.$emit('selected', value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<template v-if="busAvailable">
|
||||
<div class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" v-model="busSelected">
|
||||
<input type="checkbox" v-model="busSelected" @change="notifySelected">
|
||||
<span class="cr"><i class="cr-icon glyphicon glyphicon-ok"></i></span>
|
||||
Busanreise
|
||||
</label>
|
||||
@@ -32,12 +32,14 @@
|
||||
default: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
notifySelected () {
|
||||
this.$emit('selected', this.busSelected);
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
bus (value) {
|
||||
this.busSelected = value;
|
||||
},
|
||||
busSelected (value) {
|
||||
this.$emit('selected', value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+6
-4
@@ -2,7 +2,7 @@
|
||||
<div class="conceptselect">
|
||||
<div class="checkbox" v-for="concept of conceptOptions">
|
||||
<label>
|
||||
<input type="checkbox" v-model="conceptsSelected" :value="concept.uid">
|
||||
<input type="checkbox" v-model="conceptsSelected" :value="concept.uid" @change="notifySelected">
|
||||
<span class="cr"><i class="cr-icon glyphicon glyphicon-ok"></i></span>
|
||||
nur {{ concept.name }}
|
||||
</label>
|
||||
@@ -29,12 +29,14 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
notifySelected () {
|
||||
this.$emit('selected', this.conceptsSelected);
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
concepts (value) {
|
||||
this.conceptsSelected = value;
|
||||
},
|
||||
conceptsSelected (value) {
|
||||
this.$emit('selected', value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+2
-8
@@ -3,14 +3,14 @@
|
||||
<div class="destinationselect__section" v-for="(destination, uid) of selectableDestinations">
|
||||
<div class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" v-model.number="countryUidsSelected" :value="uid">
|
||||
<input type="checkbox" v-model.number="countryUidsSelected" :value="uid" @change="notifySelected">
|
||||
<span class="cr"><i class="cr-icon glyphicon glyphicon-ok"></i></span>
|
||||
<strong>{{ destination.country.label }}</strong>
|
||||
</label>
|
||||
</div>
|
||||
<div class="checkbox" v-for="region of destination.regions">
|
||||
<label>
|
||||
<input type="checkbox" v-model.number="regionUidsSelected" :value="region.uid">
|
||||
<input type="checkbox" v-model.number="regionUidsSelected" :value="region.uid" @change="notifySelected">
|
||||
<span class="cr"><i class="cr-icon glyphicon glyphicon-ok"></i></span>
|
||||
<span class="small">{{ region.label }}</span>
|
||||
</label>
|
||||
@@ -64,12 +64,6 @@
|
||||
},
|
||||
regionUids (value) {
|
||||
this.regionUidsSelected = value;
|
||||
},
|
||||
countryUidsSelected () {
|
||||
this.notifySelected();
|
||||
},
|
||||
regionUidsSelected () {
|
||||
this.notifySelected();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+6
-4
@@ -2,7 +2,7 @@
|
||||
<div class="hoteltypeselect">
|
||||
<div class="checkbox" v-for="hotelTypesOption of hotelTypesOptions">
|
||||
<label>
|
||||
<input type="checkbox" v-model.number="hotelTypesSelected" :value="hotelTypesOption">
|
||||
<input type="checkbox" v-model.number="hotelTypesSelected" :value="hotelTypesOption" @change="notifySelected">
|
||||
<span class="cr"><i class="cr-icon glyphicon glyphicon-ok"></i></span>
|
||||
{{ hotelTypesLabels[hotelTypesOption] }}
|
||||
</label>
|
||||
@@ -36,12 +36,14 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
notifySelected () {
|
||||
this.$emit('selected', this.hotelTypesSelected);
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
hotelTypes (value) {
|
||||
this.hotelTypesSelected = value;
|
||||
},
|
||||
hotelTypesSelected (value) {
|
||||
this.$emit('selected', value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+6
-4
@@ -2,7 +2,7 @@
|
||||
<div class="roomtypeselect">
|
||||
<div class="checkbox" v-for="roomTypesOption of roomTypesOptions">
|
||||
<label>
|
||||
<input type="checkbox" v-model.number="roomTypesSelected" :value="roomTypesOption">
|
||||
<input type="checkbox" v-model.number="roomTypesSelected" :value="roomTypesOption" @change="notifySelected">
|
||||
<span class="cr"><i class="cr-icon glyphicon glyphicon-ok"></i></span>
|
||||
{{ roomTypesLabels[roomTypesOption] }}
|
||||
</label>
|
||||
@@ -37,12 +37,14 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
notifySelected () {
|
||||
this.$emit('selected', this.roomTypesSelected);
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
roomTypes (value) {
|
||||
this.roomTypesSelected = value;
|
||||
},
|
||||
roomTypesSelected (value) {
|
||||
this.$emit('selected', value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -140,7 +140,6 @@
|
||||
resetFilterSettings () {
|
||||
this.updateFilterSettings(defaultFilterSettings);
|
||||
EventBus.$emit('filterSettingsReset');
|
||||
this.loadResults();
|
||||
},
|
||||
updateDestination (destination) {
|
||||
this.updateFilterSettings({
|
||||
|
||||
Reference in New Issue
Block a user