<?php

namespace App\Mail;

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

class SendEmailForCoverIssued extends Mailable
{
    use Queueable, SerializesModels;

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

    /**
     * Build the message.
     *
     * @return $this
     */
    public function build()
    {
        return $this->from('underwriting@tebreisainsurance.com', 'TEBREISA INSURANCE BROKERS LTD - Underwriting')
            ->replyTo('underwriting@tebreisainsurance.com', 'TEBREISA INSURANCE BROKERS LTD')
            ->subject($this->subject)
            ->view('emails.send-email-for-cover-issued-template');

    }
}
