Fixes and improvements to main.php, test.php, c_login.php, reposicion_profesor_materias.php, puesto.php, action_usuarios_insert.php, periodos.php, reposicion_autoriza.php, profesor_faltas.php
This commit is contained in:
@@ -22,7 +22,11 @@ $user = unserialize($_SESSION['user']);
|
||||
$id = filter_input(INPUT_POST, "id", FILTER_SANITIZE_NUMBER_INT);//limpia texto
|
||||
|
||||
try{
|
||||
$rs = $db->query('SELECT * FROM fs_materiasprofesor(:id, :jefe)', [':id' => $id, ':jefe'=>$user->user["id"]] );
|
||||
if($user->jefe_carrera){
|
||||
$rs = $db->query('SELECT * FROM fs_materiasprofesor(:id, :jefe)', [':id' => $id, ':jefe'=>$user->user["id"]] );
|
||||
}else{
|
||||
$rs = $db->query('SELECT * FROM fs_materiasprofesor(:id, NULL)', [':id' => $id] );
|
||||
}
|
||||
|
||||
}catch(Exception $e){
|
||||
$return["error"] = "Ocurrió un error al leer los datos de las materias.";
|
||||
|
||||
Reference in New Issue
Block a user