mirror of
https://github.com/Karaka-Management/oms-Editor.git
synced 2026-02-04 04:38:43 +00:00
Pull out general functionality
This commit is contained in:
parent
faa061260b
commit
5dc24f5e46
|
|
@ -76,14 +76,8 @@ final class ApiController extends Controller
|
|||
}
|
||||
|
||||
$doc = $this->createDocFromRequest($request);
|
||||
|
||||
EditorDocMapper::create($doc);
|
||||
$response->set($request->getUri()->__toString(), [
|
||||
'status' => NotificationLevel::OK,
|
||||
'title' => 'Document',
|
||||
'message' => 'Document successfully created.',
|
||||
'response' => $doc->jsonSerialize()
|
||||
]);
|
||||
$this->createModel($request, $doc, EditorDocMapper::class, 'doc');
|
||||
$this->fillJsonResponse($request, $response, NotificationLevel::OK, 'Document', 'Document successfully created', $doc);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user