X-Git-Url: https://git.llucax.com/z.facultad/75.43/tp1.git/blobdiff_plain/f75f7cc7a8d3d1613244e8554742c5d6e671fbf8..3bbf318b1618ff9ba0352ff789c1c6ba010cd72d:/src/admin.log.php diff --git a/src/admin.log.php b/src/admin.log.php index e7d24c8..df0854f 100644 --- a/src/admin.log.php +++ b/src/admin.log.php @@ -11,13 +11,33 @@ require_once 'lib/pagina.php'; require_once 'lib/LogMsg.php'; require_once 'lib/listador.php'; +require_once 'lib/validacion.php'; +require_once 'lib/admin.forms.php'; marco_cabecera('Log de actividades'); + p($_SESSION['user']->toHtml()); -$log = new LogMsg($_SESSION['user']); -listar($log, 'admin.log.php', 'Listado de actividades', - 'Listado de actividades'); +$desde = 0; +$mes = date('m'); +$dia = date('d'); +$anio = date('Y'); +// Cargo datos que vienen por GET (si corresponde) +if (isset($_GET['admin_anio']) and isset($_GET['admin_mes']) + and isset($_GET['admin_dia']) and !isset($_GET['admin_todo'])) +{ + $mes = intval($_GET['admin_mes']); + $dia = intval($_GET['admin_dia']); + $anio = intval($_GET['admin_anio']); +} + +if (!isset($_GET['admin_todo']) and check_fecha($anio, $mes, $dia)) + $desde = mktime(0, 0, 0, $mes, $dia, $anio); + +$log = new LogMsg($_SESSION['user'], $desde); +listar($log, 'admin.log.php'); + +admin_form_log_desde($anio, $mes, $dia); marco_pie('Leandro Lucarella', 'llucare@fi.uba.ar');