NNTmux /
newznab-tmux
| 1 | <?php |
||
| 2 | |||
| 3 | namespace App\Mail; |
||
| 4 | |||
| 5 | use Illuminate\Bus\Queueable; |
||
| 6 | use Illuminate\Mail\Mailable; |
||
| 7 | use Illuminate\Queue\SerializesModels; |
||
| 8 | |||
| 9 | class NewAccountCreatedEmail extends Mailable |
||
| 10 | { |
||
| 11 | use Queueable, SerializesModels; |
||
|
0 ignored issues
–
show
introduced
by
Loading history...
|
|||
| 12 | |||
| 13 | /** |
||
| 14 | * @var \App\Models\User |
||
| 15 | */ |
||
| 16 | private $user; |
||
| 17 | |||
| 18 | /** |
||
| 19 | * @var mixed |
||
| 20 | */ |
||
| 21 | private $siteEmail; |
||
| 22 | |||
| 23 | /** |
||
| 24 | * @var mixed |
||
| 25 | */ |
||
| 26 | private $siteTitle; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * Create a new message instance. |
||
| 30 | * |
||
| 31 | * @return void |
||
| 32 | */ |
||
| 33 | public function __construct($user) |
||
| 34 | { |
||
| 35 | $this->user = $user; |
||
| 36 | $this->siteEmail = config('mail.from.address'); |
||
| 37 | $this->siteTitle = config('app.name'); |
||
| 38 | } |
||
| 39 | |||
| 40 | /** |
||
| 41 | * Build the message. |
||
| 42 | */ |
||
| 43 | public function build(): static |
||
| 44 | { |
||
| 45 | return $this->from($this->siteEmail)->subject('New account registered')->view('emails.newAccountCreated')->with(['username' => $this->user->username, 'site' => $this->siteTitle]); |
||
| 46 | } |
||
| 47 | } |
||
| 48 |