do not enable advanced button when no place name

This commit is contained in:
lesion 2023-04-10 18:34:10 +02:00
parent 77bc1a9a43
commit 0fd9bcf014
No known key found for this signature in database
GPG key ID: 352918250B012177

View file

@ -82,7 +82,7 @@ export default {
return { return {
mdiMap, mdiMapMarker, mdiPlus, mdiCog, mdiLink, mdiCloseCircle, mdiLaptopAccount, mdiMap, mdiMapMarker, mdiPlus, mdiCog, mdiLink, mdiCloseCircle, mdiLaptopAccount,
places: [], places: [],
place: { isNew: false }, place: { isNew: false, name: '' },
placeName: '', placeName: '',
disableAddress: true, disableAddress: true,
whereInputAdvancedDialog: false, whereInputAdvancedDialog: false,
@ -93,6 +93,8 @@ export default {
...mapState(['settings']), ...mapState(['settings']),
showAdvancedDialogButton () { showAdvancedDialogButton () {
if (!this.place.name) return false
// do not show advanced dialog button in case geolocation and online events are not allowed // do not show advanced dialog button in case geolocation and online events are not allowed
if (!(this.settings.allow_geolocation || this.settings.allow_online_event)) { if (!(this.settings.allow_geolocation || this.settings.allow_online_event)) {
return false return false