diff --git a/Layout/default/Preorder/Index.php b/Layout/default/Preorder/Index.php index 0a435c382..eae4e326a 100644 --- a/Layout/default/Preorder/Index.php +++ b/Layout/default/Preorder/Index.php @@ -145,6 +145,7 @@ adb_wohneinheit_id) ? ((string)$preorder->adb_wohneinheit ? $preorder->adb_wohneinheit."
" : "") : "<keine Wohneinheit>
"?> adb_hausnummer->plz->plz?> adb_hausnummer->strasse->gemeinde->name?> + address_district) ? "
(".$preorder->address_district.")" : ""?> diff --git a/application/Api/v1/PreorderApicontroller.php b/application/Api/v1/PreorderApicontroller.php index 9e6048b0d..16226eb8f 100644 --- a/application/Api/v1/PreorderApicontroller.php +++ b/application/Api/v1/PreorderApicontroller.php @@ -61,6 +61,7 @@ class PreorderApicontroller extends mfBaseApicontroller { } protected function submitPreorder() { + //var_dump($this->post);exit; if(!$this->campaigns) { $this->log->debug("disallowed request because no campaign for apikey"); return mfResponse::Forbidden(); @@ -243,6 +244,9 @@ class PreorderApicontroller extends mfBaseApicontroller { if($address_info) { $preorder_data['address_info'] = $address_info; } + if(property_exists($this->post['address'],"district") && $this->post['address']->district) { + $preorder_data['address_district'] = $this->post['address']->district; + } if($this->post['acceptAgb'] === true) { $preorder_data['accept_agb'] = 1; diff --git a/application/Preorder/PreorderModel.php b/application/Preorder/PreorderModel.php index 0d6335fcb..a426f57b7 100644 --- a/application/Preorder/PreorderModel.php +++ b/application/Preorder/PreorderModel.php @@ -5,6 +5,7 @@ class PreorderModel { public $preordercampaign_id; public $adb_hausnummer_id; public $adb_wohneinheit_id; + public $address_district; public $address_info; public $building_id; public $termination_id;