mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-18 23:42:17 +00:00
Changed: If LV has no lectors, show empty field instead of error message
Signed-off-by: cris-technikum <hainberg@technikum-wien.at>
This commit is contained in:
@@ -535,6 +535,8 @@ class approveAnrechnungDetail extends Auth_Controller
|
||||
* Anyway this function will receive a unique array to avoid sending more mails to one and the same lector.
|
||||
* **/
|
||||
$lector_arr = $this->_getLectors($anrechnung_arr);
|
||||
|
||||
|
||||
|
||||
// Send mail to lectors
|
||||
foreach ($lector_arr as $lector)
|
||||
|
||||
@@ -61,12 +61,14 @@ class AnrechnungLib
|
||||
}
|
||||
|
||||
// Get lectors of lehrveranstaltung
|
||||
$antrag_data->lektoren = array();
|
||||
if (!$lv_lektoren = getData($this->ci->LehrveranstaltungModel->getLecturersByLv($studiensemester_kurzbz, $lv_id)))
|
||||
$result = $this->ci->LehrveranstaltungModel->getLecturersByLv($studiensemester_kurzbz, $lv_id);
|
||||
if (isError($result))
|
||||
{
|
||||
show_error('Failed loading course lectors.');
|
||||
}
|
||||
|
||||
|
||||
$lv_lektoren_arr = hasData($result) ? getData($result) : array();
|
||||
|
||||
// Set the given studiensemester
|
||||
$antrag_data->lv_id = $lv_id;
|
||||
$antrag_data->lv_bezeichnung = $lv->bezeichnung;
|
||||
@@ -76,7 +78,7 @@ class AnrechnungLib
|
||||
$antrag_data->nachname = $person->nachname;
|
||||
$antrag_data->matrikelnr = $student->matrikelnr;
|
||||
$antrag_data->stg_bezeichnung = $studiengang->bezeichnung;
|
||||
$antrag_data->lektoren = $lv_lektoren;
|
||||
$antrag_data->lektoren = $lv_lektoren_arr;
|
||||
|
||||
return $antrag_data;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user