summaryrefslogtreecommitdiffstats
path: root/modules-available/locationinfo/api.inc.php
diff options
context:
space:
mode:
authorJannik Schönartz2017-03-07 00:41:32 +0100
committerJannik Schönartz2017-03-07 00:41:32 +0100
commit4d31261bade95e74cf7a0edd88658fa7d915f46b (patch)
tree9ece33516331f6bdb75f228344ac39f1200a0128 /modules-available/locationinfo/api.inc.php
parentAPI: Fixed Calendar json decode was missing on the calendar part. (diff)
downloadslx-admin-4d31261bade95e74cf7a0edd88658fa7d915f46b.tar.gz
slx-admin-4d31261bade95e74cf7a0edd88658fa7d915f46b.tar.xz
slx-admin-4d31261bade95e74cf7a0edd88658fa7d915f46b.zip
API: Moved all echo command in the Handle Parameters function.
Diffstat (limited to 'modules-available/locationinfo/api.inc.php')
-rw-r--r--modules-available/locationinfo/api.inc.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/modules-available/locationinfo/api.inc.php b/modules-available/locationinfo/api.inc.php
index ff3c7269..45e48064 100644
--- a/modules-available/locationinfo/api.inc.php
+++ b/modules-available/locationinfo/api.inc.php
@@ -26,11 +26,11 @@ function HandleParameters() {
echo getPcStates($array);
} elseif ($getAction == "roomtree") {
$roomIDS = Request::get('id', 0, 'string');
- getRoomTree($roomIDS);
+ echo getRoomTree($roomIDS);
} elseif ($getAction == "calendar") {
$roomIDs = Request::get('id', 0, 'string');
$array = getMultipleInformations($roomIDs);
- getCalendar($array);
+ echo getCalendar($array);
}
}
@@ -100,7 +100,7 @@ function getCalendar($idList) {
$resultarray = array_merge($resultarray, $formattedArray);
}
- echo json_encode($resultarray, true);
+ return json_encode($resultarray, true);
}
// ########## </Calendar> ##########
@@ -239,7 +239,7 @@ function getRoomTree($ids) {
}
}
- echo json_encode($roomTree);
+ return json_encode($roomTree);
}
function getChildsRecursive($id, &$filteredIdList) {