From 6bafc570f6fdbe3739da681fb0b6b21be5c5a6c8 Mon Sep 17 00:00:00 2001 From: Your Name Date: Tue, 21 Jan 2025 11:50:45 -0600 Subject: [PATCH] Sin correo --- export/supervisor_excel.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/export/supervisor_excel.php b/export/supervisor_excel.php index e7f1c9f..7c7bf24 100644 --- a/export/supervisor_excel.php +++ b/export/supervisor_excel.php @@ -25,7 +25,7 @@ $data = $db->query( auditoria->>'registro_fecha_ideal' as registro_fecha_ideal, auditoria->>'profesor_clave' as profesor_clave, auditoria->>'profesor_nombre' as profesor_nombre, - auditoria->>'profesor_correo' as profesor_correo, + NULLIF(auditoria->>'profesor_correo', '') as profesor_correo, auditoria->>'facultad' as facultad, auditoria->>'materia' as materia, auditoria->>'carrera' as carrera, @@ -197,6 +197,7 @@ function getFormattedValue($key, $registro) 'salon_array' => $registro[$key], 'justificacion', 'comentario' => $registro[$key] ?? "Sin registro", + 'profesor_correo' => $registro[$key] ?? "Sin correo", default => $registro[$key] }; } @@ -220,7 +221,7 @@ foreach ($data as $index => $registro) { $sheet->setCellValue($cellLocation, $value); - if ($value == "Sin registro") { + if (in_array($value, ["Sin registro", "Sin asignar", "Sin correo"])) { $sheet->getStyle($cellLocation)->applyFromArray(['font' => ['color' => ['argb' => 'ea0029']]]); } });