mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-21 17:02:19 +00:00
person model: added method that return list of db columns
This commit is contained in:
@@ -60,7 +60,8 @@ class Person extends APIv1_Controller
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->response();
|
||||
$fields = $this->PersonModel->getFields();
|
||||
$this->response($fields, REST_Controller::HTTP_OK);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -11,11 +11,51 @@ class Person_model extends DB_Model
|
||||
$this->dbTable = 'public.tbl_person';
|
||||
$this->pk = 'person_id';
|
||||
}
|
||||
|
||||
public function getFields()
|
||||
{
|
||||
$fields = array(
|
||||
//Tabellenspalten
|
||||
"person_id" => NULL,
|
||||
"sprache" => NULL,
|
||||
"anrede" => NULL,
|
||||
"titelpost" => NULL,
|
||||
"titelpre" => NULL,
|
||||
"nachname" => NULL,
|
||||
"vorname" => NULL,
|
||||
"vornamen" => NULL,
|
||||
"gebdatum" => NULL,
|
||||
"gebort" => NULL,
|
||||
"gebzeit" => NULL,
|
||||
"foto" => NULL,
|
||||
"anmerkungen" => NULL,
|
||||
"homepage" => NULL,
|
||||
"svnr" => NULL,
|
||||
"ersatzkennzeichen" => NULL,
|
||||
"familienstand" => NULL,
|
||||
"anzahlkinder" => NULL,
|
||||
"aktiv"=>TRUE,
|
||||
"insertamum" => NULL,
|
||||
"insertvon" => NULL,
|
||||
"updateamum" => NULL,
|
||||
"updatevon" => NULL,
|
||||
"geschlecht" => "u",
|
||||
"staatsbuergerschaft" => NULL,
|
||||
"geburtsnation" => NULL,
|
||||
"ext_id" => NULL,
|
||||
"kurzbeschreibung"> NULL,
|
||||
"zugangscode" => NULL,
|
||||
"foto_sperre" => FALSE,
|
||||
"matr_nr"=> NULL
|
||||
);
|
||||
|
||||
return $this->_success($fields);
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
/*public function checkBewerbung($email, $studiensemester_kurzbz = NULL)
|
||||
public function checkBewerbung($email, $studiensemester_kurzbz = NULL)
|
||||
{
|
||||
$this->db->distinct();
|
||||
|
||||
@@ -51,5 +91,5 @@ class Person_model extends DB_Model
|
||||
;
|
||||
}
|
||||
return $this->db->get()->result_array();
|
||||
}*/
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user