package com.yunfeiyun.agmp.common.enums;


public enum ChangeBizType {
    RECEIPTS_APPLY("IN_1","入库"),
    RETURN_APPLY("IN_2","归还"),
    PICK("IN_3","采收"),
    PROCESS("IN_4","加工"),
    PARK("IN_5","包装"),
    REQUISITION_APPLY("OUT_1","领用农资"),
    LOSSES_APPLY("OUT_2","报损"),
    APPLY_GOODS("OUT_3","申领用料"),
    SALE("OUT_4","销售"),

    ;


    private final String code;
    private final String message;

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

    public String getCode()
    {
        return code;
    }

    public String getMessage()
    {
        return message;
    }

    public static String valueOfCode(String code){
        for(ChangeBizType stockChangeBizType: ChangeBizType.values()) {
            if(stockChangeBizType.equal(code)){
                return stockChangeBizType.getMessage();
            }
        }
        return "";
    }

    public boolean equal(String code){
        return this.code.equals(code);
    }
}
