This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
|
||||
<?php
|
||||
|
||||
$fecha = date('d_m_Y');
|
||||
@@ -43,6 +44,7 @@ $data_excel = array(
|
||||
"GRUPO" => 'horario_grupo',
|
||||
"HORARIO" => 'horario_hora_completa',
|
||||
"SALÓN" => 'salon',
|
||||
"UNIDAD" => 'salon_array'
|
||||
"REGISTRO PROFESOR" => 'asistencia',
|
||||
"HORA DE REGISTRO" => 'registro_fecha',
|
||||
"NOMBRE SUPERVISOR" => 'usuario_nombre',
|
||||
@@ -130,17 +132,15 @@ const DEFAULT_STYLE = [
|
||||
function getFormattedValue($key, $registro)
|
||||
{
|
||||
return match ($key) {
|
||||
'asistencia' => is_null($registro['registro_fecha'])
|
||||
? "Sin registro"
|
||||
: ($registro['registro_retardo'] ? "Retardo " : "Asistencia "),
|
||||
'registro_fecha', 'registro_fecha_supervisor' =>
|
||||
is_null($registro[$key])
|
||||
? 'Sin registro'
|
||||
: date('H:i', strtotime($registro[$key])),
|
||||
'asistencia' => is_null($registro['registro_fecha']) ? "Sin registro" : ($registro['registro_retardo'] ? "Retardo " : "Asistencia "),
|
||||
'registro_fecha',
|
||||
'registro_fecha_supervisor' => is_null($registro[$key]) ? 'Sin registro' : date('H:i', strtotime($registro[$key])),
|
||||
'nombre' => $registro[$key] ?? "Sin registro",
|
||||
'horario_hora_completa' => "{$registro['horario_hora']} - {$registro['horario_fin']}",
|
||||
'usuario_nombre', 'justificacion', 'comentario' =>
|
||||
$registro[$key] ?? "Sin registro",
|
||||
'usuario_nombre',
|
||||
'salon_array' => implode(", ", json_decode($registro[$key], true));
|
||||
'justificacion',
|
||||
'comentario' => $registro[$key] ?? "Sin registro",
|
||||
default => $registro[$key]
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user