index.html | ●●●●● patch | view | raw | blame | history | |
index.js | ●●●●● patch | view | raw | blame | history |
index.html
@@ -129,7 +129,7 @@ <p class="small" data-translate="help_text">Względne czasy (np. 3 min) są podawane na podstawie faktycznej lokalizacji pojazdów. Czasy bezwzględne (np. 8:01) to odjazdy rozkładowe, pokazywane gdy pojazd nie może być zlokalizowany. "?" oznacza nieznane opóźnienie.</p> <p class="small">© 2016-2017 Jacek Kowalski - <a href="https://github.com/jacekkow/mpk-ttss" data-translate="help_source">Źródło</a> - <a href="https://raw.githubusercontent.com/jacekkow/mpk-ttss/master/LICENSE" data-translate="help_license">Licencja</a></p> <p class="small">© 2016-2019 Jacek Kowalski - <a href="https://github.com/jacekkow/mpk-ttss" data-translate="help_source">Źródło</a> - <a href="https://raw.githubusercontent.com/jacekkow/mpk-ttss/master/LICENSE" data-translate="help_license">Licencja</a></p> </div> </div> </div> index.js
@@ -99,6 +99,16 @@ window.location.hash = '#!' + language + stopId; refresh_button.removeAttribute('disabled'); var alternative_stop = null; var candidate = null; for(var i = 0; i < stop_name_autocomplete.options.length; i++) { candidate = stop_name_autocomplete.options[i].value; if(candidate.substr(0, 1) != prefix && candidate.substr(1) == stop) { alternative_stop = candidate; break; } } times_xhr = $.get( url + '/services/passageInfo/stopPassages/stop' + '?stop=' + encodeURIComponent(stop) @@ -111,6 +121,17 @@ deleteChildren(times_table); //deleteChildren(times_lines); if(alternative_stop !== null) { var a = addParaWithText(times_alerts, ''); a = addElementWithText(a, 'a', (prefix == 'b' ? lang.departures_for_trams : lang.departures_for_buses)); a.href = ''; a.onclick = function(e) { e.preventDefault(); loadTimes(alternative_stop); }; } for(var i = 0, il = data.generalAlerts.length; i < il; i++) { addParaWithText(times_alerts, data.generalAlerts[i].title); }