40 lines
784 B
PHP
40 lines
784 B
PHP
<?php
|
|
|
|
namespace App\Mail;
|
|
|
|
use Illuminate\Bus\Queueable;
|
|
use Illuminate\Mail\Mailable;
|
|
use Illuminate\Queue\SerializesModels;
|
|
|
|
class SendFlyerFailed extends Mailable
|
|
{
|
|
use Queueable;
|
|
use SerializesModels;
|
|
|
|
/** @var object */
|
|
private $data;
|
|
|
|
/**
|
|
* Create a new message instance.
|
|
*
|
|
* @param mixed $data
|
|
* @return void
|
|
*/
|
|
public function __construct($data)
|
|
{
|
|
$this->data = (object)$data;
|
|
}
|
|
|
|
/**
|
|
* Build the message.
|
|
*
|
|
* @return $this
|
|
*/
|
|
public function build()
|
|
{
|
|
return $this
|
|
->from('noreply@ldc.fr', '[APP] ' . config('app.name'))
|
|
->subject('[MAIL] Une erreur est survenue')
|
|
->view('bo.mails.sendflyerfailed', ['data' => $this->data]);
|
|
}
|
|
}
|