From 0ba7498c8b7397c579a1c5ade8ad22bcabd1e5cf Mon Sep 17 00:00:00 2001
From: Jacek Kowalski <Jacek@jacekk.info>
Date: Mon, 25 Mar 2019 21:20:58 +0000
Subject: [PATCH] Fix stop point table - stop table is displayed instead

---
 common.js |   13 ++++++++-----
 1 files changed, 8 insertions(+), 5 deletions(-)

diff --git a/common.js b/common.js
index f238013..6733d46 100644
--- a/common.js
+++ b/common.js
@@ -1,9 +1,12 @@
 "use strict";
 
-//var ttss_trams_base = 'http://www.ttss.krakow.pl/internetservice';
-var ttss_trams_base = 'proxy_tram.php';
-//var ttss_buses_base = 'http://91.223.13.70/internetservice';
-var ttss_buses_base = 'proxy_bus.php';
+var ttss_urls = {
+	t: 'proxy_tram.php',
+	// t: 'http://www.ttss.krakow.pl/internetservice',
+	b: 'proxy_bus.php',
+	// b: 'http://91.223.13.70/internetservice',
+};
+var ttss_types = ['t', 'b'];
 
 // Special directions
 var special_directions = {
@@ -117,7 +120,7 @@
 function depotIdToVehicleId(depotId, typeHelper) {
 	if(typeHelper) {
 		for(var prop in vehicles_info) {
-			if(prop.substr(0,1) == type && vehicles_info[prop]['num'].substr(2) == depotId) {
+			if(prop.substr(0,1) == typeHelper && vehicles_info[prop]['num'].substr(2) == depotId) {
 				return prop;
 			}
 		}

--
Gitblit v1.9.1