phpvms/app/Mail/UserPending.php

29 lines
615 B
PHP
Raw Normal View History

<?php
namespace App\Mail;
use App\Models\User;
use Illuminate\Bus\Queueable;
2018-02-21 12:33:09 +08:00
use Illuminate\Mail\Mailable;
use Illuminate\Queue\SerializesModels;
class UserPending extends Mailable
{
use Queueable, SerializesModels;
2018-08-27 00:40:04 +08:00
public $subject;
public $user;
public function __construct(User $user, $subject = null)
{
$this->subject = $subject ?: 'Your registration is pending!';
$this->user = $user;
}
public function build()
{
return $this->markdown('emails.user.pending')
->subject($this->subject)
->with(['user' => $this->user]);
}
}