mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-26 00:54:27 +00:00
improved infocenter details, added bootstrap and admin theme (sb admin 2) , added zgv pruefung Status, Studiensemester and Ausbildungssemester, contacts in one table, nachzureichen and nachgereicht am columns
This commit is contained in:
@@ -192,4 +192,38 @@ class Prestudent_model extends DB_Model
|
||||
|
||||
return $this->execQuery(sprintf($query, is_array($prestudent_id) ? 'IN' : '='), array($prestudent_id));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* gets extended zgv data (with bezeichnung) for a prestudent
|
||||
* includes last status, Studiengang, zgv, zgv master
|
||||
* @param $prestudent_id
|
||||
*/
|
||||
public function getPrestudentWithZgv($prestudent_id)
|
||||
{
|
||||
$this->addSelect('tbl_prestudent.*, tbl_studiengang.kurzbzlang as studiengang, tbl_studiengang.typ as studiengangtyp, tbl_zgv.zgv_code, tbl_zgv.zgv_bez,
|
||||
tbl_prestudent.zgvort, tbl_prestudent.zgvdatum, tbl_prestudent.zgvnation as zgvnation_code,
|
||||
tbl_zgvmaster.zgvmas_code, tbl_zgvmaster.zgvmas_bez, tbl_prestudent.zgvmaort, tbl_prestudent.zgvmadatum, tbl_prestudent.zgvmanation as zgvmanation_code');
|
||||
$this->addJoin('public.tbl_studiengang', 'studiengang_kz', 'LEFT');
|
||||
$this->addJoin('bis.tbl_zgv', 'zgv_code', 'LEFT');
|
||||
$this->addJoin('bis.tbl_zgvmaster', 'zgvmas_code', 'LEFT');
|
||||
|
||||
$prestudent = $this->load($prestudent_id);
|
||||
if($prestudent->error)
|
||||
return error($prestudent->retval);
|
||||
|
||||
//Prestudentstatus
|
||||
$this->load->model('crm/prestudentstatus_model', 'PrestudentstatusModel');
|
||||
$lastStatus = $this->PrestudentstatusModel->getLastStatus($prestudent_id);
|
||||
|
||||
if ($lastStatus->error)
|
||||
{
|
||||
return error($lastStatus->retval);
|
||||
}
|
||||
|
||||
$prestudent->retval[0]->prestudentstatus = $lastStatus->retval[0];
|
||||
|
||||
return success($prestudent->retval);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user