From 588c4c6c9db2d31970ddded2d70d436617ddb63e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timoth=C3=A9e=20Poussard?= <tpoussard@neogeo.fr> Date: Tue, 7 Sep 2021 14:10:28 +0200 Subject: [PATCH] removes click on map and enable drag map --- src/store/modules/map.js | 2 +- src/views/feature/Feature_detail.vue | 47 +++++----------------------- src/views/project/Project_detail.vue | 9 ++---- 3 files changed, 11 insertions(+), 47 deletions(-) diff --git a/src/store/modules/map.js b/src/store/modules/map.js index 470e3b63..d8202f6b 100644 --- a/src/store/modules/map.js +++ b/src/store/modules/map.js @@ -159,7 +159,7 @@ const map = { dispatch("ADD_FEATURES"); // Remove multiple interactions with the map - mapUtil.getMap().dragging.disable(); + //mapUtil.getMap().dragging.disable(); mapUtil.getMap().doubleClickZoom.disable(); mapUtil.getMap().scrollWheelZoom.disable(); diff --git a/src/views/feature/Feature_detail.vue b/src/views/feature/Feature_detail.vue index 737e474c..3c83de28 100644 --- a/src/views/feature/Feature_detail.vue +++ b/src/views/feature/Feature_detail.vue @@ -159,12 +159,7 @@ </div> <div class="seven wide column"> - <a - id="feature-list-link" - href="{% url 'geocontrib:feature_list' slug=feature.project.slug %}" - > - <div id="map"></div> - </a> + <div id="map"></div> </div> </div> @@ -398,7 +393,7 @@ export default { }, ], mock_linked_features: [ - { + /* { relation_type: "Doublon", feature_to: { title: "Éolienne offshore", @@ -408,48 +403,21 @@ export default { title: "Éolienne", }, }, - }, + }, */ ], attachments: [ // TODO : Récupérer depuis l'api - { + /* { attachment_file: { url: "http://localhost:8000/media/user_1/albinoscom.jpg", }, extension: "jpg", title: "albinos", info: "Drôle de bête", - }, + }, */ ], // TODO : Récupérer depuis l'api - events: [ - { - event_type: "create", - object_type: "feature", - created_on: new Date().toDateString(), - display_user: "Babar", - }, - { - event_type: "create", - object_type: "comment", - created_on: new Date().toDateString(), - display_user: "Babar", - related_comment: { - attachments: [ - { - title: "Albinos", - url: "http://localhost:8000/media/user_1/albinoscom.jpg", - }, - ], - }, - }, - { - event_type: "update", - object_type: "feature", - created_on: new Date().toDateString(), - display_user: "Babar", - }, - ], + events: [], comment_form: { attachment_file: { errors: null, @@ -483,7 +451,8 @@ export default { }, linked_features: function () { // todo: vérifier avec données réels si ça fonctionne correctement - return this.mock_linked_features.filter((el) => el.feature_to); + //return this.mock_linked_features.filter((el) => el.feature_to); + return []; }, }, diff --git a/src/views/project/Project_detail.vue b/src/views/project/Project_detail.vue index 5401956e..58a2b35a 100644 --- a/src/views/project/Project_detail.vue +++ b/src/views/project/Project_detail.vue @@ -5,7 +5,7 @@ <div v-if="tempMessage" class="ui positive message"> <!-- <i class="close icon"></i> --> <!-- <div class="header">You are eligible for a reward</div> --> - + <p><i class="check icon"></i> {{ tempMessage }}</p> </div> </div> @@ -230,12 +230,7 @@ </div> </div> <div class="seven wide column"> - <router-link - :to="{ name: 'liste-signalements', params: { slug: project.slug } }" - class="item" - > - <div id="map"></div> - </router-link> + <div id="map"></div> </div> </div> -- GitLab