<?php

namespace App\Mail;

use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Mail\Mailable;
use Illuminate\Queue\SerializesModels;

class SendMailable extends Mailable
{
    use Queueable, SerializesModels;

    public $notif_data;

    /**
     * Create a new message instance.
     *
     * @return void
     */
    public function __construct($notif_data)
    {
       $this->notif_data = $notif_data;
    }

    /**
     * Build the message.
     *
     * @return $this
     */
    public function build()
    {
        return $this->view('mail')->with([
            'notif_data' => $this->notif_data
        ]);
    }
}
