1 | <?php |
||
2 | |||
3 | namespace App\Mail; |
||
4 | |||
5 | use App\Judite\Models\User; |
||
6 | use Illuminate\Bus\Queueable; |
||
7 | use Illuminate\Mail\Mailable; |
||
8 | use Illuminate\Queue\SerializesModels; |
||
9 | |||
10 | class RegistrationConfirmation extends Mailable |
||
11 | { |
||
12 | use Queueable, SerializesModels; |
||
0 ignored issues
–
show
introduced
by
![]() |
|||
13 | |||
14 | /** |
||
15 | * The user to be confirmed. |
||
16 | * |
||
17 | * @var string |
||
18 | */ |
||
19 | public $user; |
||
20 | |||
21 | /** |
||
22 | * Create a new message instance. |
||
23 | * |
||
24 | * @param \App\Judite\Models\User $user |
||
25 | */ |
||
26 | public function __construct(User $user) |
||
27 | { |
||
28 | $this->user = $user; |
||
29 | } |
||
30 | |||
31 | /** |
||
32 | * Build the message. |
||
33 | * |
||
34 | * @return $this |
||
35 | */ |
||
36 | public function build() |
||
37 | { |
||
38 | $name = $this->user->name; |
||
0 ignored issues
–
show
|
|||
39 | $token = $this->user->verification_token; |
||
0 ignored issues
–
show
|
|||
40 | $confirmationUrl = route('register.confirm', compact('token')); |
||
41 | |||
42 | return $this->markdown('emails.registrations.confirm', compact('name', 'confirmationUrl')); |
||
43 | } |
||
44 | } |
||
45 |