예제 #1
0
 public function load(ObjectManager $manager)
 {
     $userAdmin = new User();
     $userAdmin->setUsername('admin');
     $userAdmin->setSalt('pclt1nkvb6s440s04okw0gw4c00ocw8');
     $userAdmin->setPassword('$2y$13$pclt1nkvb6s440s04okw0eZ8/aYX1NZED7gdGAZjyS78jp3RgVAP6');
     $userAdmin->setEmail('*****@*****.**');
     $userAdmin->setLastname('Machin');
     $userAdmin->setFirstname('Toto');
     $userAdmin->setEnabled('1');
     $manager->persist($userAdmin);
     $manager->flush();
 }
 /**
  * {@inheritDoc}
  */
 public function setUsername($username)
 {
     $this->__initializer__ && $this->__initializer__->__invoke($this, 'setUsername', [$username]);
     return parent::setUsername($username);
 }