summaryrefslogtreecommitdiffstats
path: root/modules-available/locationinfo/inc/infopanel.inc.php
diff options
context:
space:
mode:
Diffstat (limited to 'modules-available/locationinfo/inc/infopanel.inc.php')
-rw-r--r--modules-available/locationinfo/inc/infopanel.inc.php9
1 files changed, 9 insertions, 0 deletions
diff --git a/modules-available/locationinfo/inc/infopanel.inc.php b/modules-available/locationinfo/inc/infopanel.inc.php
index edeb9ccf..fdc253f0 100644
--- a/modules-available/locationinfo/inc/infopanel.inc.php
+++ b/modules-available/locationinfo/inc/infopanel.inc.php
@@ -37,6 +37,9 @@ class InfoPanel
$overrides = $json['overrides'];
}
unset($json['overrides']);
+ if (!isset($json['roomplanner'])) {
+ $config['roomplanner'] = false;
+ }
$config = $json + $config;
}
}
@@ -75,6 +78,8 @@ class InfoPanel
}
/**
+ * {"language":"de","mode":1,"vertical":true,"eco":false,"scaledaysauto":true,"daystoshow":7,"rotation":0,"scale":56,"switchtime":10,"calupdate":120,"roomupdate":20,
+ * "overrides": { "12" : { "mode":4} }
* Gets the location info of the given locations.
* Append to passed array which is expected to
* map location ids to properties of that location.
@@ -157,6 +162,8 @@ class InfoPanel
// Iterate over the locations we're actually interested in
$locations = Location::getLocationsAssoc();
foreach ($idList as $locationId) {
+ if (empty($locationId))
+ continue;
// Start checking at actual location...
$currentId = $locationId;
while ($currentId !== 0) {
@@ -175,6 +182,8 @@ class InfoPanel
}
}
// Keep trying with parent
+ if (!isset($locations[$currentId]))
+ break;
$currentId = $locations[$currentId]['parentlocationid'];
}
}