Added visuals for charts (massive commit)

This commit is contained in:
Florian Sylvain
2022-01-09 04:10:14 +01:00
parent beb5382369
commit 6a9a63d7a0
8 changed files with 312 additions and 22 deletions
+2 -3
View File
@@ -2,8 +2,7 @@
require_once("class/dump.php");
if (!isset($_GET['q']) || !isset($_GET['search']) || !isset($_GET['option']) || !isset($_GET['offset']) ||
($_GET['option'] == 'establishment' && $_GET['q'] == 'establishment')) {
if (!isset($_GET['q']) || !isset($_GET['search']) || !isset($_GET['option']) || !isset($_GET['offset'])) {
print_r(json_encode(array("status" => 400, "message" => "Missing query type or attributes.")));
exit();
}
@@ -27,7 +26,7 @@ $json_object = match ($q) {
"count" => dump::getThesesCount($search, $option),
"years" => dump::getThesesYears($search, $option),
"disciplines" => dump::getThesesDisciplines($search, $option),
"establishment" => dump::getThesesEstablishments($search, $option),
"establishments" => dump::getThesesEstablishments($search, $option),
default => NULL,
};