2018-12-16 15:44:57 -05:00
|
|
|
<?php namespace BookStack\Notifications;
|
2016-09-17 13:22:04 -04:00
|
|
|
|
2018-12-16 15:44:57 -05:00
|
|
|
class ConfirmEmail extends MailNotification
|
2016-09-17 13:22:04 -04:00
|
|
|
{
|
|
|
|
public $token;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Create a new notification instance.
|
|
|
|
* @param string $token
|
|
|
|
*/
|
|
|
|
public function __construct($token)
|
|
|
|
{
|
|
|
|
$this->token = $token;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Get the mail representation of the notification.
|
|
|
|
*
|
|
|
|
* @param mixed $notifiable
|
|
|
|
* @return \Illuminate\Notifications\Messages\MailMessage
|
|
|
|
*/
|
|
|
|
public function toMail($notifiable)
|
|
|
|
{
|
2016-09-17 16:33:55 -04:00
|
|
|
$appName = ['appName' => setting('app-name')];
|
2018-12-16 15:44:57 -05:00
|
|
|
return $this->newMailMessage()
|
|
|
|
->subject(trans('auth.email_confirm_subject', $appName))
|
|
|
|
->greeting(trans('auth.email_confirm_greeting', $appName))
|
|
|
|
->line(trans('auth.email_confirm_text'))
|
|
|
|
->action(trans('auth.email_confirm_action'), baseUrl('/register/confirm/' . $this->token));
|
2016-09-17 13:22:04 -04:00
|
|
|
}
|
|
|
|
}
|