mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-24 10:22:18 +00:00
Merge branch 'master' into feature/Anrechnungen_NEU
This commit is contained in:
@@ -612,9 +612,9 @@ class Messages_model extends CI_Model
|
||||
if (!isEmptyString($vorlage_kurzbz))
|
||||
{
|
||||
$this->load->model('system/Vorlagestudiengang_model', 'VorlagestudiengangModel');
|
||||
$this->VorlagestudiengangModel->addOrder('version','DESC');
|
||||
$this->VorlagestudiengangModel->addOrder('version', 'DESC');
|
||||
|
||||
$getVorlage = $this->VorlagestudiengangModel->loadWhere(array('vorlage_kurzbz' => $vorlage_kurzbz));
|
||||
$getVorlage = $this->VorlagestudiengangModel->loadWhere(array('vorlage_kurzbz' => $vorlage_kurzbz, 'aktiv' => true));
|
||||
}
|
||||
|
||||
return $getVorlage;
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
<?php
|
||||
class Bisioaufenthaltfoerderung_model extends DB_Model
|
||||
{
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
$this->dbTable = 'bis.tbl_bisio_aufenthaltfoerderung';
|
||||
$this->pk = array('bisio_id', 'aufenthaltfoerderung_code');
|
||||
$this->hasSequence = false;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,50 @@
|
||||
<?php
|
||||
|
||||
|
||||
class ZGVPruefungStatus_model extends DB_Model
|
||||
{
|
||||
/**
|
||||
* Constructor
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
$this->dbTable = 'public.tbl_zgvpruefungstatus_status';
|
||||
$this->pk = 'zgv_pruefung_status_id';
|
||||
$this->hasSequence = true;
|
||||
}
|
||||
|
||||
public function getZgvStatus($zgvpruefung_id)
|
||||
{
|
||||
$this->addOrder('datum', 'DESC');
|
||||
$this->addLimit(1);
|
||||
|
||||
return $this->loadWhere(array('zgvpruefung_id' => $zgvpruefung_id));
|
||||
}
|
||||
|
||||
public function getZgvStatusByPrestudent($prestudent_id)
|
||||
{
|
||||
$this->addJoin('public.tbl_zgvpruefung', 'zgvpruefung_id');
|
||||
$this->addOrder($this->dbTable . '.datum', 'DESC');
|
||||
$this->addLimit(1);
|
||||
return $this->loadWhere(array('prestudent_id' => $prestudent_id));
|
||||
}
|
||||
|
||||
public function getOpenZgvByPerson($person_id, $status)
|
||||
{
|
||||
$query = 'SELECT status.zgvpruefung_id, status.datum, status.status
|
||||
FROM public.tbl_zgvpruefungstatus_status status
|
||||
INNER JOIN
|
||||
(
|
||||
SELECT zgvpruefung_id, max(datum) as MaxDate
|
||||
FROM public.tbl_zgvpruefungstatus_status
|
||||
GROUP BY zgvpruefung_id
|
||||
) sub ON status.zgvpruefung_id = sub.zgvpruefung_id AND status.datum = sub.MaxDate
|
||||
JOIN public.tbl_zgvpruefung ON status.zgvpruefung_id = public.tbl_zgvpruefung.zgvpruefung_id
|
||||
JOIN public.tbl_prestudent USING (prestudent_id)
|
||||
WHERE person_id = ?
|
||||
AND status.status IN ?';
|
||||
|
||||
return $this->execQuery($query, array($person_id, $status));
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
<?php
|
||||
|
||||
|
||||
class ZGVPruefung_model extends DB_Model
|
||||
{
|
||||
/**
|
||||
* Constructor
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
$this->dbTable = 'public.tbl_zgvpruefung';
|
||||
$this->pk = 'zgvpruefung_id';
|
||||
$this->hasSequence = true;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -154,9 +154,11 @@ class Notiz_model extends DB_Model
|
||||
{
|
||||
// Join with the table public.tbl_notizzuordnung using notiz_id
|
||||
$this->addJoin('public.tbl_notizzuordnung', 'notiz_id');
|
||||
$this->addOrder('insertamum', 'DESC');
|
||||
$this->addJoin('public.tbl_prestudent', 'prestudent_id', 'LEFT');
|
||||
$this->addJoin('public.tbl_studiengang', 'studiengang_kz', 'LEFT');
|
||||
$this->addOrder('public.tbl_notiz.insertamum', 'DESC');
|
||||
|
||||
return $this->loadWhere(array('person_id' => $person_id, 'titel LIKE' => $titel));
|
||||
return $this->loadWhere(array('public.tbl_notizzuordnung.person_id' => $person_id, 'titel LIKE' => $titel));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -11,7 +11,8 @@ class Variablenname_model extends DB_Model
|
||||
ORDER BY studienjahr_kurzbz, start
|
||||
) sem
|
||||
WHERE start > now()
|
||||
LIMIT 1;'
|
||||
LIMIT 1;',
|
||||
'infocenter_studiensgangtyp' => 'SELECT infocenter_studiensgangtyp FROM public.tbl_variablenname LIMIT 1'
|
||||
);
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user