environnement complet autonome, révision complete de la méthode, ajout de configuration
Some checks failed
Cadoles/hydra-sql/pipeline/head There was a failure building this commit
Cadoles/hydra-sql/pipeline/pr-develop There was a failure building this commit

This commit is contained in:
2022-12-09 17:31:07 +01:00
parent b451566452
commit 6fc004a549
110 changed files with 1829 additions and 372 deletions

View File

@ -2,25 +2,27 @@
namespace App\Entity;
use App\Validator as AcmeAssert;
use Symfony\Component\Security\Core\User\UserInterface;
class User
class User implements UserInterface
{
private string $email;
/** @var array */
protected $attributes;
private string $login;
private string $password;
private string $rememberMe;
private bool $rememberMe;
public function getEmail(): ?string
public function __construct($login, $password, $attributes, $rememberMe = false)
{
return $this->email;
$this->password = $password;
$this->login = $login;
$this->attributes = $attributes;
$this->rememberMe = $rememberMe;
}
public function setEmail(string $email): self
public function getLogin(): ?string
{
$this->email = $email;
return $this;
return $this->login;
}
public function getPassword(): string
@ -28,22 +30,37 @@ class User
return $this->password;
}
public function setPassword(string $password): self
public function getAttributes(): array
{
$this->password = $password;
return $this;
return $this->attributes;
}
public function getRememberMe(): string
public function getRememberMe(): bool
{
return $this->rememberMe;
}
public function setRememberMe(bool $rememberMe): self
public function getRoles(): array
{
$this->rememberMe = $rememberMe;
return $this;
return ['ROLE_USER'];
}
}
public function getSalt(): ?string
{
return null;
}
public function eraseCredentials()
{
}
public function getUsername(): string
{
return $this->login;
}
public function getUserIdentifier(): string
{
return $this->login;
}
}