<?php

namespace App\Mail;

use App\Models\Company;
use App\Models\Enums\ObjectAction;
use App\Models\Task;
use App\Models\User;
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;

class CompanyAction extends Mailable
{
    use Queueable, SerializesModels;

//    private $company;
//    private $user;

    /**
     * Create a new message instance.
     */
    public function __construct(public Company $company,public User $user,public string $rejectReason='')
    {
//        $this->company = $company;
//        $this->user = $user;
    }

    /**
     * Get the message envelope.
     */
    public function envelope(): Envelope
    {
        return new Envelope(
            subject: 'Notification of the results of the company you applied for on this system.',
        );
    }

    /**
     * Get the message content definition.
     */
    public function content(): Content
    {
        return new Content(
            //view: 'view.name',
            markdown: 'emails.actions.company',
//            with: [
//                'company' =>$this->company,
//                'user' =>$this->user,
//            ]
        );
    }

    /**
     * Get the attachments for the message.
     *
     * @return array<int, \Illuminate\Mail\Mailables\Attachment>
     */
    public function attachments(): array
    {
        return [];
    }
}