add highlight report
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
namespace App\Enum;
|
||||
|
||||
enum ReportHighlight: int
|
||||
{
|
||||
case STANDARD = 0;
|
||||
case INFO = 1;
|
||||
case WARNING = 5;
|
||||
case DANGER = 10;
|
||||
|
||||
|
||||
public function borderColor(): string
|
||||
{
|
||||
return match ($this)
|
||||
{
|
||||
ReportHighlight::STANDARD => '',
|
||||
ReportHighlight::WARNING => 'warning',
|
||||
ReportHighlight::INFO => 'info',
|
||||
ReportHighlight::DANGER => 'danger',
|
||||
};
|
||||
}
|
||||
public function buttonLang(): string
|
||||
{
|
||||
return match ($this)
|
||||
{
|
||||
ReportHighlight::STANDARD => 'Brak',
|
||||
ReportHighlight::WARNING => 'Ostrzeżenie',
|
||||
ReportHighlight::INFO => 'Informacja',
|
||||
ReportHighlight::DANGER => 'Ważne',
|
||||
};
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user