<?php

namespace Kylin\Community\Enums;

/**
 * 投诉建议状态
 */
enum ComplaintStatus: string
{
    case PENDING = 'pending';       // 待受理
    case ACCEPTED = 'accepted';     // 已受理
    case PROCESSING = 'processing'; // 处理中
    case REPLIED = 'replied';       // 已回复
    case CLOSED = 'closed';         // 已关闭
    case RATED = 'rated';           // 已评价

    public function label(): string
    {
        return match ($this) {
            self::PENDING => '待受理',
            self::ACCEPTED => '已受理',
            self::PROCESSING => '处理中',
            self::REPLIED => '已回复',
            self::CLOSED => '已关闭',
            self::RATED => '已评价',
        };
    }
}
