From 3be8480a589d90b923ec26c3d51a4481ed692da3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Laura=20Kl=C3=BCnder?= Date: Wed, 26 Jul 2017 15:11:07 +0200 Subject: [PATCH] show graph items only in graph editing mode --- src/c3nav/editor/static/editor/js/editor.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/c3nav/editor/static/editor/js/editor.js b/src/c3nav/editor/static/editor/js/editor.js index 9c5eeca9..433bc650 100644 --- a/src/c3nav/editor/static/editor/js/editor.js +++ b/src/c3nav/editor/static/editor/js/editor.js @@ -349,6 +349,9 @@ editor = { if (remove_feature !== null) { geometries.splice(remove_feature, 1); } + if (editor._graph_editing === null) { + geometries = geometries.filter(function(val) { return val.properties.type !== 'graphnode' }) + } editor._geometries_layer = L.geoJSON(geometries, { style: editor._get_geometry_style, pointToLayer: editor._point_to_layer,