package com.crm.rely.backend.core.constant;

/**
 * 信号源计分周期类型
 *
 * @author y
 * @create 2022/1/21
 */
public enum FollowDealScorePeriodTypeEnum {


    ALL(1, "ALL"),
    WEEKLY(2, "WEEKLY"),

    MONTHLY(3, "MONTHLY");//开赛时未满足资金要求


    private final Integer code;
    private final String desc;

    FollowDealScorePeriodTypeEnum(Integer code, String desc) {
        this.code = code;
        this.desc = desc;
    }

    public Integer getCode() {
        return code;
    }

    public String getDesc() {
        return desc;
    }

    public static FollowDealScorePeriodTypeEnum matchCode(Integer code) {
        for (FollowDealScorePeriodTypeEnum type : FollowDealScorePeriodTypeEnum.values()) {
            if (type.getCode() == code) {
                return type;
            }
        }
        return null;
    }


}
