package cn.estsh.i3plus.pojo.base.enumutil;

import com.fasterxml.jackson.annotation.JsonFormat;

/**
 * @Description :
 * @Reference :
 * @Author : alwaysfrin
 * @CreateDate : 2018-10-23 15:53
 * @Modify:
 **/

public class MesEnumUtil {

    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PACKAGE_IS_SEALED {

        UNSEALED(1, "未封箱"),
        SEALED(2, "已封箱");

        private int value;
        private String description;

        PACKAGE_IS_SEALED(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MES_SPC关键数据
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum SPC_KEY_DATA_OBJECT_TYPE {
        POJO_OBJECT(10, "实体对象（单表）"),
        DYNAMIC(20, "动态对象（生产数据表）");

        private Integer value;
        private String description;

        SPC_KEY_DATA_OBJECT_TYPE(Integer value, String description) {
            this.value = value;
            this.description = description;
        }

        public static String valueOfDesc(String val) {
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    return values()[i].description;
                }
            }
            return null;
        }

        public Integer getValue() {
            return value;
        }

        public void setValue(Integer value) {
            this.value = value;
        }

        public String getDescription() {
            return description;
        }

        public void setDescription(String description) {
            this.description = description;
        }
    }

    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum HQL_EXPRESSION {
        GT(">", ">", "大于"),
        LT("<", "<", "小于"),
        EQ("=", "=", "等于"),
        NEQ("!=", "!=", "不等于"),
        GTE(">=", ">=", "大于等于"),
        LTE("<=", "<=", "小于等于"),
        LIKE("like", "like", "LIKE"),
        IN("in", "in", "包含");

        private String value;
        private String code;
        private String description;

        HQL_EXPRESSION(String value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public String getCode() {
            return code;
        }

        public static String valueOfDesc(String val) {
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    return values()[i].description;
                }
            }
            return null;
        }

        public static HQL_EXPRESSION codeOf(String value) {
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(value)) {
                    return values()[i];
                }
            }
            return null;
        }
    }

    /**
     * 作业程序组件类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WORK_MODULE_TYPE {
        MONITOR_MODULE(10, "MONITOR_MODULE", "监听组件"),
        REVEAL_MODULE(20, "REVEAL_MODULE", "展示组件"),
        BUTTON_MODULE(30, "BUTTON_MODULE", "按钮组件"),
        TIMING_MODULE(40, "TIMING_MODULE", "定时组件"),
        PCS_BACK_MODULE(50, "PCS_BACK_MODULE", "工序后台组件"),
        PLC_CALLBACK_MODULE(60, "PLC_CALLBACK_MODULE", "PLC回调工位参数"),
        ASSIST_MODULE(70, "ASSIST_MODULE", "辅助组件");

        private int value;
        private String data;
        private String description;

        WORK_MODULE_TYPE(int value, String data, String description) {
            this.value = value;
            this.data = data;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getData() {
            return data;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 启用还是禁用
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum IS_VALID {
        YES(1, "启用"),
        NO(2, "禁用");
        private Integer isValid;
        private String description;

        IS_VALID(int isValid, String description) {
            this.isValid = isValid;
            this.description = description;
        }

        public int getIsValid() {
            return isValid;
        }

        public void setIsValid(int isValid) {
            this.isValid = isValid;
        }

        public String getDescription() {
            return description;
        }

        public void setDescription(String description) {
            this.description = description;
        }
    }

    /**
     * 排序方式
     */
    public enum ASC_OR_DESC {
        ASC(1, "正序"), DESC(2, "倒序");

        private int value;
        private String description;

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        private ASC_OR_DESC(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public static String valueOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 监听任务明细-采集数据方式
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MONITOR_TASK_DETAIL_COLLECT_TYPE {
        SELF_ADDITION(10, "自增列"),
        FEED_FIELD(20, "反馈字段");

        private int value;
        private String description;

        MONITOR_TASK_DETAIL_COLLECT_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 动作-module
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_ACTION_MODULE {
        WORK_ORDER_LANDED(10, "生产工单下达"),
        QUEUE_JIT_ACTUAL_LANDED(20, "客户JIT生产工单下达"),
        MES_WORK_ORDER(30, "生产工单导入");

        private int value;
        private String description;

        MES_ACTION_MODULE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * JIS发运模式类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum JIS_PATTERN_TYPE {
        ONE_PROD(10, "单产品发运"),
        MANY_PROD(20, "多产品发运");

        private int value;
        private String description;

        JIS_PATTERN_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 排序校验模式
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum CHECK_PROD_SEQ_FLAG {
        PRODUCTION_MATERIAS(10, "NO_SORT_CHECK", "无排序校验"),
        CUSTOMER_SHPING(20, "QUEUE_BAR_CODE", "按产品队列条码校验排序"),
        OUTWARD_SHIPMENT(30, "PRODUCT_MATERIAL_NUMBER", "按产品物料号校验排序"),
        ALLOCATION(40, "SAME_MATERIAL_RACK", "按队列同料架单产品校验排序"),
        NO_CHECK_SN(50, "NO_CHECK_SN", "不校验条码");

        private int value;
        private String code;
        private String description;

        CHECK_PROD_SEQ_FLAG(int value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public String getCode() {
            return code;
        }

        public static String valueOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String codeOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].code;
                }
            }
            return tmp;
        }

        public static int descOf(String desc) {
            int tmp = 1;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(desc)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }

        public static String valueOfDescription(int val) {
            return valueOf(val);
        }
    }

    /**
     * 排序校验模式
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum TOOLING_ACTION_RECORD_TYPE {
        REPLACE(10, "REPLACE", "更换"),
        WAREHOUSE(20, "WAREHOUSE", "入库"),
        Use(30, "Use", "领用"),
        ERROR(40, "ERROR", "异常操作");

        private int value;
        private String code;
        private String description;

        TOOLING_ACTION_RECORD_TYPE(int value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public String getCode() {
            return code;
        }

        public static String valueOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String codeOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].code;
                }
            }
            return tmp;
        }

        public static int descOf(String desc) {
            int tmp = 1;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(desc)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }

        public static String valueOfDescription(int val) {
            return valueOf(val);
        }
    }

    /**
     * JIS发运是否按主队列顺序扫描
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_JIS_SCAN_TYPE {
        TRUE(10, "是"),
        FALSE(20, "否");

        private int value;
        private String description;

        MES_JIS_SCAN_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 是否解析
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PLC_IS_PARSE {
        TRUE(1, "是"),
        FALSE(2, "否");

        private int value;
        private String description;

        PLC_IS_PARSE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum CALENDAR_TYPE {
        DAY(10, "日"),
        WEEK(20, "周"),
        MONTH(30, "月"),
        YEAR(40, "年");

        private int value;
        private String description;

        CALENDAR_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * redis过期时间
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum EXPIRE_TIME {

        NEVER(-1, "不过期"),
        ONE_HOUR(3600, "一小时"),
        HALF_HOUR(1800, "半小时"),
        ONE_QUARTER(900, "一刻钟"),
        TEN_MIN(300, "十分钟"),
        ONE_MIN(60, "一分钟");

        private int value;
        private String description;

        EXPIRE_TIME(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum TRUE_OR_FALSE {
        TRUE(1, "是"),
        FALSE(2, "否");

        private int value;
        private String description;

        TRUE_OR_FALSE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 包装规格-是否混包 MES_PACK_SPEC
     * 10.
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_PACK_SPEC_IS_MIXED {

        TRUE(1, "是"),
        FALSE(2, "否");

        private int value;
        private String description;

        MES_PACK_SPEC_IS_MIXED(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * PCN同步MES主数据同步类型枚举
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum SYNC_TYPE {

        GET_MES_DATA(1, "pcn获取mes数据"),
        DATA_TO_MES(2, "pcn推送数据至mes");

        private int value;
        private String description;

        SYNC_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * PCN同步MES主数据同步方式枚举
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum SYNC_PATTERN {

        UPDATE(1, "修改或新增"),
        INSERT(2, "新增");

        private int value;
        private String description;

        SYNC_PATTERN(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }


    /**
     * MES_TYPE_CFG 类型信息
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_TYPE_CFG {

        DEFECT("DEFECT", "缺陷"),
        POLISHING("POLISHING", "抛光"),
        DISASSEMBLE("DISASSEMBLE", "拆解"),
        DEFECT_CAUSE("DEFECT_CAUSE", "缺陷原因"),
        REPAIR("REPAIR", "处理措施"),
        SCRAP("SCRAP", "报废原因"),
        QC_CHECK_STAND("QC_CHECK_STAND", "质量检测标准"),
        WC_CHECK("WC_CHECK", "开线检查项"),
        BOARD("BOARD", "看板类型"),
        EQU_DEFECT_CAUSE("EQU_DEFECT_CAUSE", "故障原因"),
        EQU_DEFECT_METHOD("EQU_DEFECT_METHOD", "故障处理措施"),
        EQU_DEFECT_PHENOMENON("EQU_DEFECT_PHENOMENON", "故障现象"),
        BH_PACKAGE_TYPE_VALUE("BH_PACKAGE_TYPE_VALUE", "B&H包装条码赋值样品类型值"),
        WO_TYPE("WO_TYPE", "客户JIT队列工单类型");

        private String value;
        private String description;

        MES_TYPE_CFG(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * RAW_PART_STATUS 原材料状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum RAW_PART_STATUS {

        READY(10, "待投料"),
        ALREADY(20, "已投料");

        private int value;
        private String description;

        RAW_PART_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 接口同步状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum IF_SYNC_STATUS {

        NO_SYNC(10, "未同步"),
        ALREADY_SYNC(20, "已同步"),
        FAIL_SYNC(30, "同步失败");

        private int value;
        private String description;

        IF_SYNC_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 包装层级 MES_PACKAGE
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PACKAGE_PACKLEVEL {

        FIRST(1, "第一层"),
        SECOND(2, "第二层"),
        THIRD(3, "第三层"),
        FOURTH(4, "第四层");

        private int value;
        private String description;

        PACKAGE_PACKLEVEL(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesIf  交互方式
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum IF_CONNECT_TYPE {

        DB("10", "DB"),
        WEBSERVICE("20", "webservice"),
        RESTFUL("30", "restful");

        private String value;
        private String description;

        IF_CONNECT_TYPE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * Mes  工厂初始化数据
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum ORGANIZATION_INIT_DATA {

        MES_CONFIG("MesConfig", "MES_CONFIG", "配置表"),
        MES_NUMBER_RULE("MesNumberRule", "MES_NUMBER_RULE", "编码规则表"),
        MES_STEP("MesStep", "MES_STEP", "工步"),
        MES_STEP_PARAM("MesStepParam", "MES_STEP_PARAM", "工步参数表"),
        MES_PCN_SYNC_CFG("MesPcnSyncCfg", "MES_PCN_SYNC_CFG", "同步配置"),
        MES_BUTTON_STATUS("MesButtonStatus", "MES_BUTTON_STATUS", "按钮状态配置表"),
        MES_WORK_CELL_PARAM("MesWorkCellParam", "MES_WORK_CELL_PARAM", "工作单元参数"),
        MES_EVENT("MesEvent", "MES_EVENT", "事件清单"),
        MES_METHOD("MesMethod", "MES_METHOD", "方法清单"),
        MES_ACTION("MesAction", "MES_ACTION", "动作"),
        MES_EVENT_ACTION("MesEventAction", "MES_EVENT_ACTION", "事件动作配置"),
        MES_ACTION_METHOD("MesActionMethod", "MES_ACTION_METHOD", "动作方法配置");

        private String value;
        private String code;
        private String description;

        ORGANIZATION_INIT_DATA(String value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getCode() {
            return code;
        }

        public String getDescription() {
            return description;
        }

        public static ORGANIZATION_INIT_DATA getByValue(String value) {
            for (ORGANIZATION_INIT_DATA organizationInitData : values()) {
                if (organizationInitData.getValue().equals(value)) {
                    return organizationInitData;
                }
            }
            return null;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * Mes  对象结构是否保存
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum OBJECT_CFG_IS_SAVE {

        SAVE(1, "存储"),
        NO_SAVE(2, "不存储");

        private int value;
        private String description;

        OBJECT_CFG_IS_SAVE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * Mes  对象结构是否展示
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum OBJECT_CFG_IS_SHOW {

        SHOW(1, "是"),
        NO_SHOW(2, "否");

        private int value;
        private String description;

        OBJECT_CFG_IS_SHOW(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * Mes  客户订单来源
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum CUST_ORDER_SOURCE {

        MES("MES", "来源于MES"),
        SAP("SAP", "来源于SAP");

        private String value;
        private String description;

        CUST_ORDER_SOURCE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesCustOrder 订单类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum CUST_ORDER_TYPE {

        STANDARD(10, "标准");

        private int value;
        private String description;

        CUST_ORDER_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesCustOrder实体对应的status值   状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum CUST_ORDER_STATUS {

        CREATE(10, "CREATED", "创建"),
        DEAL(20, "DEAL", "已处理"),
        CLOSE(30, "CLOSE", "关闭");

        private int value;
        private String code;
        private String description;

        CUST_ORDER_STATUS(int value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getCode() {
            return code;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesProductEncodeCfg 匹配类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_MATCH_TYPE {

        ORGANIZATION(10, "工厂"),
        PART(20, "物料"),
        CUST_CODE(30, "客户代码"),
        CUST_PART_NO(40, "客户物料号"),
        WORK_CENTER(50, "产线");

        private int value;
        private String description;

        MES_MATCH_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String valueOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * MesProductEncodeCfg 编码类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_CODE_TYPE {

        SERIAL_SN(10, "过程条码"),
        PRODUCT_SN(20, "产品条码"),
        PACK_SN(30, "包装条码");

        private int value;
        private String description;

        MES_CODE_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * MesDatasource 数据源类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_DB_SOURCE_TYPE {

        SOURCE_MARIA_DB("SOURCE_MARIA_DB", "MariaDB"),
        SOURCE_SQL_SERVER("SOURCE_SQL_SERVER", "SQL Server"),
        SOURCE_ORACLE("SOURCE_ORACLE", "Oracle"),
        SOURCE_POSTGRE_SQL("SOURCE_POSTGRE_SQL", "PostgreSql");

        private String value;
        private String description;

        MES_DB_SOURCE_TYPE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * Mes 数据对象操作类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_DATA_OPERATE_TYPE {

        INSERT(10, "insert"),
        SELECT(20, "select"),
        UPDATE(30, "update");

        private int value;
        private String description;

        MES_DATA_OPERATE_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * MesRepair 处理措施
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_REPAIR_TYPE {

        SCRATCH(10, "划痕"),
        FRACTURE(20, "破碎"),
        SCRAP_TYPE(30, "缺失");

        private int value;
        private String description;

        MES_REPAIR_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 设备台账报表查询标识
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum EQUIPMENT_REPORT_TYPE {

        TASK(10, "作业任务"),
        PLAN(20, "周期计划"),
        REPAIR(30, "维修记录"),
        CHECK(40, "点检记录"),
        MAINTAIN(50, "保养记录");

        private int value;
        private String description;

        EQUIPMENT_REPORT_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesScrap 报废原因
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum SCRAP_TYPE {

        SCRAP_TYPE(10, "过期"),
        SCRAP_TYPE2(20, "不合格"),
        SCRAP_TYPE3(30, "缺失");

        private int value;
        private String description;

        SCRAP_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 条码类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_PRODUCE_SN_TYPE {

        NORMAL(10, "正常件"),
        FIRST_INSPECTION(20, "首检件"),
        HALF_PRODUCT(30, "半成品"),
        KP(40, "关键件");

        private int value;
        private String description;

        MES_PRODUCE_SN_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * mes 图片面位
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_SIDE_LOCATION {

        A_SIDE(10, "A面"),
        B_SIDE(20, "B面"),
        C_SIDE(30, "C面"),
        D_SIDE(40, "D面");

        private int value;
        private String description;

        MES_SIDE_LOCATION(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes缺陷类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_DEFECT_TYPE {

        DEFECT_TYPE1(10, "缺陷类型1"),
        DEFECT_TYPE2(20, "缺陷类型2"),
        DEFECT_TYPE3(30, "缺陷类型3");

        private int value;
        private String description;

        MES_DEFECT_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes类型信息，业务类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_TYPE_CFG_BUSIN_TYPE {

        BUSIN_TYPE1(10, "业务类型1"),
        BUSIN_TYPE2(20, "业务类型2"),
        BUSIN_TYPE3(30, "业务类型3");

        private int value;
        private String description;

        MES_TYPE_CFG_BUSIN_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes缺陷原因类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_DEFECT_CAUSE_TYPE {

        QUALITY_DEFECTS(10, "质量缺陷"),
        PROCESS_DEFECTS(20, "工艺缺陷"),
        EQUIPMENT_DEFECT(30, "设备缺陷");

        private int value;
        private String description;

        MES_DEFECT_CAUSE_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes设备作业任务明细-执行状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EQU_TASK_DETAIL_ACTION_STATUS {

        PENDING(10, "待处理"),
        COMPLETE(20, "已完成"),
        CANCEL(30, "取消");

        private int value;
        private String description;

        MES_EQU_TASK_DETAIL_ACTION_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes设备作业任务明细-判定结果
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EQU_TASK_DETAIL_CHECK_RESULT {

        YES(10, "合格"),
        NO(20, "不合格");

        private int value;
        private String description;

        MES_EQU_TASK_DETAIL_CHECK_RESULT(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes设备作业任务明细-整体结果
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EQU_TASK_DETAIL_FINAL_RESULT {

        YES(10, "合格"),
        NO(20, "不合格");

        private int value;
        private String description;

        MES_EQU_TASK_DETAIL_FINAL_RESULT(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes设备作业任务明细-维修标识
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EQU_TASK_DETAIL_REPAIR_FLAG {

        FALSE(10, "否"),
        TRUE(20, "是");

        private int value;
        private String description;

        MES_EQU_TASK_DETAIL_REPAIR_FLAG(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes设备作业状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EQU_TASK_STATUS {

        CREATE(10, "创建"),
        LANDED(20, "下达"),
        OPEN(30, "开启"),
        CLOSE(40, "关闭"),
        CANCEL(50, "取消");

        private int value;
        private String description;

        MES_EQU_TASK_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes设备作业任务来源
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EQU_TASK_SOURCE {

        PLAN(10, "周期计划"),
        CREATE(20, "手工创建"),
        ANDON(30, "ANDON");

        private int value;
        private String description;

        MES_EQU_TASK_SOURCE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes设备作业通知标识
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EQU_TASK_NOTIFY_FLAG {

        FALSE(10, "未通知"),
        TRUE(20, "已通知");

        private int value;
        private String description;

        MES_EQU_TASK_NOTIFY_FLAG(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes导入模块
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EXCEL {

        MES_PLAN_ORDER(10, "planOrderExcelService", "生产计划"),
        MES_EQUIPMENT(20, "equipmentExcelService", "设备台账，支持编辑"),
        MES_EQU_TASK_STANDARD(30, "equTaskStandardExcelService", "设备作业要求，支持编辑"),
        MES_CUST_ORDER(40, "custOrderExcelService", "客户订单"),
        MES_PCN_SYNC_CFG(50, "pcnSyncCfgExcelService", "PCN同步配置"),
        MES_PART(60, "partExcelService", "物料表，支持编辑"),
        MES_PRODUCE_CATEGORY(70, "produceCategoryExcelService", "产品类型"),
        MES_PACK_SPEC(80, "packSpecExcelService", "包装规格，支持编辑"),
        MES_PROD_PACK(90, "prodPackExcelService", "产品包装关系"),
        MES_PRODUCT_ENCODE_CFG(100, "productEncodeCfgExcelService", "产品编码配置"),
        MES_BOM(110, "bomExcelService", "物料清单，支持编辑"),
        MES_PROD_CFG_TYPE(120, "prodCfgTypeExcelService", "产品配置类型"),
        MES_CUSTOMER(130, "customerExcelService", "客户表，支持编辑"),
        MES_CUSTOMER_PART(140, "customerPartExcelService", "客户零件关系表，支持编辑"),
        MES_WORK_CENTER(150, "workCenterExcelService", "生产线，支持编辑"),
        MES_WORK_CELL(160, "workCellExcelService", "工位，支持编辑"),
        MES_WC_EQUIPMENT(170, "wcEquipmentExcelService", "工位设备关系表"),
        MES_SHIFT(180, "shiftExcelService", "班次，支持编辑"),
        MES_SHIFT_GROUP(190, "shiftGroupExcelService", "班组，支持编辑"),
        MES_WORK_CELL_PARAM_CFG(200, "workCellParamCfgExcelService", "工作单元参数配置"),
        MES_STATION_BOM(210, "stationBomExcelService", "工位BOM表"),
        MES_DATA_OBJECT(220, "dataObjectExcelService", "数据对象"),
        MES_OBJECT_CFG(230, "objectCfgExcelService", "对象结构"),
        MES_WC_CHECK(240, "wcCheckExcelService", "开线检查，支持编辑"),
        MES_QC_CHECK_STANDARD(250, "qcCheckStandardExcelService", "质量检测标准，支持编辑"),
        MES_FAULT_CAUSE(260, "faultCauseExcelService", "设备故障原因，支持编辑"),
        MES_FAULT_METHOD(270, "faultMethodExcelService", "设备故障处理措施，支持编辑"),
        MES_FAULT_PHENOMENON(280, "faultPhenomenonExcelService", "设备故障现象，支持编辑"),
        MES_DEFECT(290, "defectExcelService", "缺陷，支持编辑"),
        MES_DEFECT_CAUSE(300, "defectCauseExcelService", "缺陷原因，支持编辑"),
        MES_SCRAP(310, "scrapExcelService", "报废原因，支持编辑"),
        MES_REPAIR(320, "repairExcelService", "质量数据处理措施，支持编辑"),
        MES_EQU_TASK_PLAN(330, "equTaskPlanExcelService", "设备作业周期计划，支持编辑"),
        MES_PART_OJBECT(340, "partObjectExcelService", "物料对象"),
        MES_ROUTE_PROCESS_WORK_CELL(350, "routeProcessWorkCellExcelService", "工序工作单元"),
        MES_DATASOURCE(360, "datasourceExcelService", "DB地址清单"),
        MES_EQU_TASK_NOTIFY_CFG(370, "equTaskNotifyCfgExcelService", "设备通知配置"),
        MES_EQU_NOTIFY_OBJECT_CFG(380, "equNotifyObjectCfgExcelService", "设备通知对象"),
        MES_PLC(390, "plcExcelService", "PLC地址清单，支持编辑"),
        MES_PROCESS(400, "processExcelService", "工序信息"),
        MES_KPSN_RULE(410, "kpsnRuleExcelService", "关键件条码校验规则，支持编辑"),
        MES_QUEUE_JIT_ACTUAL(420, "queueJitActualExcelService", "客户JIT生产队列"),
        MES_PART_BOM_IMPORT(430, "partBomExcelService", "散件BOM导入"),
        MES_PLAN_ORDER_BATCH_COMPILE(440, "planOrderBatchCompileExcelService", "生产计划批量编制，支持编辑"),
        MES_WORK_ORDER_PAINT(450, "workOrderPaintExcelService", "生产工单-涂装"),
        NEW_SCATTER_BOM(460, "scatterBomCfgExcelService", "新散件BOM导入"),
        ENCODE_RULE_MAP(470, "mesEncodeRuleMapExcelService", "编码规则映射导入"),
        SCATTER_PART_PROD_CFG(480, "scatterPartProdCfgExcelService", "散件零件生产配置"),
        MES_WORK_ORDER_PAINT_ZS(490, "planZSOrderExcelService", "生产工单-注塑"),
        MES_KP_DATA(500, "kpDataExcelService", "物料关键数据关系"),
        BLIND_CHECK_RULE(510, "blindCheckRuleExcelService", "盲检规则导入"),
        BOARD_PLAN_CAPACITY(520, "boardPlanCapacityExcelService", "计划产能看板导入"),
        MES_PROD_WORK_CENTER(530, "prodWorkCenterExcelService", "产品工作中心配置导入"),
        MES_PART_COLOR(540, "partColorExcelService", "产品颜色导入"),
        MES_PART_STOCK_SCHEDULE(550, "partStockScheduleExcelService", "库存排程配置导入"),
        MES_PROD_CFG_DETAIL(560, "prodCfgDetailExcelService", "产品配置明细导入"),
        MES_LOCATION(570, "locationExcelService", "库位信息导入"),
        MES_SUB_PART(580, "mesSubPartExcelService", "替代料导入"),
        MES_WORK_CELL_DEFECT(590, "workCellDefectExcelService", "工位缺陷信息导入"),
        MES_MODEL_GRADE(600, "modelGradeExcelService", "车型等级导入"),
        MES_PROD_MODEL_CFG(610, "prodModelCfgExcelService", "产品车型配置导入"),
        MES_SCATTER_PART_CFG_BOM(620, "scatterPartCfgBomExcelService", "车型散件配置清单导入"),
        MES_SPARE_PARTS(630, "sparePartsExcelService", "备件计划导入"),
        MES_JISA(640, "jisaExcelService", "JISA导入");

        private int value;
        private String service;
        private String description;

        MES_EXCEL(int value, String service, String description) {
            this.value = value;
            this.service = service;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getService() {
            return service;
        }

        public String getDescription() {
            return description;
        }

        public static MES_EXCEL getByValue(int value) {
            for (MES_EXCEL excel : values()) {
                if (excel.getValue() == value) {
                    return excel;
                }
            }
            return null;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String valueOfService(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].service;
                }
            }
            return tmp;
        }

    }

    /**
     * mes设备作业通知配置-通知类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EQU_TASK_NOTIFY_CFG_TYPE {

        TASK_NOTIFY(10, "任务型通知");

        private int value;
        private String description;

        MES_EQU_TASK_NOTIFY_CFG_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes通知配置-通知方式
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum NOTIFY_CFG_PATTERN {

        EMAIL(10, "邮件");
//        USERPHONE(20, "手机号");

        private int value;
        private String description;

        NOTIFY_CFG_PATTERN(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes设备通知对象配置-对象类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EQU_NOTIFY_OBJECT_CFG_TYPE {

        CHECK_NOTIFY_OBJECT(10, "点检通知对象"),
        MAINTAIN_NOTIFY_OBJECT(20, "保养通知对象"),
        REPAIR_NOTIFY_OBJECT(30, "维修通知对象");

        private int value;
        private String description;

        MES_EQU_NOTIFY_OBJECT_CFG_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes 工位Bom  是否可重复
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_STATION_BOM_IS_REPEAT {

        REPEATABLE(1, "是"),
        NOT_REPEAT(2, "否");

        private int value;
        private String description;

        MES_STATION_BOM_IS_REPEAT(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static MES_STATION_BOM_IS_REPEAT getByValue(int value) {
            for (MES_STATION_BOM_IS_REPEAT mesInsertExcel : values()) {
                if (mesInsertExcel.getValue() == value) {
                    return mesInsertExcel;
                }
            }
            return null;
        }


        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }

    }

    /**
     * mes 工位Bom  是否检查
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_STATION_BOM_IS_CHECK {

        REPEATABLE(1, "是"),
        NOT_REPEAT(2, "否");

        private int value;
        private String description;

        MES_STATION_BOM_IS_CHECK(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }

    }

    /**
     * mes 工位Bom  是否投料配置
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_STATION_BOM_IS_FEED {

        REPEATABLE(1, "是"),
        NOT_REPEAT(2, "否");

        private int value;
        private String description;

        MES_STATION_BOM_IS_FEED(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }

    }

    /**
     * mes 工位Bom  是否绑定关键件
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_STATION_BOM_IS_BIND_KEY {

        REPEATABLE(1, "是"),
        NOT_REPEAT(2, "否");

        private int value;
        private String description;

        MES_STATION_BOM_IS_BIND_KEY(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }

    }

    /**
     * mes 工位类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_WORK_CELL_TYPE {

        NORMAL(10, "正常"),
        REWORK(20, "返修"),
        ON_LINE(30, "上线工位"),
        QUALITY_CHECK(40, "质检工位");

        private int value;
        private String description;

        MES_WORK_CELL_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static MES_WORK_CELL_TYPE getByValue(int value) {
            for (MES_WORK_CELL_TYPE mesInsertExcel : values()) {
                if (mesInsertExcel.getValue() == value) {
                    return mesInsertExcel;
                }
            }
            return null;
        }


        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }

    }

    /**
     * MesProdBindRecord 动作类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_ACTION_TYPE {

        BIND(10, "绑定"),
        UNTYING(20, "解绑");

        private int value;
        private String description;

        MES_ACTION_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static MES_ACTION_TYPE getByValue(int value) {
            for (MES_ACTION_TYPE mesInsertExcel : values()) {
                if (mesInsertExcel.getValue() == value) {
                    return mesInsertExcel;
                }
            }
            return null;
        }


        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * pcn 是否是关键件
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_IS_BIND_KEY {

        IS_BIND_KEY(1, "是"),
        NO_BIND_KEY(2, "否");

        private int value;
        private String description;

        MES_IS_BIND_KEY(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static MES_IS_BIND_KEY getByValue(int value) {
            for (MES_IS_BIND_KEY mesInsertExcel : values()) {
                if (mesInsertExcel.getValue() == value) {
                    return mesInsertExcel;
                }
            }
            return null;
        }


        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes 维修状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_REPAIR_STATUS {

        REPAIRED(10, "已维修"),
        NO_REPAIR(20, "待维修");

        private int value;
        private String description;

        MES_REPAIR_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static MES_REPAIR_STATUS getByValue(int value) {
            for (MES_REPAIR_STATUS mesInsertExcel : values()) {
                if (mesInsertExcel.getValue() == value) {
                    return mesInsertExcel;
                }
            }
            return null;
        }


        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes 操作类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_OPERATE_TYPE {

        WORKSTATION_SCAN(10, "工位扫描"),
        QUALITY_JUDGEMENT(20, "质量判定"),
        MATERIAL_DISMANTLING(30, "物料拆解"),
        REWORK(40, "返修作业"),
        WORKSTATION_MONITORING(50, "工位监控");

        private int value;
        private String description;

        MES_OPERATE_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static MES_OPERATE_TYPE getByValue(int value) {
            for (MES_OPERATE_TYPE mesInsertExcel : values()) {
                if (mesInsertExcel.getValue() == value) {
                    return mesInsertExcel;
                }
            }
            return null;
        }


        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * mes设备作业要求-作业类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EQU_TASK_TYPE {

        CHECK(10, "点检"),
        MAINTAIN(20, "保养"),
        REPAIR(30, "维修");

        private int value;
        private String description;

        MES_EQU_TASK_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * mes过程质量检测类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_QC_CHECK_TYPE {
        INCOMING_CHECK(5, "INCOMING_CHECK", "来料检验"),
        FIRST_CHECK(10, "FIRST_CHECK", "首检"),
        ON_SITE_CHECK(20, "ON_SITE_CHECK", "巡检"),
        END_CHECK(30, "END_CHECK", "末检"),
        RC_CHECK(40, "RC_CHECK", "发货检验");

        private int value;
        private String code;
        private String description;

        MES_QC_CHECK_TYPE(int value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getCode() {
            return code;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * mes设备类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EQUIPMENT_TYPE {

        PHYSICAL(10, "物理设备"),
        LOGIC(20, "逻辑设备");

        private int value;
        private String description;

        MES_EQUIPMENT_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * mes设备连接类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EQUIPMENT_CONNECT_TYPE {

        PLC(10, "PLC"),
        DB(20, "DB"),
        OTHER(30, "其他");

        private int value;
        private String description;

        MES_EQUIPMENT_CONNECT_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * mes设备状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EQUIPMENT_STATUS {

        INUSE(10, "在用"),
        SPARE(20, "备用"),
        FAULT(30, "故障"),
        SERVICE(40, "检修"),
        STOPUSING(50, "停用");

        private int value;
        private String description;

        MES_EQUIPMENT_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * mes设备类别
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_EQUIPMENT_CATEGORY {

        A("A", "A"),
        B("B", "B"),
        C("C", "C"),
        D("D", "D");

        private String value;
        private String description;

        MES_EQUIPMENT_CATEGORY(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String descriptionOfValue(String description) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * MesWorkOrder实体对应的approvalStatus值  审批状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WORK_ORDER_APPROVAL_STATUS {

        WAIT_APPROVAL(10, "待审批"),
        COMPLETE_APPROVAL(20, "已审批"),
        REJECT_APPROVAL(30, "驳回");

        private int value;
        private String description;

        WORK_ORDER_APPROVAL_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String valueOfDescription2(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description.equals("已审批") ? "审批" : values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * mes-pcn定时任务状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_PCN_TASK_STATUS {

        OPEN(1, "开启"),
        CLOSE(2, "关闭");

        private int value;
        private String description;

        MES_PCN_TASK_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * mes工步类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_STEP_TYPE {

        COMMON_STEP("10", "公用工步"),
        JIT_STEP("20", "JIT工步"),
        WORK_ORDER_STEP("30", "工单工步"),
        BACK_STEP("40", "后台工步");

        private String value;
        private String description;

        MES_STEP_TYPE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * mes工作单元参数类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_WORK_CELL_PARAM_TYPE {

        NUMBER(10, "数值"),
        STRING(20, "字符串");

        private int value;
        private String description;

        MES_WORK_CELL_PARAM_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * mes工作单元参数模式
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_WORK_CELL_PARAM_MODEL {

        PUBLIC(10, "公用"),
        JIT(20, "JIT生产"),
        WORK_ORDER(30, "工单生产"),
        JIS(40, "JIS发运"),
        OTHER(99, "其他");

        private int value;
        private String description;

        MES_WORK_CELL_PARAM_MODEL(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * mes条码生成规则最大值后是否循环
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum NUMBER_RULE_ISCYCLE {

        TRUE(1, "是"),
        FALSE(2, "否");

        private int value;
        private String description;

        NUMBER_RULE_ISCYCLE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 关键件条码规则信息绑定规则
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum BIND_RULE {

        COOPERATION_PART(0, "外协件"),
        SELF_CONTROL_PART(1, "自制件");

        private int value;
        private String description;

        BIND_RULE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 质量状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PASS_FAIL {

        PASS(1, "合格"),
        FAIL(2, "不合格");

        private int value;
        private String description;

        PASS_FAIL(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesMethod实体对应的methodType值
     * 10.
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum METHOD_TYPE {

        EXEC(10, "执行方法"),
        COMPLETE(20, "完成方法"),
        HNC_ISSUED(30, "队列自动下达"),
        LABEL_PROPERTIES(40, "标签属性查询方法");

        private int value;
        private String description;

        METHOD_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesPlanOrder实体对应的status值   计划状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PLAN_ORDER_STATUS {

        CREATE(10, "CREATED", "创建"),
        DE_COMPOSE_ING(20, "DE_COMPOSE_ING", "分解中"),
        DE_COMPOSE_ED(30, "DE_COMPOSE_ED", "分解完成"),
        CLOSE(40, "CLOSE", "关闭");

        private int value;
        private String code;
        private String description;

        PLAN_ORDER_STATUS(int value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getCode() {
            return code;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesWorkOrder实体对应的workOrderStatus值  工单状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WORK_ORDER_STATUS {

        CREATE(10, "创建"),
        LANDED(20, "下达"),
        OPEN(30, "启动"),
        PAUSE(40, "暂停"),
        CANCEL(50, "取消"),
        CLOSE(60, "关闭"),
        COMPLETE(70, "完成");

        private int value;
        private String description;

        WORK_ORDER_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesWorkOrder实体对应的workOrderType值  工单类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WORK_ORDER_TYPE {

        STANDARD_ORDER(10, "标准工单"),
        BTS_ORDER(20, "BTS工单"),
        ATTEMPT_ORDER(30, "试制工单"),
        BH_ORDER(40, "B&H工单"),
        JIT_ORDER(50, "JIT工单"),
        STOCK_ORDER(60, "库存工单"),
        REPAIR(70, "返修插单"),
        EMERGENCY_ORDER(80, "紧急插单"),
        FICTIVE(90, "虚拟工单"),
        SPARE_PART_PRODUCTION(100, "备件生产"),
        REPRODUCTION_RMS(110, "重新生产-报工"),
        REPRODUCTION_NOT_RMS(120, "重新生产-不报工"),
        REVERSE_SPRAY_ORDER(130, "反喷工单"),
        SPARE_RETURN_REPAIR(140, "客退备件返修"),
        SEIZE_SEAT_ORDER(150, "占位工单"),
        SAMPLE_ORDER(160, "样件工单");

        private int value;
        private String description;

        WORK_ORDER_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * MesPlanOrder实体对应的planType值  计划类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PLAN_ORDER_TYPE {

        STANDARD_ORDER(10, "标准");

        private int value;
        private String description;

        PLAN_ORDER_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * MesPlanOrder实体对应的source值  计划来源
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PALN_ORDER_SOURCE {

        MES("MES", "来源于MES"),
        SAP("SAP", "来源于SAP");

        private String value;
        private String description;

        PALN_ORDER_SOURCE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesWorkOrder实体对应的source值  计划来源
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WORK_ORDER_SOURCE {

        MES("MES", "来源于MES"),
        AMES("AMES", "来源于AMES"),
        SAP("SAP", "来源于SAP"),
        CREATE("CREATE", "手工新增"),
        RESOLVE("RESOLVE", "计划分解");

        private String value;
        private String description;

        WORK_ORDER_SOURCE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesQueueOrder实体对应的status值  队列主表状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QUEUE_ORDER_STATUS {

        WAIT_LANDED(5, "待下达"),
        NORMAL(10, "正常"),
        ONLINE(20, "已上线"),
        OFFLINE(30, "已下线"),
        CLOSE(40, "已关闭");

        private int value;
        private String description;

        QUEUE_ORDER_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesQueueOrderDetail实体对应的status值  队列详情状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QUEUE_ORDER_DETAIL_STATUS {

        NORMAL(10, "正常"),
        CLOSE(20, "关闭"),
        FINISH(30, "完成"),
        OFF_LINE_REWORK(40, "线下返修");

        private int value;
        private String description;

        QUEUE_ORDER_DETAIL_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesProduceSn实体对应的snStatus值  条码表条码状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PRODUCE_SN_STATUS {

        CREATE(10, "创建"),
        PROCESS(20, "加工"),
        OFFLINE(30, "下线"),
        PACKAGE_SCAN(35, "打包扫描"),
        INSTOCKED(40, "入库"),
        SHIPING(50, "发运"),
        REDO(60, "重做"),
        CLOSE(90, "关闭"),
        ;

        private int value;
        private String description;

        PRODUCE_SN_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WORK_ORDER_PRINT_STATUS {

        UNPRINTED(10, "未打印"),
        PRINTED(20, "已打印");

        private int value;
        private String description;

        WORK_ORDER_PRINT_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesProduceSn实体对应的printStatus值  条码表条码打印状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PRODUCE_SN_PRINT_STATUS {

        CREATE(10, "创建"),
        ONLINE(20, "上线打印"),
        OFFLINE(30, "下线打印");

        private int value;
        private String description;

        PRODUCE_SN_PRINT_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 质量标准配置
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QUALITY_STANDARD_TYPE {

        NG_RATE(10, "不良率"),
        INNER_PPM(20, "PPM"),
        ONLINE_PPM(30, "线上PPM");

        private int value;
        private String description;

        QUALITY_STANDARD_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 质量标准配置
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QUALITY_OBJECT_TYPE {

        ORGANIZE(10, "工厂"),
        WORK_CENTER_CODE(20, "产线"),
        PRODUCT(30, "产品");

        private int value;
        private String description;

        QUALITY_OBJECT_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesProduceSn实体对应的qcStatus值  条码表条码质量状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PRODUCE_SN_QC_STATUS {

        PRE_CHECK(5, "待检测"),
        QUALIFIED(10, "合格"),
        DEFECTED(20, "不合格"),
        SCRAPED(30, "报废"),
        DISMANTLED(40, "已拆解");

        private int value;
        private String description;

        PRODUCE_SN_QC_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MesPartCategory实体对应的categoryType值  条码表条码质量状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PART_CATEGORY_TYPE {

        CATEGORY_ONE("Category1", "类型1"),
        CATEGORY_TWO("Category2", "类型2"),
        CATEGORY_THREE("Category3", "类型3");

        private String value;
        private String description;

        PART_CATEGORY_TYPE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (val.equals(values()[i].value)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 工位程序交互时的业务类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum STATION_BUSI_TYPE {
        MESSAGE("message", "返回信息"),
        STEP_LIST("stepList", "工步列表"),
        STEP_CONTENT("stepContent", "工步内容"),
        MODULE_CONTENT("moduleContent", "组件内容"),
        CUSTOM_COMPONENT("customComponent", "定制内容"),
        TASK_COMPLETE("taskComplete", "整个扫描完成"),
        STEP_RAN_STATUS("stepRanStatus", "工步列表执行前"),
        RUNNING_INFO("runningInfo", "执行信息"),
        STOP_PCS_CTL("stopPcsCtl", "停止监控"),
        RENEW_REQUEST_PARAMS("renewRequestParams", "回传刷新StationResultBean");


        private String value;
        private String description;

        STATION_BUSI_TYPE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (val.equals(values()[i].value)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 工位程序交互时的数据类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum STATION_DATA_TYPE {
        TABLE("table", "表格"),
        TEXT("text", "正常文本"),
        EXP_TEXT("exp_text", "异常文本"),
        FILE("file", "定制内容文件"),
        IMAGE("image", "图片"),
        BUTTON("button", "按钮"),
        TABLES("tables", "多个表格");

        private String value;
        private String description;

        STATION_DATA_TYPE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (val.equals(values()[i].value)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 组织模型树形菜单level
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PROD_ORG_LEVEL {

        LEVEL_ONE(1, "一级目录"),
        LEVEL_TWO(2, "二级目录"),
        LEVEL_THREE(3, "三级目录"),
        LEVEL_FOUR(4, "四级目录");

        private int value;
        private String description;

        PROD_ORG_LEVEL(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 工步参数类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum STEP_PARAM_TYPE {

        QUALIFIED(10, "number", "数字"),
        DEFECTED(20, "text", "字符串"),
        SCRAPED(30, "select", "可选值"),
        BUTTON(40, "button", "按钮"),
        WINDOW(50, "window", "开窗");

        private int value;
        private String code;
        private String description;

        STEP_PARAM_TYPE(int value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getCode() {
            return code;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 通用条码枚举
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum COMMON_SN {
        QUEUE_SN("QUEUE_SN", "队列条码");

        private String code;
        private String description;
        int value;

        COMMON_SN(String code, String description) {
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getCode() {
            return code;
        }

        public String getDescription() {
            return description;
        }
    }

    /**
     * 动作类型枚举
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum ACTION_TYPE {

        SEATS(10, "座椅"),
        METAL(20, "金属件"),
        FOAMING(30, "发泡");

        private int value;
        private String description;

        ACTION_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 系统配置表枚举
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum CONFIG_TYPE {
        FASTDFS_SAVE_PATH(10, "SAVE_PATH", ""),
        NGINX_HOST(20, "NGINX_HOST", ""),
        MES_STATION_SOCKET(30, "mes_station_socket", ""),
        GATEWAY_IP(40, "GATEWAY_HOST", ""),
        UPDATE_SYNC_TIME(50, "SYNC_DATA_URL", "UPDATE_SYNC_TIME"),
        PCN_PULL(60, "SYNC_DATA_URL", "PCN_PULL"),
        PCN_PUSH(70, "SYNC_DATA_URL", "PCN_PUSH"),
        FDFS_DOWNLOAD(80, "SYNC_DATA_URL", "FDFS_DOWNLOAD"),
        REWORK_REPAIR(90, "REWORK_REPAIR", ""),
        OPC_LINK_SERVER_URL(100, "OPC_LINK", "OPC_LINK_SERVER_URL"),
        OPC_LINK_USERNAME(110, "OPC_LINK", "OPC_LINK_USERNAME"),
        OPC_LINK_PASSWORD(120, "OPC_LINK", "OPC_LINK_PASSWORD"),
        OPC_LINK_REALM(130, "OPC_LINK", "OPC_LINK_REALM"),
        OPC_LINK_CALLBACK(140, "OPC_LINK", "OPC_LINK_CALLBACK"),
        SUPPLY_SWITCH(150, "SUPPLY_SWITCH", ""),
        PCN_LOGIN(160, "PCN_LOGIN", ""),
        PCN_MENU(170, "PCN_MENU", ""),
        PCN_MODULE(180, "PCN_MODULE", ""),
        PCN_LOGOUT(190, "PCN_LOGOUT", ""),
        UPDATE_LOCALE_RES(200, "SYNC_DATA_URL", "LOCALE_RES_URL"),
        PCN_SYS_LOCALE_LANGUAGE(210, "PCN_SYS_LOCALE_LANGUAGE", ""),
        PCN_IMAGE_NGINX(220, "PCN_IMAGE_NGINX", "PCN_IMAGE_NGINX");

        private int value;
        private String code;
        private String description;

        CONFIG_TYPE(int value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getCode() {
            return code;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }


    /**
     * 事件类型枚举
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum EVENT_TYPE {

        SEATS(10, "座椅"),
        METAL(20, "金属件"),
        FOAMING(30, "发泡");

        private int value;
        private String description;

        EVENT_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 条码生成业务类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum COMPANY_TYPE {
        RULECODE("ruleCode", "规则编码"),
        PREFIX("prefix", "前缀"),
        PART_NO("partNo", "物料号"),
        CUST_PART_NO("custPartNo", "客户物料号"),
        CUST_CODE("custCode", "客户代码"),
        SERIAL_NUMBER("serialNumber", "过程条码"),
        PROD_LOCATION("prodLocation", "产地"),
        YEAR("year", "年"),
        MOTH("month", "月"),
        DAY("day", "日"),
        HOUR("hour", "小时"),
        MINUTE("minute", "分钟"),
        SECOND("second", "秒"),
        SERIAL("serialNo", "序列号");

        private String value;
        private String description;

        COMPANY_TYPE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }
    }

    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum ONLINE_SEND_TYPE {

        PLC("PLC", "PLC"),
        SELF_HANDLE("SELF_HANDLE", "自处理"),
        DB("DB", "DB");

        private String value;
        private String description;

        ONLINE_SEND_TYPE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String descriptionOfValue(String description) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * WC_CHECK_TYPE 开线检查的模块
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WC_CHECK_TYPE {
        MATERIAL(10, "MATERIAL", "物料"),
        ONLINE_SIGNAL(20, "ONLINE_SIGNAL", "开线信号");

        private int value;
        private String code;
        private String description;

        WC_CHECK_TYPE(int value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getCode() {
            return code;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * MesRoute 流程的类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum ROUTE_TYPE {

        SCAN(10, "扫描流程"),
        MONITOR(20, "监控流程");

        private int value;
        private String description;

        ROUTE_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * MesWorkCenter 工作中心运行状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WORK_CENTER_RUNNING_STATUS {

        RUNNING("Y", "start", "开线"),
        STOPPED("N", "stop", "停线");

        private String value;
        private String code;
        private String description;

        WORK_CENTER_RUNNING_STATUS(String value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getCode() {
            return code;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String valueOfCode(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].code;
                }
            }
            return tmp;
        }

        public static String descriptionOfValue(String description) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * MesWorkCellParamCfg 工作单元参数配置 是否必须校验
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_WORK_CELL_PARAM_CFG_IS_CHECK {

        RUNNING(1, "是"),
        STOPPED(2, "否");

        private int value;
        private String description;

        MES_WORK_CELL_PARAM_CFG_IS_CHECK(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * MesMonitorTask实体对应的status值  监听任务状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MONITOR_TASK_STATUS {

        NORMAL(10, "正常"),
        CLOSE(20, "关闭");

        private int value;
        private String description;

        MONITOR_TASK_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 监听任务任务对象类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MONITOR_TASK_OBJECT_TYPE {

        PLC(10, "PLC"),
        DB(20, "DB");

        private int value;
        private String description;

        MONITOR_TASK_OBJECT_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * 客户JIT生产队列状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QUEUE_JIT_ACTUAL_STATUS {
        CREATE(10, "创建"),
        LANDED(20, "下达"),
        CANCEL(30, "取消"),
        OFFLINE(40, "下线"),
        SHIPMENT(50, "发运"),
        SPECIAL(60, "特殊标识");

        private int value;
        private String description;

        QUEUE_JIT_ACTUAL_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 客户JIT生产队列特殊标识
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QUEUE_JIT_ACTUAL_SPECIAL_FLAG {
        NORMAL(10, "正常"),
        EMPTYING(20, "放空"),
        ERR_PERCH(30, "异常占位"),
        PERCH_HANDLE(40, "占位处理");

        private int value;
        private String description;

        QUEUE_JIT_ACTUAL_SPECIAL_FLAG(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * JIS发运队列状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QUEUE_JIS_STATUS {
        CREATE(10, "创建"),
        LANDED(20, "下达"),
        SHIPMENT(30, "已发运");

        private int value;
        private String description;

        QUEUE_JIS_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 生产队列 队列类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QUEUE_ORDER_QUEUE_TYPE {
        PRODUCT_QUEUE(10, "生产队列"),
        PRELOAD_QUEUE(20, "预装队列"),
        FIRST_STATION_QUEUE(30, "首工位队列");

        private int value;
        private String description;

        QUEUE_ORDER_QUEUE_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * JIS发运队列明细 状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QUEUE_JIS_DETAIL_STATUS {
        CREATE(10, "创建"),
        SHIPMENT(20, "已发运");

        private int value;
        private String description;

        QUEUE_JIS_DETAIL_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 关键件条码校验工步对应的物料分类的值
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PART_TYPE_THREE {

        MM(10, "MM"),
        MS(20, "MS");
        private int value;
        private String description;

        PART_TYPE_THREE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }


    /**
     * mes生产队列是否锁定
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QUEUE_ORDER_IS_LOCK {

        TRUE(1, "是"),
        FALSE(2, "否");

        private int value;
        private String description;

        QUEUE_ORDER_IS_LOCK(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 查询散件BOM关键物料号工步对应的物料分类的值
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PART_TYPE_THREE_STATION_BOM {

        MM(10, "MM"),
        NLX(20, "NLX");

        private int value;
        private String description;

        PART_TYPE_THREE_STATION_BOM(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }


    /**
     * 工位监听组件类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WORK_CELL_MONITOR_TYPE {
        MONITOR(10, "监听组件"),
        SHOW(20, "展示组件"),
        BUTTON(30, "按钮组件"),
        PROCESS_MONITOR(40, "工序监听组件");

        private int value;
        private String description;

        WORK_CELL_MONITOR_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }
    }

    /**
     * 工位监听组件触发类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WORK_MODULE_TRIGGER_TYPE {
        BY_SN(10, "根据条码加载工步"),
        BY_PART(20, "根据零件号加载工步");

        private int value;
        private String description;

        WORK_MODULE_TRIGGER_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }
    }

    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WORK_MODULE_PARAM_TYPE {
        NUMBER(10, "数值"),
        STRING(20, "字符串");

        private int value;
        private String description;

        WORK_MODULE_PARAM_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }
    }

    /**
     * 工位BOM表中的匹配类型
     * 10.
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum STATION_BOM_MATCH_RULE {

        BARCODE_RULE_MATCHING(10, "条码规则匹配"),
        PROCESS_BARCODE_MATCHING(20, "过程条码匹配"),
        BAR_CODE_MATCHING(30, "箱条码匹配");

        private int value;
        private String description;

        STATION_BOM_MATCH_RULE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 容器使用状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_CONTAINER_STATUS {
        FREE(10, "空闲"),
        OCCUPY(20, "占用");

        private int value;
        private String description;

        MES_CONTAINER_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 脚本语言类型
     * 10=Groovy, 20=Jython, 30=JavaScript, 40=Scala, 50=JRuby
     */
    public enum LANGUAGE_TYPE {
        GROOVY(1, "Groovy", 10),
        PYTHON(2, "jython", 20), // "jython" string can not change
        JS(3, "JavaScript", 30);
        // 下面这2种语言没人会写，暂不支持
        //SCALA(40,"scala"),
        //JRUBY(50,"jruby");

        private int index;
        private String description;
        private int value;

        LANGUAGE_TYPE(int index, String description, int value) {
            this.index = index;
            this.description = description;
            this.value = value;
        }

        public String getDescription() {
            return description;
        }

        public int getIndex() {
            return this.index;
        }

        public int getValue() {
            return value;
        }

        // 根据枚举编号获取语言代码
        public static String getCodeByIndex(Integer index) {
            for (MesEnumUtil.LANGUAGE_TYPE languageType : MesEnumUtil.LANGUAGE_TYPE.values()) {
                if (languageType.getValue() == index.intValue()) {
                    return languageType.getDescription();
                }
            }

            return null;
        }
    }


    /**
     * 产品特性
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PART_TRAIT {
        NORMAL(10, "正常件"),
        FICTITIOUS_ASSEMBLY(20, "虚拟散件总成"),
        FICTITIOUS_HALF_ASSEMBLY(30, "虚拟散件半总成"),
        FICTIVE(40, "虚拟件");

        private int value;
        private String description;

        PART_TRAIT(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * 配置类型
     */
    /**
     * mes工步类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PROD_CFG_TYPE {

        NORMAL("10", "正常"),
        SCATTERED("20", "散件");

        private String value;
        private String description;

        PROD_CFG_TYPE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 配方类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PART_FORMULA_TYPE {
        DEVICE_SEMAPHORE(10, "设备信号");

        private int value;
        private String description;

        PART_FORMULA_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static PART_FORMULA_TYPE codeOf(int value) {
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == value) {
                    return values()[i];
                }
            }
            return null;
        }

        public static String valueOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 作业校验模式
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum CHECK_MODEL {
        NO_CHECK(10, "不校验"),
        CHECK(20, "校验设备就绪信号");

        private int value;
        private String description;

        CHECK_MODEL(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * PLC类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PLC_TYPE {
        STANDARD(10, "标准"),
        EQU_OPERATION_SIGNLE(20, "设备作业信号");

        private int value;
        private String description;

        PLC_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * 看板类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum BOARD_TYPE {
        BOARD_CAPACITY_JIT("BOARD_CAPACITY_JIT", "产能监控看板(JIT)"),
        BOARD_EQU_STATUS("BOARD_EQU_STATUS", "设备状态监控看板(布局模式)"),
        BOARD_ORG_HOUR_OEE("BOARD_ORG_HOUR_OEE", " 工厂小时OEE"),
        BOARD_WORK_CELL_STATUS("BOARD_WORK_CELL_STATUS", " 工位状态监听看板"),
        BOARD_HNC_WC_CAPACITY("BOARD_HNC_WC_CAPACITY", " 生产线产能看板"),
        BOARD_MGN_CAPACITY("BOARD_MGN_CAPACITY", "产能看板"),
        BOARD_MGN_STATISTICS("BOARD_MGN_STATISTICS", "天津系统看板"),
        BOARD_MGN_BJ_MAIN_SCREEN("BOARD_MGN_BJ_MAIN_SCREEN", "北京麦格纳总屏幕看板"),
        BOARD_MGN_BJ_EQU_REPAIR("BOARD_MGN_BJ_EQU_REPAIR", "北京麦格纳设备维修看板");

        private String code;
        private String description;

        BOARD_TYPE(String code, String description) {
            this.code = code;
            this.description = description;
        }

        public String getCode() {
            return code;
        }

        public String getDescription() {
            return description;
        }

        public static BOARD_TYPE getByCode(String code) {
            for (BOARD_TYPE boardType : values()) {
                if (boardType.getCode().equals(code)) {
                    return boardType;
                }
            }
            return null;
        }

        public static String valueOfDescription(String code) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].code.equals(code)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 看板类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum BOARD_OBJECT_TYPE {
        ORGANIZE_CODE("organizeCode", "工厂代码"),
        AREA_CODE("areaCode", "区域代码"),
        WORK_CENTER_CODE("workCenterCode", "产线代码");

        private String value;
        private String description;

        BOARD_OBJECT_TYPE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static BOARD_OBJECT_TYPE getByCode(String code) {
            for (BOARD_OBJECT_TYPE boardObjectType : values()) {
                if (boardObjectType.getValue().equals(code)) {
                    return boardObjectType;
                }
            }
            return null;
        }

        public static String valueOfDescription(String code) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(code)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * mes 员工技能等级
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum SKILL_LEVEL {

        TRAINING("10", "培训中"),
        QUALIFIED("20", "合格"),
        GOOD("30", "良好"),
        CAN_GUIDE_OTHERS("40", "可指导他人");

        private String value;
        private String description;

        SKILL_LEVEL(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 界面类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WINDOW_TYPE {
        BUTTON_CFG(10, "按钮组件"),
        BOARD_BASE_WINDOW(20, "看板基础页面");

        private int value;
        private String description;

        WINDOW_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }


    /**
     * 运算对象属性 运算类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum OPERATE_TYPE {
        OEE(10, "OEE"),
        MTBF(20, "MTBF平均故障间隔"),
        MTTR(30, "MTTR平均修理时间");

        private int value;
        private String description;

        OPERATE_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 运算对象属性 属性类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum ATTRIBUTE_TYPE {
        STANDARD_ATTRIBUTE(10, "标准属性"),
        CUSTOM_ATTRIBUTE(20, "自定义属性");

        private int value;
        private String description;

        ATTRIBUTE_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 运算对象属性配置 赋值类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum VALUE_TYPE {
        MANUAL_ASSIGNMENT("10", "手工赋值"),
        SPEL_EXPRESSION("20", "spel表达式"),
        FUNCTION_ASSIGNMENT("30", "函数赋值"),
        JOB_ASSIGNMENT("40", "job赋值");

        private String value;
        private String description;

        VALUE_TYPE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static VALUE_TYPE getByValue(String value) {
            for (VALUE_TYPE valueType : values()) {
                if (valueType.getValue().equals(value)) {
                    return valueType;
                }
            }
            return null;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 运算对象 对象代码
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum OBJECT_CODE {
        ORGANIZE_OEE("10", "工厂OEE"),
        WORK_CENTER_OEE("20", "产线OEE"),
        WORK_CELL_CEE("30", "工位OEE"),
        EQU_OEE("40", "设备OEE");

        private String value;
        private String description;

        OBJECT_CODE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static OBJECT_CODE getByValue(String value) {
            for (OBJECT_CODE objectCode : values()) {
                if (objectCode.getValue().equals(value)) {
                    return objectCode;
                }
            }
            return null;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 脚本类型（组件、表单、报表、JOB、其他）
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum SCRIPT_TYPE {
        ASSEMBLY(10, "组件"),
        FORM(20, "表单"),
        REPORT_FORM(30, "报表"),
        JOB(40, "JOB"),
        OTHER(50, "其他");

        private int value;
        private String description;

        SCRIPT_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 语言类型（Groovy、Python、JavaScript、Scala、Ruby）
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum SCRIPT_LANGUAGE {
        GROOVY(10, "Groovy"),
        PYTHON(20, "Python"),
        JAVA_SCRIPT(30, "JavaScript"),
        SCALA(40, "Scala"),
        RUBY(50, "Ruby");

        private int value;
        private String description;

        SCRIPT_LANGUAGE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }


    /**
     * 运算对象代码 Period capacity
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum OPERATE_OBJECT_CODE {
        ORGANIZE_OEE_HOUR("ORGANIZE_OEE_HOUR", "工厂OEE(小时)"),
        ORGANIZE_OEE_DAY("ORGANIZE_OEE_DAY", "工厂OEE(天)"),
        WORK_CENTER_OEE_DAY("WORK_CENTER_OEE_DAY", "产线OEE(天)"),
        EQU_OEE_DAY("EQU_OEE_DAY", "设备OEE(天)"),
        PERIOD_CAPACITY("PERIOD_CAPACITY", "时段产能");

        private String value;
        private String description;

        OPERATE_OBJECT_CODE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static OPERATE_OBJECT_CODE getByValue(String value) {
            for (OPERATE_OBJECT_CODE objectCode : values()) {
                if (objectCode.getValue().equals(value)) {
                    return objectCode;
                }
            }
            return null;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * oee 运算状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum OEE_STATUS {
        STAY_OPERATE(10, "待运算"),
        ALREADY_OPERATE(20, "已运算");

        private int value;
        private String description;

        OEE_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 质检单状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QC_STATUS {
        CREATE(10, "创建"),
        RECEIPT(20, "执行中"),
        SUBMISSION(30, "提交"),
        COMPLETE(40, "完成");

        private int value;
        private String description;

        QC_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 接口读取标识
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum IN_READ_FLAG {
        NOTREAD(0, "未读取"),
        READ(1, "已读取");

        private int value;
        private String description;

        IN_READ_FLAG(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MES_检验单 状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_QC_STATUS {

        CREATE(10, "创建"),
        IN_EXEC(20, "执行中"),
        COMPLETE(30, "完成");

        private int value;
        private String description;

        MES_QC_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * MES_检验单 检测整体结果
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_QC_CHECK_RESULT {

        PASS(10, "通过"),
        NO_PASS(20, "不通过"),
        COMPROMISE_PASS(30, "让步通过");

        private int value;
        private String description;

        MES_QC_CHECK_RESULT(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }


    /**
     * MES_PLC 数据类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PLC_DATA_TYPE {
        STRING("10", "String", "字符串"),
        BOOLEAN("20", "Boolean", "布尔"),
        WORD("30", "Word", "整形-Word"),
        DWORD("40", "Dword", "整形-DWord"),
        LONG("50", "Long", "长整形-Long"),
        SHORT("60", "Short", "UShort"),
        DOUBLE("70", "Double", "双精度-Double"),
        FLOAT("80", "Float", "单精度-Float"),
        LLONG("90", "LLong", "LLONG"),
        QWORD("100", "QWord", "QWORD"),
        BCD("110", "BCD", "BCD"),
        LBCD("120", "LBCD", "LBCD"),
        BYTE("130", "Byte", "Byte"),
        CHAR("140", "Char", "Char"),
        Date("150", "DateTime", "日期");

        private String value;
        private String code;
        private String description;

        PLC_DATA_TYPE(String value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String codeOfValue(String code) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].code.equals(code)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * MES_产品颜色 	类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum MES_COLOR_TYPE {

        PRODUCT_COLOR(10, "产品颜色"),
        MATERIAL_COLOR(20, "物料颜色");

        private int value;
        private String description;

        MES_COLOR_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * 数据格式
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum DATA_FORMAT {
        STRING_FORMAT(1, "String", "字符串格式"),
        INTEGER_FORMAT(2, "Integer", "整数格式"),
        DOUBLE_FORMAT(3, "Double", "高精度浮点格式"),
        DATE_FORMAT(4, "Date", "日期格式"),
        FLOAT_FORMAT(5, "Float", "浮点格式"),
        BOOL_FORMAT(6, "Boolean", "布尔格式"),
        LONG_FORMAT(7, "LONG", "长整数格式");

        private int value;
        private String code;
        private String description;

        DATA_FORMAT(int value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public String getCode() {
            return code;
        }

        public static String valueOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static int descOf(String desc) {
            int tmp = 1;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(desc)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }

        public static String valueOfDescription(int val) {
            return valueOf(val);
        }
    }

    /**
     * 数据导入类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum TEMPLATE_IMPORT_TYPE {
        SINGLE_TABLE(10, "SINGLE_TABLE", "单表"),
        MULTI_TABLE(20, "MULTI_TABLE", "多表");

        private int value;
        private String code;
        private String description;

        TEMPLATE_IMPORT_TYPE(int value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public String getCode() {
            return code;
        }

        public static String valueOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static int descOf(String desc) {
            int tmp = 1;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(desc)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }

        public static String valueOfDescription(int val) {
            return valueOf(val);
        }
    }

    /**
     * 数据更新类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum TEMPLATE_UPDATE_TYPE {
        FULL_COVERAGE(10, "FULL_COVERAGE", "全覆盖"),
        DIFF_UPDATE(20, "DIFF_UPDATE", "差异更新"),
        REPEATE_NO_IMPORT(30, "REPEATE_NO_IMPORT", "重复不导入");

        private int value;
        private String code;
        private String description;

        TEMPLATE_UPDATE_TYPE(int value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public String getCode() {
            return code;
        }

        public static String valueOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static int descOf(String desc) {
            int tmp = 1;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(desc)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }

        public static String valueOfDescription(int val) {
            return valueOf(val);
        }
    }

    /**
     * 校枪状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum CALIBRATION_STATUS {
        UNEXECUTED(10, "UNEXECUTED", "待执行"),
        EXECUTE(20, "EXECUTE", "执行中"),
        CANCEL(30, "CANCEL", "取消"),
        FINISH(40, "FINISH", "完成");

        private int value;
        private String code;
        private String description;

        CALIBRATION_STATUS(int value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public String getCode() {
            return code;
        }

        public static String valueOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static int descOf(String desc) {
            int tmp = 1;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(desc)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }

        public static String valueOfDescription(int val) {
            return valueOf(val);
        }
    }


    /**
     * 扭矩枪类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum GUN_TYPE {
        DL(10, "DL", "小枪"),
        PF(20, "PF", "大枪");

        private int value;
        private String code;
        private String description;

        GUN_TYPE(int value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public String getCode() {
            return code;
        }

        public static String valueOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static int descOf(String desc) {
            int tmp = 1;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(desc)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }

        public static String valueOfDescription(int val) {
            return valueOf(val);
        }
    }

    /**
     * 盲检类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum TOPIC_TYPE {
        COLOUR(10, "颜色"),
        GRADE(20, "等级"),
        TO_CONFIGURE(30, "配置");

        private int value;
        private String description;

        TOPIC_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 选配类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum OPTION_TYPE {
        OPTION(10, "选配件"),
        BOM_DISASSEMBLY(20, "BOM拆解");

        private int value;
        private String description;

        OPTION_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 扭矩采集 黄枪规则(10-继续采集扭矩，20-发送下一个组合码)
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum YELLOW_GUN_RULE {
        COLLECT_TORQUE(10, "继续采集扭矩"),
        SEND_NEXT_GROUP_CODE(20, "发送下一个组合码");

        private int value;
        private String description;

        YELLOW_GUN_RULE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 停机类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum STOP_MACHINE_TYPE {
        TIMER_TIME_OUT(10, "计时器超时停机"),
        DELAY_HELP(20, "延时帮助停机"),
        URGENT_STOP(30, "急停停机");

        private int value;
        private String description;

        STOP_MACHINE_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }


    /**
     * 选项代码
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum OPTION_CODE {
        EXISTENCE("+", "存在"),
        NON_EXISTENCE("-", "不存在"),
        BRACKET_OPERATION("()", "括号运算"),
        AND("&", " 与"),
        OR("|", "或");

        private String value;
        private String description;

        OPTION_CODE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String value) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(value)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 条码生成模式
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum GENERATE_TYPE {
        RELEASE_GENERATION(10, "下达生成"),
        STATION_GENERATION(20, "工位生成");

        private Integer value;
        private String description;

        GENERATE_TYPE(Integer value, String description) {
            this.value = value;
            this.description = description;
        }

        public Integer getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(Integer value) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(value)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 客户JIT预装队列状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QUEUE_JIT_PLAN_STATUS {
        CREATE(10, "创建"),
        RELEASED(20, "已释放"),
        ERROR(999, "异常");

        private Integer value;
        private String description;

        QUEUE_JIT_PLAN_STATUS(Integer value, String description) {
            this.value = value;
            this.description = description;
        }

        public Integer getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(Integer value) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(value)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 客户JIT队列下达配置 缓存类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum JIT_ISSUE_CFG_TYPE {
        ORDER_CACHE(10, "订单池"),
        LOCK_CACHE(20, "锁定池");

        private Integer value;
        private String description;

        JIT_ISSUE_CFG_TYPE(Integer value, String description) {
            this.value = value;
            this.description = description;
        }

        public Integer getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(Integer value) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == value) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * JIT队列订单池 状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum JIT_ORDER_CACHE_STATUS {
        CREATE(10, "创建"),
        COMPLETE(20, "完成"),
        CANCEL(30, "取消");

        private Integer value;
        private String description;

        JIT_ORDER_CACHE_STATUS(Integer value, String description) {
            this.value = value;
            this.description = description;
        }

        public Integer getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(Integer value) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == value) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * JIT队列锁定池 状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum JIT_LOCK_CACHE_STATUS {
        CREATE(10, "创建"),
        RELEASE(20, "下达"),
        ONLINE_COMPLETE(30, "上线完成");

        private Integer value;
        private String description;

        JIT_LOCK_CACHE_STATUS(Integer value, String description) {
            this.value = value;
            this.description = description;
        }

        public Integer getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(Integer value) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == value) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 队列 料架摆放位置
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum GROUP_SIDE {
        POSITIVE(10, "A", "正面"),
        REVERSE_SIDE(20, "B", "背面");

        private Integer value;
        private String code;
        private String description;

        GROUP_SIDE(Integer value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public Integer getValue() {
            return value;
        }

        public String getCode() {
            return code;
        }

        public String getDescription() {
            return description;
        }

        public static String codeOfDescription(String code) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].code.equals(code)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String valueOfDescription(Integer value) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == value) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * QAD 解析对象
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QAD_DATA_OBJECT {
        BOM("soapenv#Envelope#SyncBOM", "getBomList", "MesBom", "BOM"),
        CUSTOMER_PART("soapenv#Envelope#SyncCustomerItem", "getCustomerPartList", "MesCustomerPart", "客户物料号"),
        CUSTOMER("soapenv#Envelope#SyncCustomer", "getCustomerList", "MesCustomer", "客户信息"),
        PART("soapenv#Envelope#SyncItem", "getPartList", "MesPart", "物料信息");

        private String code;
        private String method;
        private String objectCode;
        private String description;

        QAD_DATA_OBJECT(String code, String method, String objectCode, String description) {
            this.code = code;
            this.method = method;
            this.objectCode = objectCode;
            this.description = description;
        }

        public String getCode() {
            return code;
        }

        public String getMethod() {
            return method;
        }

        public String getObjectCode() {
            return objectCode;
        }

        public String getDescription() {
            return description;
        }

        public static String codeOfDescription(String code) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].code.equals(code)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static QAD_DATA_OBJECT getByObjectCode(String objectCode) {
            for (QAD_DATA_OBJECT qadDataObject : values()) {
                if (qadDataObject.getObjectCode().equals(objectCode)) {
                    return qadDataObject;
                }
            }
            return null;
        }

        public static QAD_DATA_OBJECT getByCode(String code) {
            for (QAD_DATA_OBJECT qadDataObject : values()) {
                if (qadDataObject.getCode().equals(code)) {
                    return qadDataObject;
                }
            }
            return null;
        }
    }

    /**
     * 工位BOM  绑定物料类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum BIND_PART_TYPE {
        POSITIVE(10, "半成品"),
        REVERSE_SIDE(20, "原材料");

        private Integer value;
        private String description;

        BIND_PART_TYPE(Integer value, String description) {
            this.value = value;
            this.description = description;
        }

        public Integer getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(Integer value) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == value) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 工作中心 工位监控模式  10=工单作业，20=标准作业
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WORK_CENTER_MONITOR_TYPE {

        ORDER_WORK(10, "工单作业"),
        STANDARD_WORK(20, "标准作业");

        private int value;
        private String description;

        WORK_CENTER_MONITOR_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * 工位等级
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WORK_CELL_GRADE {

        COMMON(10, "普通工位"),
        MONITOR(20, "监控工位");

        private int value;
        private String description;

        WORK_CELL_GRADE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * 样本类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum SAMPLE_TYPE {

        NORMAL(10, "正常"),
        FIRST_ARTICLE(20, "首件"),
        MEDIUM_SIZED(30, "中件"),
        LAST_PIECE(40, "末件");

        private int value;
        private String description;

        SAMPLE_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * 产品位置
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PRODUCE_CATEGORY {

        FL("FL", "DOOR_FRONT_LEFT"),
        FR("FR", "DOOR_FRONT_RIGHT"),
        RL("RL", "DOOR_REAR_LEFT"),
        RR("RR", "DOOR_REAR_RIGHT");

        private String description;
        private String value;

        PRODUCE_CATEGORY(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String descriptionOfValue(String description) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * 取值对象类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum EXTRACT_OBJECT_TYPE {
        MODEL(10, "实体对象（单表）"),
        PRODUCT_DATA(20, "动态对象（生产数据表）");

        private Integer value;
        private String description;

        EXTRACT_OBJECT_TYPE(Integer value, String description) {
            this.value = value;
            this.description = description;
        }

        public Integer getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(Integer value) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == value) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 系数类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum COEFFICIENT_TYPE {
        CONTROL(10, "控制限系数"),
        CENTER(20, "中心线系数");

        private Integer value;
        private String description;

        COEFFICIENT_TYPE(Integer value, String description) {
            this.value = value;
            this.description = description;
        }

        public Integer getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(Integer value) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == value) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 工单启动池状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum WORK_START_CACHE_STATUS {

        PENDING(10, "待处理"),
        PROCESSED(20, "已处理");

        private int value;
        private String description;

        WORK_START_CACHE_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * 涂装导入--反喷标识（Y-正常；F-反喷）
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum REVERSE_SPRAY_MARK {
        REVERSE_SPRAY("F", "反喷"),
        NORMAL("Y", "正常");

        private String value;
        private String description;

        REVERSE_SPRAY_MARK(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * MES_出入库事务表--事务类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PACKAGE_TRANS_TYPE {

        OUTSTOCK(10, "出库"),
        INSTOCK(20, "入库"),
        GOBACK(30, "退回");

        private int value;
        private String description;

        PACKAGE_TRANS_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static Integer descriptionOfValue(String description) {
            Integer tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * 通知标识
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum NOTICE_SIGN {

        PENDING(10, "待处理"),
        PROCESSED(20, "已处理");

        private int value;
        private String description;

        NOTICE_SIGN(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

    }

    /**
     * 触发类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum STEP_TRIGGER_TYPE {
        INTERNAL_TRIGGER(10, "内部触发"),
        EXTERNAL_TRIGGER(20, "外部触发");

        private int value;
        private String description;

        STEP_TRIGGER_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 客户JIT队列明细状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QUEUE_JIT_ACTUAL_DETAIL_STATUS {
        NORMAL(10, "正常"),
        WASHED_MATERIAL(20, "已冲料");

        private int value;
        private String description;

        QUEUE_JIT_ACTUAL_DETAIL_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * JIS_回冲标识：BACKFLUSH = 正常回冲扣减，REPAIR = 返修冲料
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum JIS_BACKFLUSH_STATUS {
        BACKFLUSH("BACKFLUSH", "正常回冲扣减"),
        REPAIR("REPAIR", "返修冲料");

        private String value;
        private String description;

        JIS_BACKFLUSH_STATUS(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 质检单审批处理意见
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QC_ORDER_APPROVAL_CHOICE {

        STOP_LINE(10, "停线"),
        RELEASE(20, "放行");

        private int value;
        private String description;

        QC_ORDER_APPROVAL_CHOICE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 整体检测结果状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum CHECK_RESULT {

        PASS(10, "通过"),
        NON_PASS(20, "不通过"),
        CONCESSION_PRODUCTION(30, "让步生产");

        private int value;
        private String description;

        CHECK_RESULT(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 整体检测结果状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QC_ORDER_APPROVAL_TYPE {

        STOP_LINE(10, "停线"),
        RELEASE(20, "放行");

        private int value;
        private String description;

        QC_ORDER_APPROVAL_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 检测单明细的检测结果
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QC_ORDER_DETAIL_CHECK_RESULT {

        OK(10, "OK"),
        NG(20, "NG");

        private int value;
        private String description;

        QC_ORDER_DETAIL_CHECK_RESULT(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * mes 看板展示类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum SHOW_TYPE {

        PICTURE(10, "图片"),
        VIDEO(20, "视频");

        private int value;
        private String description;

        SHOW_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * mes 数据来源
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QC_CHECK_DATA_SOURCE {
        MANUAL_INPUT(10, "10", "人工输入"),
        DB(30, "30", "数据库"),
        PLC(20, "20", "PLC");

        private int value;
        private String description;
        private String code;

        QC_CHECK_DATA_SOURCE(int value, String code, String description) {
            this.value = value;
            this.description = description;
            this.code = code;
        }

        public int getValue() {
            return value;
        }

        public String getCode() {
            return code;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * mes 检验值类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QC_CHECK_VALUE_TYPE {
        STRING(10, "字符串"),
        INTEGER(20, "数值");

        private int value;
        private String description;

        QC_CHECK_VALUE_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 控制计划审核状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum CONTROL_PLAN_AUDIT_TYPE {
        WAIT_AUDIT(10, "待审核"),
        AUDIT_PASS(20, "审核通过"),
        AUDIT_NON_PASS(30, "审核驳回");

        private int value;
        private String description;

        CONTROL_PLAN_AUDIT_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * edi解析方式
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum EDI_PARSE_TYPE {
        JOB(10, "定时任务解析文件"),
        SPARE_PARTS(20, "备件excel上传");

        private int value;
        private String description;

        EDI_PARSE_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * edi解析方式
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum EDI_REPORT_TYPE {
        JSP(1, "jsp解析"),
        JSA(2, "jsa解析");

        private int value;
        private String description;

        EDI_REPORT_TYPE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getValueStr() {
            return value + "";
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 功能模块
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum SRC_MENU_CODE {

        STATION_MONITOR("STATION_MONITOR", "工位监控");

        private String value;
        private String description;

        SRC_MENU_CODE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static String descriptionOfValue(String description) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(description)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }
    }

    /**
     * 缺陷类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum DEFECT_TYPE_CODE {
        SCRAPPED("SCRAPPED", "报废"),
        BACK_SPRAY("BACK_SPRAY", "返喷"),
        POLISHING("POLISHING", " 抛光"),
        DETERMIND("DETERMIND", " 待定");

        private String value;
        private String description;

        DEFECT_TYPE_CODE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String value) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(value)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }


    /**
     * 物料 物料类型1
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum PART_CATEGORY1 {
        RAW_PART(10, "原材料"),
        SEMI_FINISHED_PRODUCT(20, "半成品"),
        FINISHED_PRODUCT(30, "成品");

        private int value;
        private String description;

        PART_CATEGORY1(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getValueStr() {
            return value + "";
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 查询周期
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum QUERY_GAP_TYPE {
        MINUTE("MINUTE", "分钟"),
        HOUR("HOUR", "小时"),
        DAY("DAY", " 日"),
        WEEK("WEEK", " 周"),
        MONTH("MONTH", " 月");

        private String value;
        private String description;

        QUERY_GAP_TYPE(String value, String description) {
            this.value = value;
            this.description = description;
        }

        public String getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(String value) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value.equals(value)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 看板-安灯监控状态
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum ANDON_QUEUE_STATUS {
        CALL(10, "呼叫"),
        RESPONSE(20, "响应"),
        SOLVE(30, "解决");

        private int value;
        private String description;

        ANDON_QUEUE_STATUS(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getValueStr() {
            return value + "";
        }

        public String getDescription() {
            return description;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 不良品处理类型
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum BAD_HANDLE_TYPE {
        BACK_SPRAY(10, "BACK_SPRAY", "返喷"),
        SCRAPPED(20, "SCRAPPED", "报废"),
        POLISHING(30, "POLISHING", "抛光"),
        DETERMIND(40, "DETERMIND", "待定");

        private int value;
        private String code;
        private String description;

        BAD_HANDLE_TYPE(int value, String code, String description) {
            this.value = value;
            this.code = code;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getDescription() {
            return description;
        }

        public String getCode() {
            return code;
        }

        public static String valueOf(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }

        public static int descOf(String desc) {
            int tmp = 1;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].description.equals(desc)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }

        public static int codeOf(String code) {
            int tmp = 1;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].code.equals(code)) {
                    tmp = values()[i].value;
                }
            }
            return tmp;
        }

        public static String valueOfDescription(int val) {
            return valueOf(val);
        }

        public static String codeOfDescription(String val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].code.equals(val)) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

    /**
     * 展示供应商代码
     */
    @JsonFormat(shape = JsonFormat.Shape.OBJECT)
    public enum SHOW_SUPPLIER_CODE {
        MGN(10, "麦格纳"),
        OTHER(20, "其他"),
        ALL(99, "全部");

        private int value;
        private String description;

        SHOW_SUPPLIER_CODE(int value, String description) {
            this.value = value;
            this.description = description;
        }

        public int getValue() {
            return value;
        }

        public String getValueStr() {
            return value + "";
        }

        public String getDescription() {
            return description;
        }

        public static MesEnumUtil.SHOW_SUPPLIER_CODE getByValue(Integer value) {
            for (MesEnumUtil.SHOW_SUPPLIER_CODE showSupplierCode : values()) {
                if (showSupplierCode.getValue() == value) {
                    return showSupplierCode;
                }
            }
            return null;
        }

        public static String valueOfDescription(int val) {
            String tmp = null;
            for (int i = 0; i < values().length; i++) {
                if (values()[i].value == val) {
                    tmp = values()[i].description;
                }
            }
            return tmp;
        }
    }

}
