Modal Adressen

This commit is contained in:
ma0068
2023-11-02 16:41:28 +01:00
parent 94fe3b594d
commit 81b080ec41
2 changed files with 80 additions and 40 deletions
@@ -310,19 +310,35 @@ class Student extends FHC_Controller
'zustelladresse' => $_POST['zustelladresse'],
'co_name' => $_POST['co_name'],
'typ' => $_POST['typ']
]
);
if (isError($result)) {
if (isError($result))
{
$this->output->set_status_header(REST_Controller::HTTP_INTERNAL_SERVER_ERROR);
return $this->outputJson($result);
}
return $this->outputJsonSuccess(true);
}
public function getAdressentypen()
{
$this->load->model('person/Adressentyp_model', 'AdressentypModel');
$result = $this->AdressentypModel->load();
if (isError($result)) {
$this->output->set_status_header(REST_Controller::HTTP_INTERNAL_SERVER_ERROR);
$this->outputJson(getError($result));
} else {
$this->outputJson(getData($result) ?: []);
}
}
public function getGmeinden($plz)
{
//TODO(manu) finish
$result = "";
return $result;
}
public function getKontakte($person_id)