add route for creating a person, and post api

This commit is contained in:
2021-05-21 18:05:03 +02:00
parent 857298b8b8
commit ebe3bc5f7b
8 changed files with 246 additions and 19 deletions

View File

@@ -501,11 +501,13 @@ class ChillPersonExtension extends Extension implements PrependExtensionInterfac
'_entity' => [
'methods' => [
Request::METHOD_GET => true,
Request::METHOD_HEAD => true
Request::METHOD_HEAD => true,
Request::METHOD_POST=> true,
],
'roles' => [
Request::METHOD_GET => \Chill\PersonBundle\Security\Authorization\PersonVoter::SEE,
Request::METHOD_HEAD => \Chill\PersonBundle\Security\Authorization\PersonVoter::SEE,
Request::METHOD_POST => \Chill\PersonBundle\Security\Authorization\PersonVoter::CREATE,
]
],