From e611d3a3cb1164612cf67e5be9ed47cc42cc592e Mon Sep 17 00:00:00 2001 From: Alex Date: Thu, 16 Feb 2017 18:58:10 +0200 Subject: [PATCH] registration --- app/library/App/Controllers/UserController.php | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/app/library/App/Controllers/UserController.php b/app/library/App/Controllers/UserController.php index faaf2ff..5cefa8c 100755 --- a/app/library/App/Controllers/UserController.php +++ b/app/library/App/Controllers/UserController.php @@ -58,14 +58,19 @@ class UserController extends CrudResourceController $item = $this->createModelInstance(); + $item->save(); + die($item->id); + + $newItem = $this->createItem($item, $data); if (!$newItem) { return $this->onCreateFailed($item, $data); } - $last_id = $newItem->getWriteConnection()->lastInsertId(); - $responseData = $this->getFindData($last_id); + + //$last_id = $newItem->getWriteConnection()->lastInsertId(); + //$responseData = $this->getFindData($last_id); $response = $this->getCreateResponse($responseData, $data); -- libgit2 0.21.4