48 lines
1.2 KiB
PHP
48 lines
1.2 KiB
PHP
<?php
|
|
|
|
namespace App\Mail;
|
|
|
|
use Illuminate\Bus\Queueable;
|
|
use Illuminate\Mail\Mailable;
|
|
use Illuminate\Queue\SerializesModels;
|
|
|
|
class ReportEmail extends Mailable
|
|
{
|
|
use Queueable, SerializesModels;
|
|
|
|
protected $user;
|
|
protected $type;
|
|
protected $reportedFor;
|
|
protected $reportSubject;
|
|
protected $description;
|
|
|
|
/**
|
|
* ReportEmail constructor.
|
|
* @param $user
|
|
*/
|
|
public function __construct($user, $type, $reportedFor, $reportSubject, $description)
|
|
{
|
|
$this->user = $user;
|
|
$this->type = $type;
|
|
$this->reportedFor = $reportedFor;
|
|
$this->reportSubject = $reportSubject;
|
|
$this->description = $description;
|
|
$this->subject = trans('email.email_subject_label.report_request');
|
|
}
|
|
|
|
/**
|
|
* @return ReportEmail
|
|
*/
|
|
public function build()
|
|
{
|
|
return $this->view('frontend.mail.report')
|
|
->with([
|
|
'user' => $this->user,
|
|
'type' => $this->type,
|
|
'reportedFor' => $this->reportedFor,
|
|
'reportSubject' => $this->reportSubject,
|
|
'description' => $this->description
|
|
]);
|
|
}
|
|
}
|