From 65b4c291d6e45002985a680a34291d0c7aa7f29d Mon Sep 17 00:00:00 2001 From: lewa <lene.wasskog@nibio.no> Date: Fri, 26 Apr 2024 15:34:23 +0200 Subject: [PATCH] fix: Display of selected point (coordinates) in observation form --- src/components/MapObservation.vue | 2 +- src/components/Observation.vue | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/components/MapObservation.vue b/src/components/MapObservation.vue index ff62e8d..6cac739 100644 --- a/src/components/MapObservation.vue +++ b/src/components/MapObservation.vue @@ -518,7 +518,7 @@ export default { this.latitude = this.myGeoInfo.features[0].geometry.coordinates[0]; this.longitude = this.myGeoInfo.features[0].geometry.coordinates[1]; this.mapZoom = CommonUtil.CONST_GPS_OBSERVATION_ZOOM; - this.showOnlyUsersPOIs = this.myGeoInfo.features[0].properties.pointOfInterestTypeId !== 1; + this.showOnlyUsersPOIs = this.myGeoInfo.features[0].properties && this.myGeoInfo.features[0].properties.pointOfInterestTypeId !== 1; } else { this.mapZoom = CommonUtil.CONST_GPS_DEFAULT_ZOOM; } diff --git a/src/components/Observation.vue b/src/components/Observation.vue index e636fa2..e9321fc 100644 --- a/src/components/Observation.vue +++ b/src/components/Observation.vue @@ -70,7 +70,7 @@ <font-awesome-icon class="form-icon" icon="map-location"/>{{ mapGeoinfo ? $t("observation.map.label.edit") : $t("observation.map.label.new") }} </router-link> </div> - <div class="col-4 d-flex align-items-center justify-content-end" v-html="currentLocationName()"></div> + <div class="col-4 d-flex align-items-end justify-content-end" v-html="currentLocationName()"></div> </div> <div v-if="mapGeoinfo" id="divMapGeoInfo"> -- GitLab