Add new files and make code improvements
This commit is contained in:
@@ -68,13 +68,12 @@ if ($user->admin) { //si es admin su facultad es null (todas las facultades)
|
||||
}
|
||||
}
|
||||
$fs_profesores = $db->query(
|
||||
"SELECT DISTINCT PROFESOR.*, FACULTAD.* FROM profesor
|
||||
"SELECT DISTINCT PROFESOR.*, horario_view.facultad as facultad_nombre, horario_view.facultad_id FROM profesor
|
||||
JOIN horario_profesor USING (profesor_id)
|
||||
JOIN horario USING (horario_id)
|
||||
JOIN facultad ON horario.facultad_id = facultad.facultad_id
|
||||
JOIN horario_view USING (horario_id)
|
||||
WHERE
|
||||
profesor_nombre ILIKE COALESCE(:nombre, profesor_nombre) AND profesor_clave ILIKE COALESCE(:clave, profesor_clave)
|
||||
AND facultad.facultad_id = COALESCE(:facultad, facultad.facultad_id)
|
||||
AND facultad_id = COALESCE(:facultad, facultad_id)
|
||||
LIMIT :maxc",
|
||||
array(
|
||||
":nombre" => "%$desc%",
|
||||
|
||||
Reference in New Issue
Block a user