module/Core/src/Core/Entity/FileEntity.php 1 location
|
@@ 200-210 (lines=11) @@
|
| 197 |
|
return $this; |
| 198 |
|
} |
| 199 |
|
|
| 200 |
|
public function getPermissions() |
| 201 |
|
{ |
| 202 |
|
if (!$this->permissions) { |
| 203 |
|
$perms = new Permissions(); |
| 204 |
|
if ($this->user instanceof UserInterface) { |
| 205 |
|
$perms->grant($this->user, PermissionsInterface::PERMISSION_ALL); |
| 206 |
|
} |
| 207 |
|
$this->setPermissions($perms); |
| 208 |
|
} |
| 209 |
|
return $this->permissions; |
| 210 |
|
} |
| 211 |
|
} |
| 212 |
|
|
module/Organizations/src/Organizations/Entity/Organization.php 1 location
|
@@ 269-277 (lines=9) @@
|
| 266 |
|
return $this->permissions; |
| 267 |
|
} |
| 268 |
|
|
| 269 |
|
public function setPermissions(PermissionsInterface $permissions) |
| 270 |
|
{ |
| 271 |
|
// Assure the user has always all rights. |
| 272 |
|
if ($this->user) { |
| 273 |
|
$permissions->grant($this->user, Permissions::PERMISSION_ALL); |
| 274 |
|
} |
| 275 |
|
$this->permissions = $permissions; |
| 276 |
|
return $this; |
| 277 |
|
} |
| 278 |
|
|
| 279 |
|
public function getPermissionsResourceId() |
| 280 |
|
{ |