2023-07-13 08:34:54 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
|
|
namespace App\Mail;
|
|
|
|
|
|
|
|
|
|
use Illuminate\Bus\Queueable;
|
2025-09-24 11:27:55 +02:00
|
|
|
use Illuminate\Contracts\Queue\ShouldQueue;
|
2023-07-13 08:34:54 +00:00
|
|
|
use Illuminate\Mail\Mailable;
|
|
|
|
|
use Illuminate\Queue\SerializesModels;
|
|
|
|
|
|
2025-09-24 11:27:55 +02:00
|
|
|
class SendFlyerFailed extends Mailable implements ShouldQueue
|
2023-07-13 08:34:54 +00:00
|
|
|
{
|
|
|
|
|
use Queueable;
|
|
|
|
|
use SerializesModels;
|
|
|
|
|
|
|
|
|
|
/** @var object */
|
|
|
|
|
private $data;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Create a new message instance.
|
|
|
|
|
*
|
|
|
|
|
* @param mixed $data
|
|
|
|
|
* @return void
|
|
|
|
|
*/
|
2025-05-20 10:16:12 +02:00
|
|
|
public function __construct(mixed $data)
|
2023-07-13 08:34:54 +00:00
|
|
|
{
|
2025-05-20 10:16:12 +02:00
|
|
|
$this->data = (object) $data;
|
2023-07-13 08:34:54 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Build the message.
|
|
|
|
|
*
|
2025-05-20 10:16:12 +02:00
|
|
|
* @return mixed
|
2023-07-13 08:34:54 +00:00
|
|
|
*/
|
2025-05-20 10:16:12 +02:00
|
|
|
public function build(): mixed
|
2023-07-13 08:34:54 +00:00
|
|
|
{
|
|
|
|
|
return $this
|
|
|
|
|
->subject('[MAIL] Une erreur est survenue')
|
|
|
|
|
->view('bo.mails.sendflyerfailed', ['data' => $this->data]);
|
|
|
|
|
}
|
|
|
|
|
}
|