feat: Implement client status validation on login, refine password rules, and simplify customer resource status.

This commit is contained in:
pbao9
2026-03-10 16:27:23 +07:00
parent cf0f2cf686
commit 7fdcc01027
18 changed files with 831 additions and 12 deletions
+51
View File
@@ -0,0 +1,51 @@
<?php
namespace App\Mail;
use App\Models\Invoice;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Database\Eloquent\Collection;
use Illuminate\Mail\Mailable;
use Illuminate\Mail\Mailables\Content;
use Illuminate\Mail\Mailables\Envelope;
use Illuminate\Queue\SerializesModels;
class InvoiceNotificationMail extends Mailable implements ShouldQueue
{
use Queueable, SerializesModels;
public function __construct(
public readonly Invoice $invoice,
public readonly Collection $attachments,
public readonly string $customerName,
public readonly string $message,
public readonly string $companyName,
) {}
public function envelope(): Envelope
{
return new Envelope(
subject: "Thông báo hóa đơn #{$this->invoice->order_num} - {$this->companyName}",
);
}
public function content(): Content
{
return new Content(
view: 'emails.invoice-notification',
with: [
'invoice' => $this->invoice,
'attachments' => $this->attachments,
'customerName' => $this->customerName,
'message' => $this->message,
'companyName' => $this->companyName,
]
);
}
public function attachments(): array
{
return [];
}
}