added Parking feauture to infocenter

This commit is contained in:
alex
2018-05-16 20:00:19 +02:00
parent 24d4c316e4
commit 6a67183738
8 changed files with 400 additions and 33 deletions
@@ -12,4 +12,21 @@ class Studienjahr_model extends DB_Model
$this->pk = 'studienjahr_kurzbz';
$this->hasSequence = false;
}
/**
* Gets current Studienjahr, as determined by its start and enddate
* @return array|null
*/
public function getCurrStudienjahr()
{
$query = 'SELECT *
FROM public.tbl_studienjahr
JOIN public.tbl_studiensemester using(studienjahr_kurzbz)
WHERE start <= now()
AND ende >= now()
ORDER by start DESC
LIMIT 1';
return $this->execQuery($query);
}
}