<?php

namespace App\Mail;

use Illuminate\Mail\Mailable;
use Illuminate\Queue\SerializesModels;
use App\Models\Setting;

class NewShipmentMail extends Mailable
{
    use SerializesModels;

    public $shipment;

    public function __construct($shipment)
    {
        $this->shipment = $shipment;
    }

    public function build()
    {
    return $this->markdown('emails.shipments.new')
                ->subject('New Shipment Created - ' . $this->shipment->tracking_number)
                ->with([
                    'siteName' => Setting::get('site_name', config('app.name')),
                    'siteUrl' => Setting::get('site_url', config('app.url')),
                ]);
    }
}