refactor of whereInput, move geolocation related code to whereInputAdvanced

This commit is contained in:
sedum
2023-02-19 23:19:16 +01:00
parent f298fe2fed
commit eefc0bb2df
4 changed files with 108 additions and 119 deletions

View File

@@ -239,8 +239,11 @@ export default {
}
formData.append('place_name', this.event.place.name.trim())
formData.append('place_address', this.event.place.address)
formData.append('place_latitude', this.event.place.latitude)
formData.append('place_longitude', this.event.place.longitude)
if (this.settings.allow_geolocation) {
formData.append('place_latitude', this.event.place.latitude || '')
formData.append('place_longitude', this.event.place.longitude || '')
}
if (this.event.locations.length) {
this.event.locations.forEach(location => formData.append('locations[]', location.url))