File: /mnt/data/ghayatcom/ghayatcom-api/app/Enums/LabOrderStatusEnum.php
<?php
namespace App\Enums;
use Spatie\Enum\Enum;
/**
* @method static self Pending()
* @method static self Accepted()
* @method static self SampleCollected()
* @method static self Completed()
* @method static self Rejected()
* @method static self PatientRequestFromLab()
* @method static self SampleCollectFromHome()
* @method static self SampleProvideToLab()
*/
class LabOrderStatusEnum extends Enum
{
protected static function values(): array
{
return [
'Pending' => 0,
'Accepted' => 1,
'SampleCollected' => 2,
'Completed' => 3,
'Rejected' => 4,
'PatientRequestFromLab' => 5,
'SampleCollectFromHome' => 6,
'SampleProvideToLab' => 7
];
}
protected static function labels(): array
{
return [
'Pending' => 'Pending',
'Accepted' => 'Accepted',
'SampleCollected' => 'Sample Collected',
'Completed' => 'Completed',
'Rejected' => 'Rejected',
'PatientRequestFromLab' => 'Patient Request From Lab',
'SamepleCollectFromHome' => 'Sameple Collect From Home',
'SampleProvideToLab' => 'Sample Provide To Lab'
];
}
/**
* Override dynamic calls to return the value instead of the enum instance.
*/
public static function __callStatic($name, $arguments)
{
$enum = parent::__callStatic($name, $arguments);
return (string)$enum->value;
}
}