29 lines
685 B
PHP
29 lines
685 B
PHP
<?php
|
|
namespace App\Mail;
|
|
use Illuminate\Bus\Queueable;
|
|
use Illuminate\Mail\Mailable;
|
|
use Illuminate\Queue\SerializesModels;
|
|
class JobFailed extends Mailable
|
|
{
|
|
use Queueable, SerializesModels;
|
|
public $job;
|
|
public $exception;
|
|
/**
|
|
* Create a new message instance.
|
|
*
|
|
* @return void
|
|
*/
|
|
public function __construct($job, $exception)
|
|
{
|
|
$this->job = $job;
|
|
$this->exception = $exception;
|
|
}
|
|
/**
|
|
* Build the message.
|
|
*
|
|
* @return $this
|
|
*/
|
|
public function build() {
|
|
return $this->subject('[JOB FAILED] Une erreur est survenue pendant le job : ' . $this->job)->view('bo.mails.job-failed');
|
|
}
|
|
}
|