diff --git a/application/core/Auth_Controller.php b/application/core/Auth_Controller.php index 1427a318d..5d03091f0 100644 --- a/application/core/Auth_Controller.php +++ b/application/core/Auth_Controller.php @@ -14,9 +14,6 @@ class Auth_Controller extends FHC_Controller // Loads authentication library and starts authentication $this->load->library('AuthLib'); - // Loads authentication helper - $this->load->helper('hlp_authentication'); - // Checks if the caller is allowed to access to this content $this->_isAllowed($requiredPermissions); } diff --git a/application/helpers/hlp_authentication_helper.php b/application/helpers/hlp_authentication_helper.php index 1c2e3603d..740823ff9 100644 --- a/application/helpers/hlp_authentication_helper.php +++ b/application/helpers/hlp_authentication_helper.php @@ -2,20 +2,35 @@ if (!defined('BASEPATH')) exit('No direct script access allowed'); -// ------------------------------------------------------------------------ +// ----------------------------------------------------------------------------------------------------- // Functions needed to manage the user authentication -// ------------------------------------------------------------------------ +// NOTE: the following functions do NOT prompt a login page if the user is NOT logged in +// ----------------------------------------------------------------------------------------------------- /** - * It calls the AuthLib, if the user is NOT logged then the login page is shown + * If the user is NOT logged then a null value is returned. + * If the user is alredy logged, then it is possible to access to the authentication object + * that contains the person_id of the logged user + * NOTE: if a user is logged then a person_id is always present! + */ +function getAuthPersonId() +{ + $ci =& get_instance(); // get CI instance + + return isLogged() ? ($ci->authlib->getAuthObj())->{AuthLib::AO_PERSON_ID} : null; +} + + +/** + * If the user is NOT logged then a null value is returned. * If the user is alredy logged, then it is possible to access to the authentication object * that contains the username of the logged user - * - * @return string or null + * NOTE: if the user is logged with a "foreign" method (ex. Bewerbungstool), + * then it is possible that the username is null! */ function getAuthUID() { $ci =& get_instance(); // get CI instance - return ($ci->authlib->getAuthObj())->{AuthLib::AO_USERNAME}; + return isLogged() ? ($ci->authlib->getAuthObj())->{AuthLib::AO_USERNAME} : null; } diff --git a/application/helpers/hlp_common_helper.php b/application/helpers/hlp_common_helper.php index bc09cd32c..bb8b1b8e4 100644 --- a/application/helpers/hlp_common_helper.php +++ b/application/helpers/hlp_common_helper.php @@ -224,3 +224,19 @@ function isDateWorkingDay($date, $days = null) return true; } } + +/** + * Checks if the current user is logged by checking that the AuthLib is loaded and + * it is present the authentication object in session + * NOTE: it is placed here instead of being placed in the helper hlp_authentication_helper + * because hlp_authentication_helper is loaded after the authentication. + * It is very useful to use this function even in those parts of the code that are accessible + * even when a user is NOT authenticated!!! + * If and only if this function returns true, then all the functions present in hlp_authentication_helper can be used! + */ +function isLogged() +{ + $ci =& get_instance(); // get CI instance + + return isset($ci->authlib) && $ci->authlib->getAuthObj() != null; +} diff --git a/application/libraries/AuthLib.php b/application/libraries/AuthLib.php index deebcb3ee..bb2c6ce9b 100644 --- a/application/libraries/AuthLib.php +++ b/application/libraries/AuthLib.php @@ -30,7 +30,6 @@ class AuthLib /** * Construct * - * * @param bool $authenticate If the authentication must be performed. */ public function __construct($authenticate = true) @@ -483,6 +482,8 @@ class AuthLib /** * Stores the authentication object into the authentication session + * Everything was fine, the user at this point is authenticated, it is possible to store the authentication object + * in the user session */ private function _storeSessionAuthObj($authObj) { @@ -552,7 +553,12 @@ class AuthLib $this->_showError(getData($auth)); // display a generic error message and logs the occurred error } } - // else the user is already logged, then continue with the execution + // else the user is already logged, then loads authentication helper and continue with the execution + // NOTE: it is needed only here because: + // - it is called when a user is already logged in + // - it is called after login the user + // - it is NOT called in case of fatal error or wrong authentication + $this->_ci->load->helper('hlp_authentication'); } /** diff --git a/application/libraries/FiltersLib.php b/application/libraries/FiltersLib.php index 9d0d67584..6346150d8 100644 --- a/application/libraries/FiltersLib.php +++ b/application/libraries/FiltersLib.php @@ -108,9 +108,6 @@ class FiltersLib { $this->_ci =& get_instance(); // get code igniter instance - // Loads authentication helper - $this->_ci->load->helper('hlp_authentication'); // NOTE: needed to load custom filters do not remove! - $this->_filterUniqueId = $this->_getFilterUniqueId($params); // sets the id for the related filter widget } @@ -185,11 +182,8 @@ class FiltersLib { // Loads the needed models $this->_ci->load->model('system/Filters_model', 'FiltersModel'); - $this->_ci->load->model('person/Benutzer_model', 'BenutzerModel'); // to get the default custom filter - $this->_ci->FiltersModel->resetQuery(); // reset any previous built query - $this->_ci->FiltersModel->addJoin('public.tbl_benutzer', 'person_id', 'LEFT'); // left join with benutzer table $this->_ci->FiltersModel->addSelect('system.tbl_filters.*'); // select only from table filters $this->_ci->FiltersModel->addOrder('sort', 'ASC'); // sort on column sort $this->_ci->FiltersModel->addLimit(1); // if more than one filter is set as default only one will be retrieved @@ -223,7 +217,7 @@ class FiltersLib $whereParameters = array( 'app' => $app, 'dataset_name' => $datasetName, - 'uid' => getAuthUID(), + 'person_id' => getAuthPersonId(), 'default_filter' => true ); @@ -260,10 +254,10 @@ class FiltersLib $jsonEncodedFilter = null; // If the definition contains data and they are valid - if (hasData($definition) && isset($definition->retval[0]->filter) && trim($definition->retval[0]->filter) != '') + if (hasData($definition) && isset(getData($definition)[0]->filter) && trim(getData($definition)[0]->filter) != '') { // Get the json definition of the filter - $tmpJsonEncodedFilter = json_decode($definition->retval[0]->filter); + $tmpJsonEncodedFilter = json_decode(getData($definition)[0]->filter); // Checks required filter's properies if (isset($tmpJsonEncodedFilter->name) @@ -585,87 +579,76 @@ class FiltersLib $saveCustomFilter = false; // by default returns a failure // Checks parameter customFilterDescription if not valid stop the execution - if (isEmptyString($customFilterDescription)) - { - return $saveCustomFilter; - } + if (isEmptyString($customFilterDescription)) return $saveCustomFilter; $this->_ci->load->model('system/Filters_model', 'FiltersModel'); // to load the filter definitions - $this->_ci->load->model('person/Benutzer_model', 'BenutzerModel'); // to get the person_id of the authenticated user - $this->_ci->FiltersModel->resetQuery(); // reset any previous built query - $this->_ci->BenutzerModel->resetQuery(); // reset any previous built query - // Loads data for the authenticated user - $authBenutzer = $this->_ci->BenutzerModel->loadWhere(array('uid' => getAuthUID())); - if (hasData($authBenutzer)) // if data are found + // person_id of the authenticated user + $authPersonId = getAuthPersonId(); + // Postgres array for the description + $descPGArray = str_replace('%desc%', $customFilterDescription, '{"%desc%", "%desc%", "%desc%", "%desc%"}'); + + // Loads the definition to check if is already present in the DB + $definition = $this->_ci->FiltersModel->loadWhere(array( + 'app' => $this->getSessionElement(self::APP_PARAMETER), + 'dataset_name' => $this->getSessionElement(self::DATASET_NAME_PARAMETER), + 'description' => $descPGArray, + 'person_id' => $authPersonId + )); + + // New definition to be json encoded + $jsonDeifinition = new stdClass(); + $jsonDeifinition->name = $customFilterDescription; // name of the filter + + // Generates the "column" property + $jsonDeifinition->columns = array(); + $selectedFields = $this->getSessionElement(self::SESSION_SELECTED_FIELDS); // retrieved the selected fields + for ($i = 0; $i < count($selectedFields); $i++) { - // person_id of the authenticated user - $authPersonId = $authBenutzer->retval[0]->person_id; - // Postgres array for the description - $descPGArray = str_replace('%desc%', $customFilterDescription, '{"%desc%", "%desc%", "%desc%", "%desc%"}'); + // Each element is an object with a property called "name" + $jsonDeifinition->columns[$i] = new stdClass(); + $jsonDeifinition->columns[$i]->name = $selectedFields[$i]; + } - // Loads the definition to check if is already present in the DB - $definition = $this->_ci->FiltersModel->loadWhere(array( - 'app' => $this->getSessionElement(self::APP_PARAMETER), - 'dataset_name' => $this->getSessionElement(self::DATASET_NAME_PARAMETER), - 'description' => $descPGArray, - 'person_id' => $authPersonId - )); + // List of applied filters + $jsonDeifinition->filters = $this->getSessionElement(self::SESSION_FILTERS); - // New definition to be json encoded - $jsonDeifinition = new stdClass(); - $jsonDeifinition->name = $customFilterDescription; // name of the filter + // If it is already present + if (hasData($definition)) + { + // update it + $this->_ci->FiltersModel->update( + array( + 'app' => $this->getSessionElement(self::APP_PARAMETER), + 'dataset_name' => $this->getSessionElement(self::DATASET_NAME_PARAMETER), + 'description' => $descPGArray, + 'person_id' => $authPersonId + ), + array( + 'filter' => json_encode($jsonDeifinition) + ) + ); - // Generates the "column" property - $jsonDeifinition->columns = array(); - $selectedFields = $this->getSessionElement(self::SESSION_SELECTED_FIELDS); // retrieved the selected fields - for ($i = 0; $i < count($selectedFields); $i++) - { - // Each element is an object with a property called "name" - $jsonDeifinition->columns[$i] = new stdClass(); - $jsonDeifinition->columns[$i]->name = $selectedFields[$i]; - } + $saveCustomFilter = true; + } + else // otherwise insert a new one + { + $this->_ci->FiltersModel->insert( + array( + 'app' => $this->getSessionElement(self::APP_PARAMETER), + 'dataset_name' => $this->getSessionElement(self::DATASET_NAME_PARAMETER), + 'filter_kurzbz' => uniqid($authPersonId, true), + 'description' => $descPGArray, + 'person_id' => $authPersonId, + 'sort' => null, + 'default_filter' => false, + 'filter' => json_encode($jsonDeifinition), + 'oe_kurzbz' => null + ) + ); - // List of applied filters - $jsonDeifinition->filters = $this->getSessionElement(self::SESSION_FILTERS); - - // If it is already present - if (hasData($definition)) - { - // update it - $this->_ci->FiltersModel->update( - array( - 'app' => $this->getSessionElement(self::APP_PARAMETER), - 'dataset_name' => $this->getSessionElement(self::DATASET_NAME_PARAMETER), - 'description' => $descPGArray, - 'person_id' => $authPersonId - ), - array( - 'filter' => json_encode($jsonDeifinition) - ) - ); - - $saveCustomFilter = true; - } - else // otherwise insert a new one - { - $this->_ci->FiltersModel->insert( - array( - 'app' => $this->getSessionElement(self::APP_PARAMETER), - 'dataset_name' => $this->getSessionElement(self::DATASET_NAME_PARAMETER), - 'filter_kurzbz' => uniqid($authPersonId, true), - 'description' => $descPGArray, - 'person_id' => $authPersonId, - 'sort' => null, - 'default_filter' => false, - 'filter' => json_encode($jsonDeifinition), - 'oe_kurzbz' => null - ) - ); - - $saveCustomFilter = true; - } + $saveCustomFilter = true; } return $saveCustomFilter; @@ -721,7 +704,7 @@ class FiltersLib $childrenPersonalArray = array(); // contains all the children elements in menu enty for personal filters // Loops through loaded filters - foreach ($filters->retval as $filter) + foreach (getData($filters) as $filter) { // Generate a menu entry $menuEntry = $this->_ci->navigationlib->oneLevel( diff --git a/application/views/person/gradelist/gradelist.php b/application/views/person/gradelist/gradelist.php index dbdcf66f8..9ae485c02 100644 --- a/application/views/person/gradelist/gradelist.php +++ b/application/views/person/gradelist/gradelist.php @@ -37,7 +37,8 @@ p->t('lehre', 'gewichteternotendurchschnitt'); ?> :
- p->t('lehre', 'ects'); ?>: + p->t('lehre', 'ects'); ?> + :

, - * Andreas Oesterreicher - * Rudolf Hangl < rudolf.hangl@technikum-wien.at > - * Gerald Simane-Sequens < gerald.simane-sequens@technikum-wien.at > - */ -/* - * Erstellt eine Liste mit den Noten des eingeloggten Studenten - * das betreffende Studiensemester kann ausgewaehlt werden - */ -require_once('../../../config/cis.config.inc.php'); -require_once('../../../config/global.config.inc.php'); -require_once('../../../include/functions.inc.php'); -require_once('../../../include/studiensemester.class.php'); -require_once('../../../include/datum.class.php'); -require_once('../../../include/note.class.php'); -require_once('../../../include/phrasen.class.php'); -require_once('../../../include/studiengang.class.php'); -require_once('../../../include/studienordnung.class.php'); -require_once('../../../include/lehrveranstaltung.class.php'); -require_once('../../../include/pruefung.class.php'); -require_once('../../../include/benutzerberechtigung.class.php'); -require_once('../../../include/prestudent.class.php'); - -$sprache = getSprache(); -$p = new phrasen($sprache); - -if (! $db = new basis_db()) - die($p->t('global/fehlerBeimOeffnenDerDatenbankverbindung')); - -if (isset($_GET['stsem'])) - $stsem = $_GET['stsem']; -else - $stsem = ''; - -echo ' - - - - - - - - - - - - ' . $p->t('tools/leistungsbeurteilung') . ' - - - - - -

' . $p->t('tools/leistungsbeurteilung') . '

'; - -$user = get_uid(); - -if (isset($_GET['uid'])) -{ - // Administratoren duerfen die UID als Parameter uebergeben um die Notenliste - // von anderen Personen anzuzeigen - - $rechte = new benutzerberechtigung(); - $rechte->getBerechtigungen($user); - if ($rechte->isBerechtigt('admin')) - { - $user = $_GET['uid']; - $getParam = "&uid=" . $user; - } - else - $getParam = ""; -} -else - $getParam = ''; - -$datum_obj = new datum(); - -$error = ''; - -if (! check_student($user)) -{ - $error .= $p->t('tools/mussAlsStudentEingeloggtSein'); -} -else -{ - $qry = "SELECT vw_student.vorname, vw_student.nachname, vw_student.prestudent_id, tbl_studiengang.studiengang_kz - FROM public.tbl_studiengang JOIN campus.vw_student USING (studiengang_kz) - WHERE campus.vw_student.uid = " . $db->db_add_param($user) . ";"; - - if (! $result = $db->db_query($qry)) - die($p->t('tools/studentWurdeNichtGefunden')); - else - { - $row = $db->db_fetch_object($result); - - $vorname = $row->vorname; - $nachname = $row->nachname; - $prestudent_id = $row->prestudent_id; - $stg_obj = new studiengang(); - $stg_obj->load($row->studiengang_kz); - $stg_name = $stg_obj->bezeichnung_arr[$sprache]; - $prestudent_id = $row->prestudent_id; - $prestudent = new prestudent($prestudent_id); - if ($prestudent->getLastStatus($prestudent_id)) - { - $studienplan_id = $prestudent->studienplan_id; - $studienordnung = new studienordnung(); - if ($studienordnung->getStudienordnungFromStudienplan($studienplan_id)) - { - $studiengangbezeichnung_sto = $sprache === 'English' ? $studienordnung->__get('studiengangbezeichnung_englisch') : $studienordnung->__get('studiengangbezeichnung'); - } - } - - $studiengang_bezeichnung = empty($studiengangbezeichnung_sto) ? $stg_name : $studiengangbezeichnung_sto; - } - - $notenarr = array(); - $note = new note(); - $note->getAll(); - foreach ($note->result as $row) - { - $notenarr[$row->note]['bezeichnung'] = $row->bezeichnung; - $notenarr[$row->note]['notenwert'] = $row->notenwert; - } - - // Aktuelles Studiensemester ermitteln - - $stsem_obj = new studiensemester(); - if ($stsem == '') - $stsem = $stsem_obj->getaktorNext(); - - // Erstes und letztes Studiensemester mit Studenten-Status ermitteln - $prestudent = new prestudent(); - // Wenn Incoming, dann Incomingstatus laden, sonst Studentenstatus - $prestudent->getPrestudentRolle($prestudent_id, 'Incoming'); - if(count($prestudent->result) > 0) - { - $prestudent->getFirstStatus($prestudent_id, 'Incoming'); - $firstStudiensemester = $prestudent->studiensemester_kurzbz; - $prestudent->getLastStatus($prestudent_id, null, 'Incoming'); - $lastStudiensemester = $prestudent->studiensemester_kurzbz; - } - else - { - $prestudent->getFirstStatus($prestudent_id, 'Student'); - $firstStudiensemester = $prestudent->studiensemester_kurzbz; - $prestudent->getLastStatus($prestudent_id, null, 'Student'); - $lastStudiensemester = $prestudent->studiensemester_kurzbz; - } - - $stsem_obj->getStudiensemesterBetween($firstStudiensemester, $lastStudiensemester); - - echo "
"; - echo "".$p->t('global/name').": $vorname $nachname
"; - echo "".$p->t('global/studiengang').": $studiengang_bezeichnung
"; - echo "".$p->t('global/studiensemester')."
"; - - // echo "Datum: ".date('d.m.Y')."
"; - echo "
"; - if ($notenImAktuellenStSem == false) - { - $stsem = 'alle'; - } - // Lehrveranstaltungen und Noten holen - if ($stsem != "alle") - { - $sqlFilter = " AND tbl_zeugnisnote.studiensemester_kurzbz = " . $db->db_add_param($stsem) . " - AND (tbl_lvgesamtnote.studiensemester_kurzbz = " . $db->db_add_param($stsem) . " OR tbl_lvgesamtnote.studiensemester_kurzbz is null) "; - } - else - $sqlFilter = ""; - - $qry = "SELECT - tbl_lehrveranstaltung.lehrveranstaltung_id, tbl_zeugnisnote.note, tbl_zeugnisnote.punkte, - tbl_lvgesamtnote.note as lvnote, tbl_lvgesamtnote.punkte as lvpunkte, - tbl_zeugnisnote.benotungsdatum, tbl_lvgesamtnote.freigabedatum, - tbl_lvgesamtnote.benotungsdatum as lvbenotungsdatum, - tbl_zeugnisnote.studiensemester_kurzbz AS studiensemester_zeugnis, tbl_lvgesamtnote.studiensemester_kurzbz AS studiensemester_lvnote, - tbl_lehrveranstaltung.zeugnis, tbl_lehrveranstaltung.ects - FROM - lehre.tbl_lehrveranstaltung, lehre.tbl_zeugnisnote - LEFT OUTER JOIN - campus.tbl_lvgesamtnote - USING (lehrveranstaltung_id, student_uid, studiensemester_kurzbz) - WHERE - tbl_zeugnisnote.student_uid = " . $db->db_add_param($user) . $sqlFilter . " - AND tbl_lehrveranstaltung.lehrveranstaltung_id = tbl_zeugnisnote.lehrveranstaltung_id - ORDER BY bezeichnung"; - - if ($result = $db->db_query($qry)) - { - // Tabelle anzeigen - $tbl = ""; - $tblHead = " - - "; - if ($stsem == "alle") - $tblHead .= ""; - - $tblHead .= ""; - if (defined('CIS_GESAMTNOTE_PUNKTE') && CIS_GESAMTNOTE_PUNKTE) - $tblHead .= ""; - - $tblHead .= " "; - if (defined('CIS_GESAMTNOTE_PUNKTE') && CIS_GESAMTNOTE_PUNKTE) - $tblHead .= ""; - - $tblHead .= " - - - - "; - $tblBody = ""; - $i = 0; - $legende = false; - $notenSummenArray = array(); - while ($row = $db->db_fetch_object($result)) - { - $lv_obj = new lehrveranstaltung(); - $lv_obj->load($row->lehrveranstaltung_id); - - $i ++; - $tblBody .= ""; - if ($stsem == "alle") - $tblBody .= ""; - - // LV Gesamtnote Punkte - if (defined('CIS_GESAMTNOTE_PUNKTE') && CIS_GESAMTNOTE_PUNKTE) - { - $lvpunkte = ($row->lvpunkte != '' ? (float) $row->lvpunkte : ''); - $tblBody .= ""; - } - - if ($row->note != $row->lvnote && $row->lvnote != NULL) - { - $markier = " style='background-color: #FFD999;'"; - $legende = true; - } - else - $markier = ""; - $tblBody .= ""; - - if (defined('CIS_GESAMTNOTE_PUNKTE') && CIS_GESAMTNOTE_PUNKTE) - { - $punkte = ($row->punkte != '' ? ((float) $row->punkte) : ''); - $tblBody .= ""; - } - - $tblBody .= ''; - - $pruefung = new pruefung(); - $pruefung->getPruefungen($user, null, $row->lehrveranstaltung_id, $stsem); - - if (count($pruefung->result) > 0) - { - $tblBody .= ''; - } - else - $tblBody .= ''; - - $tblBody .= ""; - } - // Durchschnitt und gewichteten Durchschnitt berechnen - $notenSumme = 0; - $notenSummeGewichtet = 0; - $ectsSumme = 0; - $anzahlLv = 0; - foreach ($notenSummenArray AS $key => $value) - { - if ($value['notenwert'] != '') - { - $anzahlLv++; - $notenSumme += $value['notenwert']; - $ectsSumme += $value['ects']; - $notenSummeGewichtet += $value['notenwert'] * $value['ects']; - } - } - - $tblBody .= ""; - $tblFoot = ""; - - if ($anzahlLv != 0) - $notenDurchschnitt = round($notenSumme / $anzahlLv, 2); - else - $notenDurchschnitt = 0; - - if ($ectsSumme != 0) - $notenDurchschnittGewichtet = round($notenSummeGewichtet / $ectsSumme, 2); - else - $notenDurchschnittGewichtet = 0; - - $tblFoot .= ''; - $tblFoot .= ''; - $tblFoot .= ''; - $tblFoot .= ''; - $tblFoot .= ""; - - $tblFoot .= ''; - $tblFoot .= ''; - $tblFoot .= ''; - $tblFoot .= ''; - - $tblFoot .= ""; - - $tblFoot .= ""; - - $tbl .= $tblHead.$tblFoot.$tblBody; - - $tbl .= "
" . $p->t('global/lehrveranstaltung') . "" . $p->t('global/studiensemester') . "" . $p->t('benotungstool/lvNote') . "" . $p->t('benotungstool/punkte') . "" . $p->t('benotungstool/zeugnisnote') . "" . $p->t('benotungstool/punkte') . "" . $p->t('tools/benotungsdatumDerZeugnisnote') . "" . $p->t('benotungstool/pruefung') . "
" . $lv_obj->bezeichnung_arr[$sprache] . ($lv_obj->lehrform_kurzbz != "" && $lv_obj->lehrform_kurzbz != " - " ? " (" . $lv_obj->lehrform_kurzbz . ")" : "") . "" . ($row->studiensemester_zeugnis != '' ? $row->studiensemester_zeugnis : $row->studiensemester_lvnote) . ""; - - $tblBody .= ""; - - // Nur freigegebene Noten anzeigen - if ($row->freigabedatum >= $row->lvbenotungsdatum) - { - if (isset($notenarr[$row->lvnote])) - $tblBody .= $notenarr[$row->lvnote]['bezeichnung']; - else - $tblBody .= $row->lvnote; - - // Nur Noten, die aufs Zeugnis gedruckt werden für Durchschnittsberechnung addieren - if ($row->zeugnis == true) - { - $notenSummenArray[$row->lehrveranstaltung_id]['notenwert'] = (isset($notenarr[$row->note]['notenwert']) ? $notenarr[$row->note]['notenwert'] : ''); - $notenSummenArray[$row->lehrveranstaltung_id]['ects'] = $row->ects; - } - } - $tblBody .= "" . $lvpunkte . ""; - - if (isset($notenarr[$row->note])) - $tblBody .= $notenarr[$row->note]['bezeichnung']; - else - $tblBody .= $row->note; - - $tblBody .= "" . $punkte . "' . $datum_obj->formatDatum($row->benotungsdatum, 'Y-m-d') . ''; - foreach ($pruefung->result as $row) - { - if (isset($notenarr[$row->note])) - $note = $notenarr[$row->note]['bezeichnung']; - else - $note = $row->note; - - if ($row->punkte != '') - $punkte = ' (' . (float) $row->punkte . ')'; - else - $punkte = ''; - - $tblBody .= $row->pruefungstyp_beschreibung . ' ' . $datum_obj->formatDatum($row->datum, 'd.m.Y') . ' ' . $note . $punkte . '
'; - } - $tblBody .= '
' . $p->t("tools/notendurchschnittDerZeugnisnote") . ''.$notenDurchschnitt.'
' . $p->t("tools/gewichteterNotendurchschnittDerZeugnisnote") . ''.$notenDurchschnittGewichtet.'
"; - $tbl .= ""; - if ($legende) - { - $tbl .= ""; - } - $tbl .= "
*" . $p->t('tools/legendeNotendurchschnitt') . "
**" . $p->t('tools/legendeGewichteterNotendurchschnitt') . "
" . $p->t('tools/hinweistextMarkierung') . "
"; - if ($i == 0) - echo $p->t('tools/nochKeineBeurteilungEingetragen'); - else - { - $tbl .= "


"; - echo $tbl; - } - } - else - { - $error .= $p->t('tools/fehlerBeimAuslesenDerNoten'); - } -} -echo $error; -echo ' -'; -?> +, + * Andreas Oesterreicher + * Rudolf Hangl < rudolf.hangl@technikum-wien.at > + * Gerald Simane-Sequens < gerald.simane-sequens@technikum-wien.at > + */ +/* + * Erstellt eine Liste mit den Noten des eingeloggten Studenten + * das betreffende Studiensemester kann ausgewaehlt werden + */ +require_once('../../../config/cis.config.inc.php'); +require_once('../../../config/global.config.inc.php'); +require_once('../../../include/functions.inc.php'); +require_once('../../../include/studiensemester.class.php'); +require_once('../../../include/datum.class.php'); +require_once('../../../include/note.class.php'); +require_once('../../../include/phrasen.class.php'); +require_once('../../../include/studiengang.class.php'); +require_once('../../../include/studienordnung.class.php'); +require_once('../../../include/lehrveranstaltung.class.php'); +require_once('../../../include/pruefung.class.php'); +require_once('../../../include/benutzerberechtigung.class.php'); +require_once('../../../include/prestudent.class.php'); + +$sprache = getSprache(); +$p = new phrasen($sprache); + +if (! $db = new basis_db()) + die($p->t('global/fehlerBeimOeffnenDerDatenbankverbindung')); + +if (isset($_GET['stsem'])) + $stsem = $_GET['stsem']; +else + $stsem = ''; + +echo ' + + + + + + + + + + + + ' . $p->t('tools/leistungsbeurteilung') . ' + + + + + +

' . $p->t('tools/leistungsbeurteilung') . '

'; + +$user = get_uid(); + +if (isset($_GET['uid'])) +{ + // Administratoren duerfen die UID als Parameter uebergeben um die Notenliste + // von anderen Personen anzuzeigen + + $rechte = new benutzerberechtigung(); + $rechte->getBerechtigungen($user); + if ($rechte->isBerechtigt('admin')) + { + $user = $_GET['uid']; + $getParam = "&uid=" . $user; + } + else + $getParam = ""; +} +else + $getParam = ''; + +$datum_obj = new datum(); + +$error = ''; + +if (! check_student($user)) +{ + $error .= $p->t('tools/mussAlsStudentEingeloggtSein'); +} +else +{ + $qry = "SELECT vw_student.vorname, vw_student.nachname, vw_student.prestudent_id, tbl_studiengang.studiengang_kz + FROM public.tbl_studiengang JOIN campus.vw_student USING (studiengang_kz) + WHERE campus.vw_student.uid = " . $db->db_add_param($user) . ";"; + + if (! $result = $db->db_query($qry)) + die($p->t('tools/studentWurdeNichtGefunden')); + else + { + $row = $db->db_fetch_object($result); + + $vorname = $row->vorname; + $nachname = $row->nachname; + $prestudent_id = $row->prestudent_id; + $stg_obj = new studiengang(); + $stg_obj->load($row->studiengang_kz); + $stg_name = $stg_obj->bezeichnung_arr[$sprache]; + $prestudent_id = $row->prestudent_id; + $prestudent = new prestudent($prestudent_id); + if ($prestudent->getLastStatus($prestudent_id)) + { + $studienplan_id = $prestudent->studienplan_id; + $studienordnung = new studienordnung(); + if ($studienordnung->getStudienordnungFromStudienplan($studienplan_id)) + { + $studiengangbezeichnung_sto = $sprache === 'English' ? $studienordnung->__get('studiengangbezeichnung_englisch') : $studienordnung->__get('studiengangbezeichnung'); + } + } + + $studiengang_bezeichnung = empty($studiengangbezeichnung_sto) ? $stg_name : $studiengangbezeichnung_sto; + } + + $notenarr = array(); + $note = new note(); + $note->getAll(); + foreach ($note->result as $row) + { + $notenarr[$row->note]['bezeichnung'] = $row->bezeichnung; + $notenarr[$row->note]['notenwert'] = $row->notenwert; + } + + // Aktuelles Studiensemester ermitteln + + $stsem_obj = new studiensemester(); + if ($stsem == '') + $stsem = $stsem_obj->getaktorNext(); + + // Erstes und letztes Studiensemester mit Studenten-Status ermitteln + $prestudent = new prestudent(); + // Wenn Incoming, dann Incomingstatus laden, sonst Studentenstatus + $prestudent->getPrestudentRolle($prestudent_id, 'Incoming'); + if(count($prestudent->result) > 0) + { + $prestudent->getFirstStatus($prestudent_id, 'Incoming'); + $firstStudiensemester = $prestudent->studiensemester_kurzbz; + $prestudent->getLastStatus($prestudent_id, null, 'Incoming'); + $lastStudiensemester = $prestudent->studiensemester_kurzbz; + } + else + { + $prestudent->getFirstStatus($prestudent_id, 'Student'); + $firstStudiensemester = $prestudent->studiensemester_kurzbz; + $prestudent->getLastStatus($prestudent_id, null, 'Student'); + $lastStudiensemester = $prestudent->studiensemester_kurzbz; + } + + $stsem_obj->getStudiensemesterBetween($firstStudiensemester, $lastStudiensemester); + + echo "
"; + echo "".$p->t('global/name').": $vorname $nachname
"; + echo "".$p->t('global/studiengang').": $studiengang_bezeichnung
"; + echo "".$p->t('global/studiensemester')."
"; + + // echo "Datum: ".date('d.m.Y')."
"; + echo "
"; + if ($notenImAktuellenStSem == false) + { + $stsem = 'alle'; + } + // Lehrveranstaltungen und Noten holen + if ($stsem != "alle") + { + $sqlFilter = " AND tbl_zeugnisnote.studiensemester_kurzbz = " . $db->db_add_param($stsem) . " + AND (tbl_lvgesamtnote.studiensemester_kurzbz = " . $db->db_add_param($stsem) . " OR tbl_lvgesamtnote.studiensemester_kurzbz is null) "; + } + else + $sqlFilter = ""; + + $qry = "SELECT + tbl_lehrveranstaltung.lehrveranstaltung_id, tbl_zeugnisnote.note, tbl_zeugnisnote.punkte, + tbl_lvgesamtnote.note as lvnote, tbl_lvgesamtnote.punkte as lvpunkte, + tbl_zeugnisnote.benotungsdatum, tbl_lvgesamtnote.freigabedatum, + tbl_lvgesamtnote.benotungsdatum as lvbenotungsdatum, + tbl_zeugnisnote.studiensemester_kurzbz AS studiensemester_zeugnis, tbl_lvgesamtnote.studiensemester_kurzbz AS studiensemester_lvnote, + tbl_lehrveranstaltung.zeugnis, tbl_lehrveranstaltung.ects + FROM + lehre.tbl_lehrveranstaltung, lehre.tbl_zeugnisnote + LEFT OUTER JOIN campus.tbl_lvgesamtnote USING (lehrveranstaltung_id, student_uid, studiensemester_kurzbz) + LEFT OUTER JOIN lehre.tbl_note on tbl_zeugnisnote.note = tbl_note.note + WHERE + tbl_zeugnisnote.student_uid = " . $db->db_add_param($user) . $sqlFilter . " + AND tbl_lehrveranstaltung.lehrveranstaltung_id = tbl_zeugnisnote.lehrveranstaltung_id"; + + if(defined('CIS_NOTENLISTE_OFFIZIELL_ANZEIGEN') && CIS_NOTENLISTE_OFFIZIELL_ANZEIGEN) + $qry .= " AND tbl_note.offiziell = true"; + + $qry .= " ORDER BY tbl_lehrveranstaltung.bezeichnung"; + + if ($result = $db->db_query($qry)) + { + // Tabelle anzeigen + $tbl = ""; + $tblHead = " + + "; + if ($stsem == "alle") + $tblHead .= ""; + + $tblHead .= ""; + if (defined('CIS_GESAMTNOTE_PUNKTE') && CIS_GESAMTNOTE_PUNKTE) + $tblHead .= ""; + + $tblHead .= " "; + if (defined('CIS_GESAMTNOTE_PUNKTE') && CIS_GESAMTNOTE_PUNKTE) + $tblHead .= ""; + + $tblHead .= " + + + + "; + $tblBody = ""; + $i = 0; + $legende = false; + $notenSummenArray = array(); + while ($row = $db->db_fetch_object($result)) + { + $lv_obj = new lehrveranstaltung(); + $lv_obj->load($row->lehrveranstaltung_id); + + $i ++; + $tblBody .= ""; + if ($stsem == "alle") + $tblBody .= ""; + + // LV Gesamtnote Punkte + if (defined('CIS_GESAMTNOTE_PUNKTE') && CIS_GESAMTNOTE_PUNKTE) + { + $lvpunkte = ($row->lvpunkte != '' ? (float) $row->lvpunkte : ''); + $tblBody .= ""; + } + + if ($row->note != $row->lvnote && $row->lvnote != NULL) + { + $markier = " style='background-color: #FFD999;'"; + $legende = true; + } + else + $markier = ""; + $tblBody .= ""; + + if (defined('CIS_GESAMTNOTE_PUNKTE') && CIS_GESAMTNOTE_PUNKTE) + { + $punkte = ($row->punkte != '' ? ((float) $row->punkte) : ''); + $tblBody .= ""; + } + + $tblBody .= ''; + + $pruefung = new pruefung(); + $pruefung->getPruefungen($user, null, $row->lehrveranstaltung_id, $stsem); + + if (count($pruefung->result) > 0) + { + $tblBody .= ''; + } + else + $tblBody .= ''; + + $tblBody .= ""; + } + // Durchschnitt und gewichteten Durchschnitt berechnen + $notenSumme = 0; + $notenSummeGewichtet = 0; + $ectsSumme = 0; + $anzahlLv = 0; + foreach ($notenSummenArray AS $key => $value) + { + if ($value['notenwert'] != '') + { + $anzahlLv++; + $notenSumme += $value['notenwert']; + $ectsSumme += $value['ects']; + $notenSummeGewichtet += $value['notenwert'] * $value['ects']; + } + } + + $tblBody .= ""; + $tblFoot = ""; + + if ($anzahlLv != 0) + $notenDurchschnitt = round($notenSumme / $anzahlLv, 2); + else + $notenDurchschnitt = 0; + + if ($ectsSumme != 0) + $notenDurchschnittGewichtet = round($notenSummeGewichtet / $ectsSumme, 2); + else + $notenDurchschnittGewichtet = 0; + + $tblFoot .= ''; + $tblFoot .= ''; + $tblFoot .= ''; + $tblFoot .= ''; + $tblFoot .= ""; + + $tblFoot .= ''; + $tblFoot .= ''; + $tblFoot .= ''; + $tblFoot .= ''; + + $tblFoot .= ""; + + $tblFoot .= ""; + + $tbl .= $tblHead.$tblFoot.$tblBody; + + $tbl .= "
" . $p->t('global/lehrveranstaltung') . "" . $p->t('global/studiensemester') . "" . $p->t('benotungstool/lvNote') . "" . $p->t('benotungstool/punkte') . "" . $p->t('benotungstool/zeugnisnote') . "" . $p->t('benotungstool/punkte') . "" . $p->t('tools/benotungsdatumDerZeugnisnote') . "" . $p->t('benotungstool/pruefung') . "
" . $lv_obj->bezeichnung_arr[$sprache] . ($lv_obj->lehrform_kurzbz != "" && $lv_obj->lehrform_kurzbz != " - " ? " (" . $lv_obj->lehrform_kurzbz . ")" : "") . "" . ($row->studiensemester_zeugnis != '' ? $row->studiensemester_zeugnis : $row->studiensemester_lvnote) . ""; + + $tblBody .= ""; + + // Nur freigegebene Noten anzeigen + if ($row->freigabedatum >= $row->lvbenotungsdatum) + { + if (isset($notenarr[$row->lvnote])) + $tblBody .= $notenarr[$row->lvnote]['bezeichnung']; + else + $tblBody .= $row->lvnote; + + // Nur Noten, die aufs Zeugnis gedruckt werden für Durchschnittsberechnung addieren + if ($row->zeugnis == true) + { + $notenSummenArray[$row->lehrveranstaltung_id]['notenwert'] = (isset($notenarr[$row->note]['notenwert']) ? $notenarr[$row->note]['notenwert'] : ''); + $notenSummenArray[$row->lehrveranstaltung_id]['ects'] = $row->ects; + } + } + $tblBody .= "" . $lvpunkte . ""; + + if (isset($notenarr[$row->note])) + $tblBody .= $notenarr[$row->note]['bezeichnung']; + else + $tblBody .= $row->note; + + $tblBody .= "" . $punkte . "' . $datum_obj->formatDatum($row->benotungsdatum, 'Y-m-d') . ''; + foreach ($pruefung->result as $row) + { + if (isset($notenarr[$row->note])) + $note = $notenarr[$row->note]['bezeichnung']; + else + $note = $row->note; + + if ($row->punkte != '') + $punkte = ' (' . (float) $row->punkte . ')'; + else + $punkte = ''; + + $tblBody .= $row->pruefungstyp_beschreibung . ' ' . $datum_obj->formatDatum($row->datum, 'd.m.Y') . ' ' . $note . $punkte . '
'; + } + $tblBody .= '
' . $p->t("tools/notendurchschnittDerZeugnisnote") . ''.$notenDurchschnitt.'
' . $p->t("tools/gewichteterNotendurchschnittDerZeugnisnote") . ''.$notenDurchschnittGewichtet.'
"; + $tbl .= ""; + if ($legende) + { + $tbl .= ""; + } + $tbl .= "
*" . $p->t('tools/legendeNotendurchschnitt') . "
**" . $p->t('tools/legendeGewichteterNotendurchschnitt') . "
" . $p->t('tools/hinweistextMarkierung') . "
"; + if ($i == 0) + echo $p->t('tools/nochKeineBeurteilungEingetragen'); + else + { + $tbl .= "


"; + echo $tbl; + } + } + else + { + $error .= $p->t('tools/fehlerBeimAuslesenDerNoten'); + } +} +echo $error; +echo ' +'; +?> diff --git a/cis/private/lehre/pruefung/pruefungsanmeldung.json.php b/cis/private/lehre/pruefung/pruefungsanmeldung.json.php index 555144a67..a446c73e2 100644 --- a/cis/private/lehre/pruefung/pruefungsanmeldung.json.php +++ b/cis/private/lehre/pruefung/pruefungsanmeldung.json.php @@ -606,9 +606,10 @@ function saveAnmeldung($aktStudiensemester = null, $uid = null) foreach ($prestudent->result as $ps) { - if ($ps->getLaststatus($ps->prestudent_id, $stdsem_lv_besuch)) + // prüfen ob Student zum Zeitpunkt der LV oder zumindest irgendwann Student im Studiengang war/ist + if ($ps->getLaststatus($ps->prestudent_id, $stdsem_lv_besuch) || $ps->studiengang_kz == $studiengang_kz) { - if (($ps->status_kurzbz == "Student") || ($ps->status_kurzbz == "Unterbrecher")) + if (($ps->status_kurzbz == "Student") || ($ps->status_kurzbz == "Unterbrecher") || ($ps->status_kurzbz == "")) { array_push($prestudenten, $ps); } diff --git a/cis/private/lvplan/index.php b/cis/private/lvplan/index.php index ddbddf586..260ee8066 100644 --- a/cis/private/lvplan/index.php +++ b/cis/private/lvplan/index.php @@ -314,8 +314,14 @@ function LoadGruppe(type) - -

'.$p->t("lvplan/saalplan").'

+ '; + + if(!defined('CIS_LVPLAN_SAALPLAN_ANZEIGEN') || CIS_LVPLAN_SAALPLAN_ANZEIGEN) + { + echo '

'.$p->t("lvplan/saalplan").'

'; + } + + echo ' '; @@ -328,21 +334,24 @@ function LoadGruppe(type) - + '; + + if(!defined('CIS_LVPLAN_SAALPLAN_ANZEIGEN') || CIS_LVPLAN_SAALPLAN_ANZEIGEN) + { echo ' '; + } if ($raumres) { diff --git a/cis/private/profile/lva_liste.php b/cis/private/profile/lva_liste.php index 95b9cf50b..33eb7da3b 100644 --- a/cis/private/profile/lva_liste.php +++ b/cis/private/profile/lva_liste.php @@ -304,15 +304,16 @@ require_once('../../../include/benutzerberechtigung.class.php'); tbl_lehrveranstaltung.bezeichnung, tbl_projektarbeit.titel, (SELECT nachname || ' ' || vorname FROM public.tbl_benutzer JOIN public.tbl_person USING(person_id) WHERE uid=student_uid) as student, tbl_lehrveranstaltung.studiengang_kz, tbl_lehrveranstaltung.semester, - tbl_studiengang.email + tbl_studiengang.email, tbl_betreuerart.beschreibung AS beutreuerart_beschreibung FROM - lehre.tbl_lehreinheit, lehre.tbl_lehrveranstaltung, lehre.tbl_projektarbeit, lehre.tbl_projektbetreuer, public.tbl_studiengang + lehre.tbl_lehreinheit, lehre.tbl_lehrveranstaltung, lehre.tbl_projektarbeit, lehre.tbl_projektbetreuer, public.tbl_studiengang, lehre.tbl_betreuerart WHERE tbl_lehreinheit.lehreinheit_id=tbl_projektarbeit.lehreinheit_id AND tbl_lehreinheit.lehrveranstaltung_id=tbl_lehrveranstaltung.lehrveranstaltung_id AND tbl_lehreinheit.studiensemester_kurzbz=".$db->db_add_param($stdsem)." AND tbl_projektarbeit.projektarbeit_id=tbl_projektbetreuer.projektarbeit_id AND tbl_lehrveranstaltung.studiengang_kz=tbl_studiengang.studiengang_kz AND + tbl_projektbetreuer.betreuerart_kurzbz=tbl_betreuerart.betreuerart_kurzbz AND tbl_projektbetreuer.person_id=".$db->db_add_param($mitarbeiter->person_id, FHC_INTEGER); $stg_obj = new studiengang(); @@ -330,6 +331,7 @@ require_once('../../../include/benutzerberechtigung.class.php'); echo ''.$p->t('lvaliste/semester').''; echo ''.$p->t('lvaliste/lvBezeichnung').''; echo ''.$p->t('lvaliste/student').''; + echo ''.$p->t('lvaliste/betreuungsart').''; echo ''.$p->t('lvaliste/titelProjektarbeit').''; echo ''; while($row = $db->db_fetch_object($result)) @@ -339,6 +341,7 @@ require_once('../../../include/benutzerberechtigung.class.php'); echo ''.$row->semester.''; echo ''.$row->bezeichnung.''; echo ''.$row->student.''; + echo ''.$row->beutreuerart_beschreibung.''; echo ''.$row->titel.''; echo ''; diff --git a/cis/private/tools/suche.php b/cis/private/tools/suche.php index 97188553d..f5a1ae591 100644 --- a/cis/private/tools/suche.php +++ b/cis/private/tools/suche.php @@ -111,7 +111,7 @@ if (!$searchPerson && !$searchOrt && !$searchDms && !$searchContent && !$searchO function searchPerson($searchItems) { - global $db, $p, $noalias; + global $db, $p, $noalias, $uid; $bn = new benutzer(); $bn->search($searchItems, 21); @@ -164,10 +164,18 @@ function searchPerson($searchItems) echo '',$row->anrede,''; echo '',$row->vorname,''; echo ''; - if(!defined('CIS_SUCHE_PROFIL_ANZEIGEN') || CIS_SUCHE_PROFIL_ANZEIGEN) + if(!defined('CIS_SUCHE_PROFIL_ANZEIGEN')) echo '',$row->nachname,''; + else if(!CIS_SUCHE_PROFIL_ANZEIGEN) + { + $mitarbeiter = new Mitarbeiter($uid); + if($mitarbeiter->errormsg === NULL) + echo '',$row->nachname,''; + else + echo $row->nachname; + } else - echo $row->nachname; + echo '',$row->nachname,''; if($row->aktiv==false) echo ' (ausgeschieden)'; elseif($bisverwendung->beschausmasscode=='5') diff --git a/config/global.config-default.inc.php b/config/global.config-default.inc.php index 1386a6199..4a13fe2f2 100644 --- a/config/global.config-default.inc.php +++ b/config/global.config-default.inc.php @@ -96,6 +96,9 @@ define('FAS_GESAMTNOTE_PRUEFUNGSHONORAR',false); // Aus Datenschutzgründen ist dies per default deaktiviert define('CIS_GESAMTNOTE_FREIGABEMAIL_NOTE', false); +// Gibt an ob in der Notenliste der Studierenden nur offizielle Noten oder alle angezeigt werden +define('CIS_NOTENLISTE_OFFIZIELL_ANZEIGEN', false); + // Grenzwerte für Anwesenheit define('FAS_ANWESENHEIT_ROT', 70); define('FAS_ANWESENHEIT_GELB', 90); @@ -126,6 +129,7 @@ define('CIS_LVPLAN_PERSONENAUSWAHL_ANZEIGEN',true); define('CIS_LVPLAN_LEHRVERBANDAUSWAHL_ANZEIGEN',true); define('CIS_LVPLAN_ARCHIVAUSWAHL_ANZEIGEN',true); define('CIS_LVPLAN_ZUSATZMENUE_ANZEIGEN',true); +define('CIS_LVPLAN_SAALPLAN_ANZEIGEN',true); //Anmerkung bei Unterrichtseinheiten im LV-Plan anzeigen. Anmerkungen bei LV-Plan Sync mitkopieren. define('LVPLAN_ANMERKUNG_ANZEIGEN',true); @@ -241,7 +245,7 @@ define('LOG_CONTENT', false); // ContentID of default content-template for reports. New contents will be childs of this. define('REPORT_CONTENT_TEMPLATE', ''); -// Schwund in %, der bei Arbeitsplätzen herausgerechnet werden soll. +// Schwund in %, der bei Arbeitsplätzen herausgerechnet werden soll. // zB 5. Dann werden bei 20 Plätzen 5% Schwund herausgerechnet und nur 19 Plätze zurückgegeben define('REIHUNGSTEST_ARBEITSPLAETZE_SCHWUND', 0); diff --git a/content/fas.xul.php b/content/fas.xul.php index 85deaa818..2aecae047 100644 --- a/content/fas.xul.php +++ b/content/fas.xul.php @@ -110,7 +110,7 @@ foreach($addon_obj->result as $addon) - + @@ -377,14 +377,14 @@ foreach($addon_obj->result as $addon) label = "&menu-statistic-notenspiegel.label;" command = "menu-statistic-notenspiegel:command" accesskey = "&menu-statistic-notenspiegel.accesskey;"/> - + diff --git a/content/fasoverlay.js.php b/content/fasoverlay.js.php index 0c80221e9..375818b48 100644 --- a/content/fasoverlay.js.php +++ b/content/fasoverlay.js.php @@ -1077,7 +1077,7 @@ function StatistikPrintNotenspiegelErweitert(typ) window.open('content/statistik/notenspiegel_erweitert.php?studiengang_kz='+studiengang_kz+'&semester='+semester+'&typ='+typ+'&orgform='+orgform,'Notenspiegel'); } -function StatistikPrintNotenspiegelStudent() +function StatistikPrintStudienverlaufStudent() { var tree = document.getElementById('student-tree'); var data=''; @@ -1094,7 +1094,7 @@ function StatistikPrintNotenspiegelStudent() alert('Markierte Person ist kein Student'); return; } - window.open('index.ci.php/person/gradelist/index/'+student_uid,'Notenspiegel'); + window.open('index.ci.php/person/gradelist/index/'+student_uid,'Studienverlauf'); } // **** diff --git a/content/student/studentprojektarbeitoverlay.xul.php b/content/student/studentprojektarbeitoverlay.xul.php index c9f68cc0a..5bceac252 100644 --- a/content/student/studentprojektarbeitoverlay.xul.php +++ b/content/student/studentprojektarbeitoverlay.xul.php @@ -233,7 +233,7 @@ echo ''; @@ -247,7 +247,7 @@ echo ''; diff --git a/include/dokument_export.class.php b/include/dokument_export.class.php index b1eee8df3..523a5f89d 100644 --- a/include/dokument_export.class.php +++ b/include/dokument_export.class.php @@ -292,7 +292,7 @@ class dokument_export if($ret!=0) { - $this->errormsg = 'Dokumentenkonvertierung ist derzeit nicht möglich. Bitte informieren Sie den Administrator'; + $this->errormsg = 'Dokumentenkonvertierung ist derzeit nicht möglich. Bitte versuchen Sie es in einer Minute erneut oder kontaktieren Sie einen Administrator'; return false; } break; @@ -465,7 +465,7 @@ class dokument_export if($ret!=0) { - $this->errormsg = 'Dokumentenkonvertierung ist derzeit nicht möglich. Bitte informieren Sie den Administrator'; + $this->errormsg = 'Dokumentenkonvertierung ist derzeit nicht möglich. Bitte versuchen Sie es in einer Minute erneut oder kontaktieren Sie einen Administrator'; return false; } diff --git a/locale/de-AT/fas.dtd b/locale/de-AT/fas.dtd index 6662cb355..86415c024 100644 --- a/locale/de-AT/fas.dtd +++ b/locale/de-AT/fas.dtd @@ -114,9 +114,9 @@ - - - + + + diff --git a/locale/de-AT/lvaliste.php b/locale/de-AT/lvaliste.php index 48189aee6..e51ddcbf5 100644 --- a/locale/de-AT/lvaliste.php +++ b/locale/de-AT/lvaliste.php @@ -1,5 +1,7 @@ phrasen['lvaliste/titel']='Lehrveranstaltungsübersicht'; +$this->phrasen['lvaliste/anwesenheit']='Anwesenheit'; +$this->phrasen['lvaliste/anwesenheit/studenten']='Anwesenheit der Studierenden'; $this->phrasen['lvaliste/hilfeText']='Erklärung\n\nStg-Sem: Studiengang-Semester\nGruppen: Teilnehmende Gruppen\nBlock: Blockung (1->Einzelstunden; 2->Doppelstunden; ...)\nWR: Wochenrhythmus (1->jede Woche; 2->jede 2. Woche; ...)\nStd: gesamte Semesterstunden\nKW: Kalenderwoche in der die Lehrveranstaltung startet'; $this->phrasen['lvaliste/hilfeAnzeigen']='Hilfe anzeigen'; @@ -31,4 +33,5 @@ $this->phrasen['lvaliste/gesamtnote']='Noten eintragen'; $this->phrasen['lvaliste/anzahl']='Anzahl'; $this->phrasen['lvaliste/summe']='Summe'; $this->phrasen['lvaliste/lvinfo']='LV-Info'; -$this->phrasen['lvaliste/id']='ID'; \ No newline at end of file +$this->phrasen['lvaliste/id']='ID'; +$this->phrasen['lvaliste/betreuungsart']='Betreuungsart'; \ No newline at end of file diff --git a/locale/en-US/lvaliste.php b/locale/en-US/lvaliste.php index 20df4f7c2..4560a4182 100644 --- a/locale/en-US/lvaliste.php +++ b/locale/en-US/lvaliste.php @@ -29,6 +29,9 @@ $this->phrasen['lvaliste/keineDatensaetze']='No Entrys for this Semester!'; $this->phrasen['lvaliste/lehrveranstaltungen']='Courses'; $this->phrasen['lvaliste/betreuungen']='Supervisor'; $this->phrasen['lvaliste/koordination']='Coordination'; +$this->phrasen['lvaliste/gesamtnote']='Enter grades'; $this->phrasen['lvaliste/anzahl']='Number'; $this->phrasen['lvaliste/summe']='Total'; +$this->phrasen['lvaliste/lvinfo']='Course-Info'; $this->phrasen['lvaliste/id']='ID'; +$this->phrasen['lvaliste/betreuungsart']='Kind of supervision'; diff --git a/rdf/diplomasupplement.xml.php b/rdf/diplomasupplement.xml.php index d52617c10..3621339f0 100644 --- a/rdf/diplomasupplement.xml.php +++ b/rdf/diplomasupplement.xml.php @@ -669,6 +669,7 @@ if (isset($_REQUEST["xmlformat"]) && $_REQUEST["xmlformat"] == "xml") else { $note_alt = $arrayLvAusbildungssemester[$row_stud->lehrveranstaltung_id]['note']; + $note_alt_positiv = $arrayLvAusbildungssemester[$row_stud->lehrveranstaltung_id]['note_positiv']; $note_neu = $row_stud->anmerkung; // alte oder neue note besser @@ -687,6 +688,13 @@ if (isset($_REQUEST["xmlformat"]) && $_REQUEST["xmlformat"] == "xml") $arrayLvAusbildungssemester[$row_stud->lehrveranstaltung_id]['note'] = $db->db_parse_bool($row_stud->offiziell) ? $row_stud->anmerkung : ""; $arrayLvAusbildungssemester[$row_stud->lehrveranstaltung_id]['note_positiv'] = $db->db_parse_bool($row_stud->positiv); $arrayLvAusbildungssemester[$row_stud->lehrveranstaltung_id]['sort'] = $row_stud->sort; + + // ects dazuzählen wenn alte Note negativ, neue positiv + if ($arrayLvAusbildungssemester[$row_stud->lehrveranstaltung_id]['note_positiv'] === true && $note_alt_positiv !== true) + { + $ects_total_positiv += $row_stud->ects; + $semester_ects_positiv += $row_stud->ects; + } } } diff --git a/system/vorlage_zip/DiplSupplementDebug.odt b/system/vorlage_zip/DiplSupplementDebug.odt new file mode 100644 index 000000000..aaee7c600 Binary files /dev/null and b/system/vorlage_zip/DiplSupplementDebug.odt differ diff --git a/system/xsl/diplomaSuppDebug.xsl b/system/xsl/diplomaSuppDebug.xsl new file mode 100644 index 000000000..6d3feaf42 --- /dev/null +++ b/system/xsl/diplomaSuppDebug.xsl @@ -0,0 +1,2948 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ANHANG ZUM DIPLOM + DIPLOMA SUPPLEMENT + + + + + + -Studiengang + + + + + + + + ’s degree program + + + + + + + Verliehener Titel ist nicht gesetzt + Regelstudiendauer wurde nicht gefunden + ECTS wurden nicht gefunden + Kein Sponsionsdatum gesetzt + Keine Studiengangsleitung eingetragen + Datum der Abschlussprüfung ist nicht gesetzt + Abschlussbeurteilung ist nicht gesetzt + + + + + + + + + + TRANSCRIPT OF RECORDS + + Semester - + + ’s degree program + + + Student ID: + Program Code: + + + First Name/Last Name: + + Date of Birth: + + Within the period of studies at the University of Applied Sciences Technikum Wien from to in the ’s degree program examinations in the following subjects were passed: + + + + + + + + + + + Date + + + Course + + + Type1 + + + SP/W2 + + + ECTS credits + + + Grade³ + + + + + + Total + + + + - + + + + + - + + + + + - + + + + + + + + - + + + + + + ¹ Type: Laboratory (LAB), Lecture (VO), Integrated Course (ILV), Seminar (SE), Tutorial (TUT), Project (PRJ), Exercise (UE), Distance Learning (FL), Other (SO) + ² 1 Semester period per week = 45 minutes + ³ Grading Scheme: excellent (1), good (2), satisfactory (3), sufficient (4), Credit based on previous experience/work (ar), successfully completed (ea), Participated with success (met), participated (tg) + + + + + + + + + Final Examination + + + + + + 's Examination on + + + + + + + + Grading Scheme: Passed with distinction, Passed with merit, Passed + + + + + + + + + + + + + + + Vienna, + Place, Date + + + + + + Program Director + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Σ + + + + + - + + + + + - + + + + + - + + + + + + + + + + - + + + + + + + + + + + + + + + + ID: + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vilesci/lehre/lehrveranstaltung.php b/vilesci/lehre/lehrveranstaltung.php index 92cd5d7de..1011b6d00 100644 --- a/vilesci/lehre/lehrveranstaltung.php +++ b/vilesci/lehre/lehrveranstaltung.php @@ -683,8 +683,7 @@ echo ' 19: {sorter: false, filter: false}, 20: {sorter: false, filter: false}, 21: {sorter: false, filter: false}}, - widgetOptions : {filter_saveFilters : true, - filter_functions : { + widgetOptions : {filter_functions : { // Add select menu to this column 10 : { "True" : function(e, n, f, i, $r, c, data) { return /t/.test(e); }, @@ -704,13 +703,6 @@ echo ' } } } - }); - - $(\'.resetsaved\').click(function() - { - $("#t1").trigger("filterReset"); - location.reload(); - return false; }); }); @@ -990,7 +982,6 @@ if ($result_lv!=0) $num_rows=$db->db_num_rows($result_lv); echo '

Übersicht - '.$num_rows.' LVAs

- '; diff --git a/vilesci/stammdaten/auswertung_fhtw.php b/vilesci/stammdaten/auswertung_fhtw.php index a817614c3..685473499 100644 --- a/vilesci/stammdaten/auswertung_fhtw.php +++ b/vilesci/stammdaten/auswertung_fhtw.php @@ -1348,7 +1348,7 @@ if (isset($_REQUEST['reihungstest'])) ORDER BY start ASC LIMIT 1 ) ) - AND bewerbung_abgeschicktamum IS NOT NULL + /*AND bewerbung_abgeschicktamum IS NOT NULL*/ /* Leider gibt es bestaetigte Bewerbungen, die nie abgeschickt wurden */ AND bestaetigtam IS NOT NULL AND tbl_gebiet.gebiet_id != 7 ";