<?php

namespace App\Mail;

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

class CartaGeneral extends Mailable
{
    use Queueable, SerializesModels;

    private $info = [];

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

    /**
     * Build the message.
     *
     * @return $this
     */
    public function build()
    {
        return $this
            ->markdown('emails.carta.general', $this->info)
            ->subject('Carta Consulta 2 - Altosol')
            ->attachFromStorage('carta_consulta2_altosol.pdf', 'carta_consulta2_altosol.pdf', [
                'mime' => 'application/pdf'
            ]);


    }
}
