示例#1
0
 public function listarDisponiveisProfessorSerie($serie, $idProfessor)
 {
     $sql = "SELECT * FROM periodo p\n                        JOIN grupo g ON g.grp_periodo = p.prd_id\n                        WHERE g.grp_professor = " . $idProfessor . " AND g.grp_serie = " . $serie;
     $result = $this->retrieve($sql);
     $lista = array();
     while ($qr = mysqli_fetch_array($result)) {
         $per = new Periodo();
         $per->setPrd_id($qr["prd_id"]);
         $per->setPrd_periodo($qr["prd_periodo"]);
         array_push($lista, $per);
     }
     return $lista;
 }