46 lines
915 B
PHP
46 lines
915 B
PHP
<?php
|
|
|
|
namespace App\Enums;
|
|
|
|
use Kwaadpepper\Enum\BaseEnumRoutable;
|
|
|
|
/**
|
|
* @method static self waiting()
|
|
* @method static self failed()
|
|
* @method static self waitingCheck()
|
|
* @method static self sentCheck()
|
|
* @method static self payed()
|
|
*/
|
|
final class OrderStatus extends BaseEnumRoutable
|
|
{
|
|
/**
|
|
* Enum values
|
|
*
|
|
* @return array
|
|
*/
|
|
protected static function values(): array
|
|
{
|
|
return [
|
|
'waiting' => 0,
|
|
'failed' => 1,
|
|
'payed' => 2,
|
|
'waitingCheck' => 3,
|
|
'sentCheck' => 4
|
|
];
|
|
}
|
|
|
|
/**
|
|
* Enum labels
|
|
*
|
|
* @return array
|
|
*/
|
|
protected static function labels(): array
|
|
{
|
|
return [
|
|
'waiting' => __('En attente'),
|
|
'failed' => __('Échec'),
|
|
'payed' => __('Réglée'),
|
|
'sentCheck' => __('Par chèque bancaire')
|
|
];
|
|
}
|
|
}
|