Update Migration Input Update Praktik Budidaya
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
namespace App\Enums\PraktikBudidaya;
|
||||
|
||||
enum Bulan: string
|
||||
{
|
||||
case JANUARI = 'Januari';
|
||||
case FEBRUARI = 'Februari';
|
||||
case MARET = 'Maret';
|
||||
case APRIL = 'April';
|
||||
case MEI = 'Mei';
|
||||
case JUNI = 'Juni';
|
||||
case JULI = 'Juli';
|
||||
case AGUSTUS = 'Agustus';
|
||||
case SEPTEMBER = 'September';
|
||||
case OKTOBER = 'Oktober';
|
||||
case NOVEMBER = 'November';
|
||||
case DESEMBER = 'Desember';
|
||||
|
||||
public function label(): string
|
||||
{
|
||||
return $this->value;
|
||||
}
|
||||
|
||||
public static function options(): array
|
||||
{
|
||||
return collect(self::cases())->map(fn ($case) => [
|
||||
'value' => $case->value,
|
||||
'label' => $case->label(),
|
||||
])->toArray();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user