From adaa1f628f04a6af247e142edbea679578b90fef Mon Sep 17 00:00:00 2001
From: Jacek Kowalski <Jacek@jacekk.info>
Date: Sat, 15 Apr 2017 11:43:18 +0000
Subject: [PATCH] Add layers with stops and stop points
---
index.js | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/index.js b/index.js
index fd3d883..04e285b 100644
--- a/index.js
+++ b/index.js
@@ -257,6 +257,7 @@
addCellWithText(tr, data.old[i].stop_seq_num + '. ' + data.old[i].stop.name);
tr.className = 'active';
+ tr.addEventListener('click', function(stopId){ return function(){ loadTimes(stopId); } }(data.old[i].stop.shortName) );
route_table.appendChild(tr);
}
@@ -268,6 +269,7 @@
if(data.actual[i].status == 'STOPPING') {
tr.className = 'success';
}
+ tr.addEventListener('click', function(stopId){ return function(){ loadTimes(stopId); } }(data.actual[i].stop.shortName) );
route_table.appendChild(tr);
}
}).fail(fail_ajax);
--
Gitblit v1.10.0