package com.yingpaipay.business.enumeration;

import lombok.AccessLevel;
import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * @Author: Huanyi
 * @CreateTime: 2025-12-08
 * @Description:
 * @Version: 1.0
 */

@Getter
@AllArgsConstructor(access = AccessLevel.PRIVATE)
public enum ProjectStatusEnum {

    UNPLAYED(0, "未开始"),
    UNDERWAY(1, "进行中"),
    PAUSED(2, "暂停中"),
    FINISHED(3, "已完成"),
    ;

    private final Integer value;
    private final String label;

    public static String getLabel(Integer value) {
        for (ProjectStatusEnum status : values()) {
            if (value.equals(status.value)) {
                return status.label;
            }
        }
        throw new IllegalArgumentException("未知状态");
    }

}
