package com.unis.crk.mq.constant;

/**
 * 业务类型
 *
 * @author ybw
 * @version V1.0
 * @className BizType
 * @date 2024/5/11
 **/
public enum BizType {
    //原粮入库
    YLRK("yuliang.rk"),
    //原粮出库
    YLCK("yuliang.ck"),
    //原粮库存变动
    KCBD("yuliang.kcbd");

    private String desc;

    BizType(String desc) {
        this.desc = desc;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }
    public static  BizType getBizTypeByDesc(String desc) {
        if ( YLRK.desc.equals(desc)){
            return YLRK;
        }
        if ( YLCK.desc.equals(desc)){
            return YLCK;
        }
        if ( KCBD.desc.equals(desc)){
            return KCBD;
        }
        return  null;
    }
}
