guild/common/models/email/ResetPasswordEmail.php
2023-10-18 16:26:49 +03:00

20 lines
470 B
PHP

<?php
namespace common\models\email;
use common\models\User;
use Yii;
class ResetPasswordEmail extends Email
{
/**
* @param User $user
*/
public function __construct(User $user)
{
$this->sendTo = $user->email;
$this->subject = 'Password reset for ' . Yii::$app->name;
$this->mailLayout = ['html' => 'passwordResetToken-html', 'text' => 'passwordResetToken-text']; //+
$this->params = ['user' => $user];//+
}
}