42 lines
1.2 KiB
PHP
42 lines
1.2 KiB
PHP
|
<?php
|
||
|
|
||
|
namespace App\Enums;
|
||
|
|
||
|
use Filament\Support\Contracts\HasIcon;
|
||
|
use Filament\Support\Contracts\HasLabel;
|
||
|
|
||
|
enum OrderAttributes: string implements HasIcon, HasLabel
|
||
|
{
|
||
|
case NEW_ART = 'New Art';
|
||
|
case REPEAT = 'Repeat';
|
||
|
case RUSH = 'Rush';
|
||
|
case EVENT = 'Event';
|
||
|
case DIGITIZING = 'Digitizing';
|
||
|
case GARMENTS = 'Garments';
|
||
|
case SUPPLIED_FILE = 'Customer Supplied File';
|
||
|
|
||
|
public function getLabel(): ?string
|
||
|
{
|
||
|
return $this->value;
|
||
|
}
|
||
|
|
||
|
// public function getColor(): string|array|null
|
||
|
// {
|
||
|
// return match ($this) {
|
||
|
// };
|
||
|
// }
|
||
|
|
||
|
public function getIcon(): ?string
|
||
|
{
|
||
|
return match ($this) {
|
||
|
self::NEW_ART => 'heroicon-o-paint-brush',
|
||
|
self::REPEAT => 'heroicon-o-clipboard-document',
|
||
|
self::RUSH => 'heroicon-o-clock',
|
||
|
self::EVENT => 'heroicon-o-users',
|
||
|
self::DIGITIZING => 'heroicon-o-computer-desktop',
|
||
|
self::GARMENTS => 'heroicon-o-shopping-bag',
|
||
|
self::SUPPLIED_FILE => 'heroicon-o-arrow-down-tray',
|
||
|
};
|
||
|
}
|
||
|
}
|