Admin - Mensajes y footer

This commit is contained in:
2020-04-16 16:27:20 -04:00
parent 080577d002
commit 575693def1
10 changed files with 107 additions and 11 deletions

View File

@ -24,11 +24,12 @@ class Notificacion {
if (isset($post['activo'])) {
$notificacion->activo = json_decode($post['activo']);
}
$filemanager->folder('data')->save($filename, $notificacion);
$status = $filemanager->folder('data')->save($filename, $notificacion);
$output = [
'informacion' => $post,
'editado' => $notificacion
'editado' => $notificacion,
'estado' => ($status !== false) ? 'ok' : 'error'
];
$response->getBody()->write(json_encode($output));
return $response

View File

@ -20,11 +20,12 @@ class Transparencia {
if (isset($post['activo'])) {
$transparencia->activo = json_decode($post['activo']);
}
$filemanager->folder('data')->save($filename, $transparencia);
$status = $filemanager->folder('data')->save($filename, $transparencia);
$output = [
'informacion' => $post,
'editado' => $transparencia
'editado' => $transparencia,
'estado' => ($status !== false) ? 'ok' : 'error'
];
$response->getBody()->write(json_encode($output));
return $response