浏览代码

Merge branch 'release/2.5.1'

Olivier Massot 5 月之前
父节点
当前提交
575662ac93
共有 2 个文件被更改,包括 17 次插入2 次删除
  1. 2 2
      src/Entity/Access/Preferences.php
  2. 15 0
      src/Entity/Organization/Parameters.php

+ 2 - 2
src/Entity/Access/Preferences.php

@@ -7,7 +7,7 @@ namespace App\Entity\Access;
 // use DH\Auditor\Provider\Doctrine\Auditing\Annotation\Auditable;
 use ApiPlatform\Metadata\ApiResource;
 use ApiPlatform\Metadata\Get;
-use ApiPlatform\Metadata\Put;
+use ApiPlatform\Metadata\Patch;
 use Doctrine\ORM\Mapping as ORM;
 
 /**
@@ -20,7 +20,7 @@ use Doctrine\ORM\Mapping as ORM;
         new Get(
             security: 'object.getAccess().getId() == user.getId()'
         ),
-        new Put(
+        new Patch(
             security: 'object.getAccess().getId() == user.getId()'
         ),
     ]

+ 15 - 0
src/Entity/Organization/Parameters.php

@@ -211,6 +211,9 @@ class Parameters
     #[ORM\Column(options: ['default' => false])]
     private bool $showEducationIsACollectivePractice = false;
 
+    #[ORM\Column(options: ['default' => false])]
+    private bool $handlePresence = false;
+
     #[Pure]
     public function __construct()
     {
@@ -854,4 +857,16 @@ class Parameters
 
         return $this;
     }
+
+    public function isHandlePresence(): bool
+    {
+        return $this->handlePresence;
+    }
+
+    public function setHandlePresence(bool $handlePresence): self
+    {
+        $this->handlePresence = $handlePresence;
+
+        return $this;
+    }
 }