예제 #1
0
파일: User.php 프로젝트: avanthay/timekipr
 /**
  * Set email and, if there is no username set, set the email as username
  * @param string $email
  * @return $this|\FOS\UserBundle\Model\UserInterface
  */
 public function setEmail($email)
 {
     if (!$this->username) {
         $this->username = $email;
     }
     return parent::setEmail($email);
 }
예제 #2
0
 /**
  * override original setter, with set username with email.
  *
  * {@inheritDoc}
  *
  * @see \FOS\UserBundle\Model\User::setEmail()
  */
 public function setEmail($email)
 {
     parent::setEmail($email);
     $this->setUsername($email);
     return $this;
 }
예제 #3
0
 /**
  * Set email
  *
  * @param string $email
  * @return User
  */
 public function setEmail($email)
 {
     $email = is_null($email) ? '' : $email;
     parent::setEmail($email);
     if (!empty($email)) {
         $this->setUsername($email);
     }
     return $this;
 }
예제 #4
0
파일: User.php 프로젝트: amougel/cheerup
 /**
  * @param string $email
  *
  * @return $this
  */
 public function setEmail($email)
 {
     $email = is_null($email) ? '' : $email;
     parent::setEmail($email);
     $this->setUsername($email);
     return $this;
 }
예제 #5
0
파일: User.php 프로젝트: superskat/tracker
 public function setEmail($email)
 {
     parent::setEmail($email);
 }