change createmodel function

This commit is contained in:
Dennis Eichhorn 2019-07-08 19:21:23 +02:00
parent 80ccaecbfd
commit f5d16a6682

View File

@ -60,7 +60,7 @@ final class ApiController extends Controller
} }
$card = $this->createKanbanCardFromRquest($request); $card = $this->createKanbanCardFromRquest($request);
$this->createModel($request, $card, KanbanCardMapper::class, 'card'); $this->createModel($request->getHeader()->getAccount(), $card, KanbanCardMapper::class, 'card');
$this->fillJsonResponse($request, $response, NotificationLevel::OK, 'Card', 'Card successfully created.', $card); $this->fillJsonResponse($request, $response, NotificationLevel::OK, 'Card', 'Card successfully created.', $card);
} }
@ -137,7 +137,7 @@ final class ApiController extends Controller
} }
$board = $this->createKanbanBoardFromRquest($request); $board = $this->createKanbanBoardFromRquest($request);
$this->createModel($request, $board, KanbanBoardMapper::class, 'board'); $this->createModel($request->getHeader()->getAccount(), $board, KanbanBoardMapper::class, 'board');
$this->fillJsonResponse($request, $response, NotificationLevel::OK, 'Board', 'Board successfully created.', $board); $this->fillJsonResponse($request, $response, NotificationLevel::OK, 'Board', 'Board successfully created.', $board);
} }
@ -206,7 +206,7 @@ final class ApiController extends Controller
} }
$column = $this->createKanbanColumnFromRquest($request); $column = $this->createKanbanColumnFromRquest($request);
$this->createModel($request, $column, KanbanColumnMapper::class, 'column'); $this->createModel($request->getHeader()->getAccount(), $column, KanbanColumnMapper::class, 'column');
$this->fillJsonResponse($request, $response, NotificationLevel::OK, 'Column', 'Column successfully created.', $column); $this->fillJsonResponse($request, $response, NotificationLevel::OK, 'Column', 'Column successfully created.', $column);
} }