Commit 3b95c5dd07157d04b44c2f78a382fcab5af6f172
Exists in
master
Merge branch 'master' of http://gitlab.nologostudio.ru/alarionov/rekamore-su
Showing 1 changed file Side-by-side Diff
app/Enums/WorkerStatuses.php
... | ... | @@ -25,11 +25,11 @@ enum WorkerStatuses: int |
25 | 25 | } |
26 | 26 | |
27 | 27 | public static function getWorkerStatuses(): array { |
28 | - $statuses_names = self::names(); | |
28 | + $statuses = self::cases(); | |
29 | 29 | |
30 | 30 | $result = []; |
31 | - foreach ($statuses_names as $status_name){ | |
32 | - $result[self::{$status_name}->value] = self::{$status_name}->label(); | |
31 | + foreach ($statuses as $status) { | |
32 | + $result[$status->value] = $status->label(); | |
33 | 33 | } |
34 | 34 | return $result; |
35 | 35 | } |