mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
Fix icu message
This commit is contained in:
parent
f9a2d7f2d5
commit
f68deca992
@ -18,7 +18,8 @@ use Doctrine\Common\Collections\Collection;
|
|||||||
use Doctrine\Common\Collections\Criteria;
|
use Doctrine\Common\Collections\Criteria;
|
||||||
use Doctrine\Common\Collections\Selectable;
|
use Doctrine\Common\Collections\Selectable;
|
||||||
use Doctrine\ORM\Mapping as ORM;
|
use Doctrine\ORM\Mapping as ORM;
|
||||||
use libphonenumber\PhoneNumber;
|
use RuntimeException;
|
||||||
|
use Symfony\Component\Security\Core\User\PasswordAuthenticatedUserInterface;
|
||||||
use Symfony\Component\Security\Core\User\UserInterface;
|
use Symfony\Component\Security\Core\User\UserInterface;
|
||||||
use Symfony\Component\Serializer\Annotation as Serializer;
|
use Symfony\Component\Serializer\Annotation as Serializer;
|
||||||
use Symfony\Component\Validator\Context\ExecutionContextInterface;
|
use Symfony\Component\Validator\Context\ExecutionContextInterface;
|
||||||
@ -37,7 +38,7 @@ use Chill\MainBundle\Validation\Constraint\PhonenumberConstraint;
|
|||||||
* "user": User::class
|
* "user": User::class
|
||||||
* })
|
* })
|
||||||
*/
|
*/
|
||||||
class User implements UserInterface, \Stringable
|
class User implements UserInterface, \Stringable, PasswordAuthenticatedUserInterface
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* @ORM\Id
|
* @ORM\Id
|
||||||
@ -306,10 +307,7 @@ class User implements UserInterface, \Stringable
|
|||||||
return new ArrayCollection($sortedScopeHistories);
|
return new ArrayCollection($sortedScopeHistories);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
public function getPassword(): ?string
|
||||||
* @return string
|
|
||||||
*/
|
|
||||||
public function getPassword()
|
|
||||||
{
|
{
|
||||||
return $this->password;
|
return $this->password;
|
||||||
}
|
}
|
||||||
|
@ -19,38 +19,14 @@ use Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInt
|
|||||||
use Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface;
|
use Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface;
|
||||||
use Symfony\Contracts\Translation\TranslatorInterface;
|
use Symfony\Contracts\Translation\TranslatorInterface;
|
||||||
|
|
||||||
class UserMenuBuilder implements LocalMenuBuilderInterface
|
final readonly class UserMenuBuilder implements LocalMenuBuilderInterface
|
||||||
{
|
{
|
||||||
/**
|
|
||||||
* @var AuthorizationCheckerInterface
|
|
||||||
*/
|
|
||||||
public $authorizationChecker;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @var CountNotificationTask
|
|
||||||
*/
|
|
||||||
public $counter;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @var TokenStorageInterface
|
|
||||||
*/
|
|
||||||
public $tokenStorage;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @var TranslatorInterface
|
|
||||||
*/
|
|
||||||
public $translator;
|
|
||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
CountNotificationTask $counter,
|
private CountNotificationTask $counter,
|
||||||
TokenStorageInterface $tokenStorage,
|
private TokenStorageInterface $tokenStorage,
|
||||||
TranslatorInterface $translator,
|
private TranslatorInterface $translator,
|
||||||
AuthorizationCheckerInterface $authorizationChecker
|
private AuthorizationCheckerInterface $authorizationChecker
|
||||||
) {
|
) {
|
||||||
$this->counter = $counter;
|
|
||||||
$this->tokenStorage = $tokenStorage;
|
|
||||||
$this->translator = $translator;
|
|
||||||
$this->authorizationChecker = $authorizationChecker;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public function buildMenu($menuId, MenuItem $menu, array $parameters)
|
public function buildMenu($menuId, MenuItem $menu, array $parameters)
|
||||||
@ -99,7 +75,7 @@ class UserMenuBuilder implements LocalMenuBuilderInterface
|
|||||||
return ['user'];
|
return ['user'];
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function addItemInMenu(MenuItem $menu, $message, $number, $order, array $states = [], array $status = [])
|
private function addItemInMenu(MenuItem $menu, string $message, int $number, $order, array $states = [], array $status = [])
|
||||||
{
|
{
|
||||||
if (0 < $number) {
|
if (0 < $number) {
|
||||||
$menu->addChild(
|
$menu->addChild(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user