Exemplo n.º 1
0
 /**
  * Send a confirmation e-mail to the user if the account is not active
  */
 public function afterSave()
 {
     if ($this->active == 'N') {
         $emailConfirmation = new EmailConfirmations();
         $emailConfirmation->usersId = $this->id;
         if ($emailConfirmation->save()) {
             $this->getDI()->getFlash()->notice('A confirmation mail has been sent to ' . $this->email);
         }
     }
 }