From 4413a64860e986be9fd7d9663c532bdcb6173ab5 Mon Sep 17 00:00:00 2001 From: paolo Date: Wed, 11 May 2016 10:40:08 +0200 Subject: [PATCH] - Added new permission to access to tbl_bundesland table using basis/nation - Added bundesland controller and model --- application/config/fhcomplete.php | 1 + .../controllers/api/v1/codex/Bundesland.php | 37 +++++++++++++++++++ 2 files changed, 38 insertions(+) create mode 100644 application/controllers/api/v1/codex/Bundesland.php diff --git a/application/config/fhcomplete.php b/application/config/fhcomplete.php index 2a3b16462..3b862bf12 100644 --- a/application/config/fhcomplete.php +++ b/application/config/fhcomplete.php @@ -6,6 +6,7 @@ $config['fhc_version'] = '3.2'; $config['fhc_acl'] = array ( + 'bis.tbl_bundesland' => 'basis/nation', 'bis.tbl_nation' => 'basis/nation', 'bis.tbl_lgartcode' => 'basis/lgartcode', diff --git a/application/controllers/api/v1/codex/Bundesland.php b/application/controllers/api/v1/codex/Bundesland.php new file mode 100644 index 000000000..ad5c8e29a --- /dev/null +++ b/application/controllers/api/v1/codex/Bundesland.php @@ -0,0 +1,37 @@ +load->model('codex/bundesland_model', 'BundeslandModel'); + // Load set the uid of the model to let to check the permissions + $this->BundeslandModel->setUID($this->_getUID()); + } + + public function getAll() + { + $result = $this->BundeslandModel->loadWhole(); + + $this->response($result, REST_Controller::HTTP_OK); + } +} \ No newline at end of file