mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-19 16:02:15 +00:00
add endpoint for fetching all degree programes
This commit is contained in:
@@ -26,7 +26,8 @@ class Studgang extends FHCAPI_Controller
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct([
|
||||
'getStudiengangInfo'=> self::PERM_LOGGED,
|
||||
'getAllStudiengange'=> self::PERM_LOGGED,
|
||||
'getAllDegreePrograms'=> self::PERM_LOGGED,
|
||||
|
||||
]);
|
||||
|
||||
@@ -43,6 +44,14 @@ class Studgang extends FHCAPI_Controller
|
||||
//------------------------------------------------------------------------------------------------------------------
|
||||
// Public methods
|
||||
|
||||
public function getAllDegreePrograms()
|
||||
{
|
||||
$this->load->model('organisation/Studiengang_model', "StudiengangModel");
|
||||
$class_schedule_res = $this->StudiengangModel->load();
|
||||
$class_schedule_res = $this->getDataOrTerminateWithError($class_schedule_res);
|
||||
$this->terminateWithSuccess($class_schedule_res);
|
||||
}
|
||||
|
||||
public function getStudiengangInfo(){
|
||||
$isMitarbeiter = $this->MitarbeiterModel->isMitarbeiter(getAuthUID());
|
||||
$isMitarbeiter = $this->getDataOrTerminateWithError($isMitarbeiter);
|
||||
|
||||
Reference in New Issue
Block a user