php
use NotificationChannels\Mandrill\MandrillChannel;
use NotificationChannels\Mandrill\MandrillMessage;
use Illuminate\Notifications\Notification;
class TestNotification extends Notification
{
public function via($notifiable)
{
return [MandrillChannel::class];
}
public function toMandrill($notifiable)
{
return (new MandrillMessage())
->template('foo-bar', ['foo' => 'bar']);
}
}
php
/**
* Route notifications for the Mandrill channel.
*
* @return array
*/
public function routeNotificationForMandrill()
{
return [
'email' => $this->email,
'name' => $this->name
];
}
php
return (new MandrillMessage())
->subject('Test Subject')
->mergeLanguage('handlebars');
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.