38 lines
840 B
PHP
38 lines
840 B
PHP
<?php
|
|
|
|
namespace App\Mail;
|
|
|
|
use Illuminate\Bus\Queueable;
|
|
use Illuminate\Contracts\Queue\ShouldQueue;
|
|
use Illuminate\Mail\Mailable;
|
|
use Illuminate\Queue\SerializesModels;
|
|
|
|
class TicketUpdate extends Mailable
|
|
{
|
|
use Queueable, SerializesModels;
|
|
|
|
private $ticket, $corpsMaj;
|
|
|
|
/**
|
|
* Create a new message instance.
|
|
*
|
|
* @return void
|
|
*/
|
|
public function __construct($ticket, $corpsMaj)
|
|
{
|
|
$this->ticket = $ticket;
|
|
$this->corpsMaj = $corpsMaj;
|
|
}
|
|
|
|
/**
|
|
* Build the message.
|
|
*
|
|
* @return $this
|
|
*/
|
|
public function build()
|
|
{
|
|
$ticket = $this->ticket;
|
|
$corpsMaj = $this->corpsMaj;
|
|
return $this->subject("[SupportWeb] Le ticket n°" . $ticket->id . " à été mis à jour")->view('mails.ticket-update', compact('ticket', 'corpsMaj'));
|
|
}
|
|
}
|