Merge branch 'feature-12987/Sonderbeitrag_versicherung_trennen' into feature-10450/DVUH_requestMatrikelnummer

This commit is contained in:
KarpAlex
2021-05-18 23:40:39 +02:00
45 changed files with 2631 additions and 282 deletions
@@ -220,7 +220,7 @@ class Pruefungsprotokoll extends Auth_Controller
$nullfields = array('uhrzeit', 'endezeit', 'abschlussbeurteilung_kurzbz', 'protokoll');
foreach ($data as $idx => $item)
{
if (in_array($idx, $nullfields) & $item === '')
if (in_array($idx, $nullfields) && $item === '')
$data[$idx] = null;
}
+1 -1
View File
@@ -167,7 +167,7 @@ class LDAPLib
}
// LDAP connection
$ldapConnection = @ldap_connect($ldapConfigs[self::SERVER], $ldapConfigs[self::PORT]);
$ldapConnection = @ldap_connect($ldapConfigs[self::SERVER].':'.$ldapConfigs[self::PORT]);
if ($ldapConnection) // if success
{
// Sets the LDAP protocol version
@@ -41,4 +41,23 @@ class Projektbetreuer_model extends DB_Model
return error ('Incorrect parameter type');
}
}
/**
* Get Projektbetreuer data by authentification token
* @param $zugangstoken
* @return object
*/
public function getBetreuerByToken($zugangstoken)
{
$qry = '
SELECT tbl_projektbetreuer.person_id, tbl_projektbetreuer.projektarbeit_id, student_uid
FROM lehre.tbl_projektbetreuer
JOIN lehre.tbl_projektarbeit USING (projektarbeit_id)
WHERE zugangstoken = ? AND zugangstoken_gueltigbis >= NOW()
ORDER BY tbl_projektbetreuer.insertamum DESC, projektarbeit_id DESC
LIMIT 1
';
return $this->execQuery($qry, array($zugangstoken));
}
}
@@ -13,6 +13,11 @@ class Benutzer_model extends DB_Model
$this->hasSequence = false;
}
/**
* Gets active Benutzer from person_id
* @param $person_id
* @return object
*/
public function getFromPersonId($person_id)
{
return $this->loadWhere(array('person_id' => $person_id, 'aktiv' => true));
+1 -1
View File
@@ -6,7 +6,7 @@ class Nation_widget extends DropdownWidget
{
// Nation
$this->load->model('codex/Nation_model', 'NationModel');
$this->NationModel->addOrder('nation_code');
$this->NationModel->addOrder('kurztext');
$this->addSelectToModel($this->NationModel, 'nation_code', 'kurztext');