major update
This commit is contained in:
30
lib/Domain/Taxonomy/MailLogStatus.php
Normal file
30
lib/Domain/Taxonomy/MailLogStatus.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
namespace MintyPHP\Domain\Taxonomy;
|
||||
|
||||
enum MailLogStatus: string
|
||||
{
|
||||
use SupportsStringTaxonomy;
|
||||
|
||||
case Queued = 'queued';
|
||||
case Sent = 'sent';
|
||||
case Failed = 'failed';
|
||||
|
||||
public function labelToken(): string
|
||||
{
|
||||
return match ($this) {
|
||||
self::Queued => 'Queued',
|
||||
self::Sent => 'Sent',
|
||||
self::Failed => 'Failed',
|
||||
};
|
||||
}
|
||||
|
||||
public function badgeVariant(): string
|
||||
{
|
||||
return match ($this) {
|
||||
self::Queued => 'info',
|
||||
self::Sent => 'success',
|
||||
self::Failed => 'danger',
|
||||
};
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user