initial commit
This commit is contained in:
@@ -0,0 +1,38 @@
|
||||
<?php
|
||||
namespace App\Enum;
|
||||
|
||||
enum ReportTodoEnum: int {
|
||||
case SENT_EMAIL = 1;
|
||||
case MAKE_PHONE_CALL = 2;
|
||||
case INVOICE_SEND = 4;
|
||||
case COMPLETE = 3;
|
||||
|
||||
public function takeLang() : string
|
||||
{
|
||||
return match ($this) {
|
||||
self::SENT_EMAIL => "Wysłano E-Mail",
|
||||
self::MAKE_PHONE_CALL => "Wykonano połączenie",
|
||||
self::COMPLETE => "Zakończono",
|
||||
self::INVOICE_SEND => "Wysłano fakturę"
|
||||
};
|
||||
}
|
||||
|
||||
public function backgroundColor(): string
|
||||
{
|
||||
return match ($this) {
|
||||
self::SENT_EMAIL,self::MAKE_PHONE_CALL,self::INVOICE_SEND => "info",
|
||||
self::COMPLETE => "success",
|
||||
};
|
||||
}
|
||||
|
||||
public function takeIcon(): string
|
||||
{
|
||||
return match ($this) {
|
||||
self::SENT_EMAIL => "envelope",
|
||||
self::MAKE_PHONE_CALL => "phone",
|
||||
self::COMPLETE => "check",
|
||||
self::INVOICE_SEND => "file-invoice",
|
||||
};
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user