This commit is contained in:
Lizandro Guarnizo
2026-03-10 18:42:51 -05:00
parent b57fc16ab3
commit db469b2134
98 changed files with 16365 additions and 303 deletions
+17
View File
@@ -0,0 +1,17 @@
<?php
/**
* GET /api/lab/get_config.php — config global del lab
* GET /api/lab/get_config.php?forma=1 — config como objeto clave=>valor (para el builder)
*/
require_once __DIR__ . '/_helpers.php';
requireMethod('GET');
$db = Database::getInstance();
$rows = $db->fetchAll('SELECT clave, valor FROM lab_config ORDER BY clave');
$cfg = [];
foreach ($rows as $r) {
$cfg[$r['clave']] = $r['valor'];
}
jsonOk(['config' => $cfg]);