ldc-mesbr-app/app/Mail/AlertBr.php
Vincent BRIDIER f0c322c843 - Add API v1
- Add PHPCS
2021-04-27 17:29:47 +02:00

43 lines
925 B
PHP

<?php
namespace App\Mail;
use Illuminate\Bus\Queueable;
use Illuminate\Mail\Mailable;
use Illuminate\Queue\SerializesModels;
use Illuminate\Contracts\Queue\ShouldQueue;
class AlertBr extends Mailable
{
use Queueable;
use SerializesModels;
public $couponSeuil;
public $couponDiffusion;
public $subject;
/**
* Create a new message instance.
*
* @return void
*/
public function __construct($couponSeuil, $couponDiffusion, $sitename)
{
$this->couponSeuil = $couponSeuil;
$this->couponDiffusion = $couponDiffusion;
$this->subject = 'Notification mes BR : ' . $sitename;
}
/**
* Build the message.
*
* @return $this
*/
public function build()
{
return $this->subject($this->subject)->view('mail.alert')->with(['couponSeuil' => $this->couponSeuil, 'couponDiffusion' => $this->couponDiffusion]);
}
}