package com.ltgk.common.enums;

/**
 * @Author: w1826
 * @Description: 抽检是不是通过
 * @Date: 2025/1/23 9:31
 * @Version: 1.0
 */
public enum FishCheckPass {
    //是不是通过抽检 0未检查  1通过 2未通过
    NO_CHECK(0, "未检查"),
    PASS(1, "通过"),
    NO_PASS(2, "未通过");
    private final Integer code;
    private final String message;

    FishCheckPass(Integer code, String message) {
        this.code = code;
        this.message = message;
    }

    public Integer getCode() {
        return code;
    }

    public String getMessage() {
        return message;
    }

    public static FishCheckPass getFishCheckPass(Integer code) {
        for (FishCheckPass fishCheckPass : FishCheckPass.values()) {
            if (fishCheckPass.getCode().equals(code)) {
                return fishCheckPass;
            }
        }
        return null;
    }
}
