diff --git a/components/DateInput.vue b/components/DateInput.vue index a20ad081..d43db681 100644 --- a/components/DateInput.vue +++ b/components/DateInput.vue @@ -8,7 +8,6 @@ v-col(cols=12) p {{ $t(`event.${type}_description`) }} - p {{value}} v-btn-toggle.v-col-6.flex-column.flex-sm-row(v-if='type === "recurrent"' color='primary' :value='value.recurrent.frequency' @change='fq => change("frequency", fq)') v-btn(v-for='f in frequencies' :key='f.value' :value='f.value') {{ f.text }} diff --git a/components/WhereInput.vue b/components/WhereInput.vue index 76ea1935..11ca66bb 100644 --- a/components/WhereInput.vue +++ b/components/WhereInput.vue @@ -11,8 +11,8 @@ v-row.mb-4 @input.native='search' persistent-hint :value='value.name' + item-text='name' :items="places" - @focus='search' @change='selectPlace') template(v-slot:item="{ item, attrs, on }") v-list-item(v-bind='attrs' v-on='on') @@ -38,6 +38,7 @@ v-row.mb-4 :label="$t('common.address')" :rules="[ v => disableAddress ? true : $validators.required('common.address')(v)]" :value='value.address' + item-text='address' persistent-hint hide-no-data clearable no-filter :loading='loading' @change='selectAddress' @@ -130,11 +131,13 @@ export default { }, selectPlace (p) { if (!p) { return } + console.error('dentro select place ', p) if (typeof p === 'object' && !p.create) { + if (p.id === this.value.id) return + console.error('quindi sono qui dentro !') this.place.name = p.name this.place.address = p.address if (this.settings.allow_geolocation) { - this.place.details = p.details this.place.latitude = p.latitude this.place.longitude = p.longitude } diff --git a/pages/index.vue b/pages/index.vue index 1c4be164..9cf24e80 100644 --- a/pages/index.vue +++ b/pages/index.vue @@ -1,12 +1,13 @@