From 5eb51d3c1a9d1f9a3bbc9a7e84e1f7e932a25f1d Mon Sep 17 00:00:00 2001 From: Jannik Schönartz Date: Thu, 30 Nov 2017 15:17:43 +0100 Subject: [locationinfo] removed seconds from the time. More than 4 locations are allowed for the summary panel --- modules-available/locationinfo/page.inc.php | 3 --- modules-available/locationinfo/templates/frontend-summary.html | 8 +++++++- 2 files changed, 7 insertions(+), 4 deletions(-) (limited to 'modules-available/locationinfo') diff --git a/modules-available/locationinfo/page.inc.php b/modules-available/locationinfo/page.inc.php index 2471a701..311b269d 100644 --- a/modules-available/locationinfo/page.inc.php +++ b/modules-available/locationinfo/page.inc.php @@ -327,9 +327,6 @@ class Page_LocationInfo extends Page { // Check locations $locationids = self::getLocationIdsFromRequest(true); - if (count($locationids) > 4) { - $locationids = array_slice($locationids, 0, 4); - } return array('locationids' => $locationids); } diff --git a/modules-available/locationinfo/templates/frontend-summary.html b/modules-available/locationinfo/templates/frontend-summary.html index e8406de4..7faa01e5 100644 --- a/modules-available/locationinfo/templates/frontend-summary.html +++ b/modules-available/locationinfo/templates/frontend-summary.html @@ -571,7 +571,13 @@ * @param time Time value */ function updateCoursTimer(id, time) { - $("#div_Time_" + id).text(time); + // TODO: Add seconds again with a better update rate. + var time_split = time.split(":"); + if (time != "") { + $("#div_Time_" + id).text(time_split[0] + ":" + time_split[1]); + } else { + $("#div_Time_" + id).text(time); + } } /** -- cgit v1.2.3-55-g7522