From 982c1b4ba4d55baf29afb6a1055c2fe33b5b105e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Rodrigo?= Date: Sat, 3 Nov 2018 18:09:59 +0100 Subject: [PATCH] Add way in result of analyser_osmosis_highway_traffic_signals #360 --- analysers/analyser_osmosis_highway_traffic_signals.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/analysers/analyser_osmosis_highway_traffic_signals.py b/analysers/analyser_osmosis_highway_traffic_signals.py index df56aa91d..423e5fd23 100644 --- a/analysers/analyser_osmosis_highway_traffic_signals.py +++ b/analysers/analyser_osmosis_highway_traffic_signals.py @@ -93,6 +93,7 @@ sql30 = """ SELECT nodes.id, + max(ways.id), ST_AsText(nodes.geom) FROM {0}traffic_signals AS nodes @@ -130,6 +131,7 @@ sql41 = """ SELECT nodes.id, + max(ways.id), ST_AsText(nodes.geom) FROM {0}stops AS nodes @@ -164,11 +166,11 @@ def __init__(self, config, logger = None): [{"+":{"crossing":"traffic_signals"}}, {"-":["crossing"]}] ] } self.callback20 = lambda res: {"class":2, "data":[self.node_full, self.positionAsText]} - self.callback30 = lambda res: {"class":3, "data":[self.node_full, self.positionAsText], "fix":[ + self.callback30 = lambda res: {"class":3, "data":[self.node_full, self.way, self.positionAsText], "fix":[ [{"+":{"traffic_signals:direction":"forward"}}], [{"+":{"traffic_signals:direction":"backward"}}], ] } - self.callback40 = lambda res: {"class":4, "data":[self.node_full, self.positionAsText], "fix":[ + self.callback40 = lambda res: {"class":4, "data":[self.node_full, self.way, self.positionAsText], "fix":[ [{"+":{"direction":"forward"}}], [{"+":{"direction":"backward"}}], ] }