<?php

namespace App\Mail;

use App\Models\Customer;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Mail\Mailable;
use Illuminate\Mail\Mailables\Content;
use Illuminate\Mail\Mailables\Envelope;
use Illuminate\Queue\SerializesModels;

/** Başvuru sırasında otomatik oluşturulan müşteri hesabının giriş bilgilerini iletir. */
class CustomerWelcomeMail extends Mailable implements ShouldQueue
{
    use Queueable, SerializesModels;

    public function __construct(public Customer $customer, public string $temporaryPassword)
    {
    }

    public function envelope(): Envelope
    {
        return new Envelope(subject: 'Kolay Abonelik Hesabınız Oluşturuldu');
    }

    public function content(): Content
    {
        return new Content(view: 'emails.customer-welcome');
    }
}
