Files
omg-wtf-ai/app/Enums/PostStatus.php
T

20 lines
353 B
PHP
Raw Normal View History

2026-08-08 18:03:29 +03:00
<?php
namespace App\Enums;
use Filament\Support\Contracts\HasLabel;
enum PostStatus: string implements HasLabel
{
case Draft = 'draft';
case Published = 'published';
public function getLabel(): string
{
return match ($this) {
self::Draft => 'Draft',
self::Published => 'Published',
};
}
}