Files
bogazici-api/app/Enums/CourseBadge.php
2026-03-27 10:41:54 +03:00

24 lines
545 B
PHP
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?php
namespace App\Enums;
enum CourseBadge: string
{
case Popular = 'popular';
case MostPreferred = 'most_preferred';
case New = 'new';
case Recommended = 'recommended';
case Limited = 'limited';
public function label(): string
{
return match ($this) {
self::Popular => 'Popüler',
self::MostPreferred => 'En Çok Tercih Edilen',
self::New => 'Yeni',
self::Recommended => 'Önerilen',
self::Limited => 'Sınırlı Kontenjan',
};
}
}