香洲二院小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
mini_xzey/app/Dictionary/Order/Status.php

35 lines
546 B

<?php
declare(strict_types=1);
namespace App\Dictionary\Order;
/**
* 订单状态
*/
enum Status: int
{
case NORMAL = 0;
case ABNORMAL = 1;
case SUCCESS = 2;
case REVERSE = 3;
case FAILURE = 4;
/**
* Label string
*/
public function label(): string
{
return match ($this) {
self::NORMAL => '初始',
self::ABNORMAL => '异常',
self::SUCCESS => '成功',
self::REVERSE => '冲正',
self::FAILURE => '失败'
};
}
}