add flags to permissions groups

Flags can be added to permissions group to store some metadata.

An interface `PermissionsGroupFlagProvider` allow to add some flag to the form which create/
edit permissions groups.
This commit is contained in:
2018-09-07 16:24:36 +02:00
parent b1ae55ba80
commit b9a7314975
12 changed files with 160 additions and 2 deletions

View File

@@ -43,6 +43,12 @@ class PermissionsGroup
*/
private $name;
/**
*
* @var string[]
*/
private $flags = [];
/**
*
* @var \Doctrine\Common\Collections\Collection
@@ -109,6 +115,19 @@ class PermissionsGroup
}
}
public function getFlags()
{
return $this->flags;
}
public function setFlags(array $flags)
{
$this->flags = $flags;
return $this;
}
/**
* Test that a role scope is associated only once with the permission group
*