Bladeren bron

fix missing education timint post security

Olivier Massot 1 jaar geleden
bovenliggende
commit
ccba9022f4
1 gewijzigde bestanden met toevoegingen van 7 en 5 verwijderingen
  1. 7 5
      src/Entity/Education/EducationTiming.php

+ 7 - 5
src/Entity/Education/EducationTiming.php

@@ -28,18 +28,20 @@ use Doctrine\ORM\Mapping as ORM;
 #[ApiResource(
     operations: [
         new Get(
-            security: 'is_granted(\'ROLE_ORGANIZATION_VIEW\') and object.getOrganization().getId() == user.getOrganization().getId()'
+            security: 'is_granted("ROLE_ORGANIZATION_VIEW") and object.getOrganization().getId() == user.getOrganization().getId()'
         ),
         new Put(
-            security: 'is_granted(\'ROLE_ORGANIZATION\') and object.getOrganization().getId() == user.getOrganization().getId()'
+            security: 'is_granted("ROLE_ORGANIZATION") and object.getOrganization().getId() == user.getOrganization().getId()'
         ),
         new Delete(
-            security: 'is_granted(\'ROLE_ORGANIZATION\') and object.getOrganization().getId() == user.getOrganization().getId()'
+            security: 'is_granted("ROLE_ORGANIZATION") and object.getOrganization().getId() == user.getOrganization().getId()'
         ),
         new GetCollection(
-            security: 'is_granted(\'ROLE_ORGANIZATION_VIEW\')'
+            security: 'is_granted("ROLE_ORGANIZATION_VIEW")'
+        ),
+        new Post(
+            security: 'is_granted("ROLE_ORGANIZATION")'
         ),
-        new Post(),
     ]
 )]
 // #[Auditable]