mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-13 13:54:23 +00:00
fix errors with Role type
This commit is contained in:
parent
1b8b99d5ce
commit
d9e602247e
@ -559,13 +559,13 @@ class ExportManager
|
|||||||
}
|
}
|
||||||
|
|
||||||
foreach ($centers as $center) {
|
foreach ($centers as $center) {
|
||||||
if ($this->authorizationChecker->isGranted($role->getRole(), $center) === false) {
|
if ($this->authorizationChecker->isGranted($role, $center) === false) {
|
||||||
//debugging
|
//debugging
|
||||||
$this->logger->debug('user has no access to element', [
|
$this->logger->debug('user has no access to element', [
|
||||||
'method' => __METHOD__,
|
'method' => __METHOD__,
|
||||||
'type' => get_class($element),
|
'type' => get_class($element),
|
||||||
'center' => $center->getName(),
|
'center' => $center->getName(),
|
||||||
'role' => $role->getRole(),
|
'role' => $role,
|
||||||
]);
|
]);
|
||||||
|
|
||||||
///// Bypasse les autorisations qui empêche d'afficher les nouveaux exports
|
///// Bypasse les autorisations qui empêche d'afficher les nouveaux exports
|
||||||
|
@ -64,7 +64,7 @@ final class GeographicalUnitStatAggregator implements AggregatorInterface
|
|||||||
/**
|
/**
|
||||||
* @inheritDoc
|
* @inheritDoc
|
||||||
*/
|
*/
|
||||||
public function addRole()
|
public function addRole(): ?string
|
||||||
{
|
{
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
@ -142,9 +142,9 @@ class ListPersonDuplicate implements DirectExportInterface, ExportElementValidat
|
|||||||
return 'List duplicates';
|
return 'List duplicates';
|
||||||
}
|
}
|
||||||
|
|
||||||
public function requiredRole(): Role
|
public function requiredRole(): string
|
||||||
{
|
{
|
||||||
return new Role(PersonVoter::DUPLICATE);
|
return PersonVoter::DUPLICATE;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function validateForm($data, ExecutionContextInterface $context)
|
public function validateForm($data, ExecutionContextInterface $context)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user