ldc-mesbr-app/app/Mail/AlertBr.php

43 lines
893 B
PHP
Raw Permalink Normal View History

2019-02-13 16:37:14 +01:00
<?php
namespace App\Mail;
use Illuminate\Bus\Queueable;
use Illuminate\Mail\Mailable;
use Illuminate\Queue\SerializesModels;
class AlertBr extends Mailable
{
2021-04-27 17:29:47 +02:00
use Queueable;
use SerializesModels;
public $couponSeuil;
2021-04-27 17:29:47 +02:00
public $couponDiffusion;
2021-04-27 17:29:47 +02:00
2019-02-27 15:52:13 +01:00
public $subject;
2019-02-27 15:42:44 +01:00
2019-02-13 16:37:14 +01:00
/**
* Create a new message instance.
*
* @return void
*/
2019-02-27 15:42:44 +01:00
public function __construct($couponSeuil, $couponDiffusion, $sitename)
2019-02-13 16:37:14 +01:00
{
2025-04-03 09:30:16 +02:00
$this->couponSeuil = $couponSeuil;
2019-02-20 16:26:32 +01:00
$this->couponDiffusion = $couponDiffusion;
2025-04-03 09:30:16 +02:00
$this->subject = 'Notification mes BR : ' . $sitename;
2019-02-13 16:37:14 +01:00
}
/**
* Build the message.
*
* @return $this
*/
public function build()
{
2019-02-27 15:52:13 +01:00
return $this->subject($this->subject)->view('mail.alert')->with(['couponSeuil' => $this->couponSeuil, 'couponDiffusion' => $this->couponDiffusion]);
2019-02-13 16:37:14 +01:00
}
}