Improved www.ttss.krakow.pl
Jacek Kowalski
2019-02-03 f7f4ce5a4f2ae6b5f0cbbe549651b3c5ba5fcbbc
Fix searching for parent stop of a stop point
2 files modified
6 ■■■■ changed files
map.html 2 ●●● patch | view | raw | blame | history
map.js 4 ●●●● patch | view | raw | blame | history
map.html
@@ -18,6 +18,6 @@
<script src="https://cdn.jsdelivr.net/gh/openlayers/openlayers.github.io@master/en/v5.3.0/build/ol.js" integrity="sha384-iQkGyyH4ioz3m+maM3s9MX1Oq67mACa4B9Z3ovUv3Sv37LJ96fx3WnZfLoiC3Wfl" crossorigin="anonymous"></script>
<script tyle="text/javascript" src="lang_pl.js?v3" id="lang_script"></script>
<script tyle="text/javascript" src="common.js?v5"></script>
<script tyle="text/javascript" src="map.js?v7"></script>
<script tyle="text/javascript" src="map.js?v8"></script>
</body>
</html>
map.js
@@ -551,6 +551,10 @@
            addElementWithText(additional, 'a', lang.departures_for_stop).addEventListener(
                'click',
                function() {
                    var stops_source = stops_trams_source;
                    if(feature.getId().startsWith('pb')) {
                        stops_source = stops_buses_source;
                    }
                    featureClicked(stops_source.forEachFeature(function(stop_feature) {
                        if(stop_feature.get('shortName') == feature.get('shortName') && stop_feature.getId().substr(1,1) == feature.getId().substr(1,1)) {
                            return stop_feature;