package com.sw.mes.enumvalue;

import com.sw.mes.core.enums.EnumValue;
import lombok.Getter;

/**
 * @Author: GaoXinJian
 * @Date: 2022-01-20 13:22
 */
public class EnumDocketPrint {
    @Getter
    /**
     * 打印模版枚举
     */
    public enum PrintModelType implements EnumValue.KeyValue {
        /**
         *
         */
//        画线标签("DRAW_LINE_LABEL", "画线标签"),
//        圆棒合格证("YB_CRYSTAL_CERTIFICATE", "圆棒合格证"),
//        合格证标签("CERTIFICATE_LABEL", "合格证标签"),
        圆棒反切标签("YB_RE_CUTTING_LABEL", "圆棒反切标签"),
        单晶补标签("SINGLE_CRYSTAL_PATCH_LABEL", "单晶补标签"),
        //        圆棒初级标签("YB_PRIMARY_LABEL", "圆棒初级标签"),
//        方棒合格证("FB_CRYSTAL_CERTIFICATE", "方棒合格证"),
        方棒反切标签("FB_RE_CUTTING_LABEL", "方棒反切标签"),
        //        方棒唛头("FB_SHIPPING_MARK", "方棒唛头"),
        PDA补签("PDA_RE_LABEL", "PDA补签"),
        晶棒划线条码("CRYSTAL_DOCUMENT_MOULD", "晶棒划线条码"),
        长晶棒头划线("LONG_CRYSTAL_DOCUMENT_MOULD", "长晶棒头划线"),
        热场条码("HOT_SPOT_CODE", "热场条码"),
        圆棒标签("YB_LABEL", "圆棒标签"),
        成品标签("CLEAN_BOX", "成品标签"),
        成托标签("CLEAN_GROUP", "成托标签"),
        方棒标签("FB_LABEL", "方棒标签"),
        方棒组拖("FB_TURNSTORE", "方棒组拖"),
        籽晶打印("CRYSTALLON", "籽晶打印"),
        无尘打印("CLEAN_GROUP_PRINT", "无尘打印"),
        分选打印("CLEAN_FX_PRINT", "分选打印"),
        余料打印("REC_PRINT", "余料打印"),
        单晶余料标签("SURPLUS_PRINT", "单晶余料标签"),
        返工打印("CLEAN_REWORK_PRINT", "返工打印"),
        余料出库打印("STORE_OUTPUT_PRINT", "余料出库打印"),
        废料标签("REC_OUTPUT_PRINT", "废料标签"),
        方棒组拖拖号("FB_TURNSTORE_NO", "方棒组拖拖号");

        PrintModelType(String key, String value) {
            this.key = key;
            this.value = value;
        }

        public static String getText(String value) {
            PrintModelType[] printModelTypes = values();
            for (PrintModelType businessModeEnum : printModelTypes) {
                if (businessModeEnum.getKey().equals(value)) {
                    return businessModeEnum.getValue();
                }
            }
            return null;
        }

        private String key;
        private String value;

        public static PrintModelType getEnum(String value) {
            PrintModelType[] businessModeEnums = values();
            for (PrintModelType businessModeEnum : businessModeEnums) {
                if (businessModeEnum.getValue().equals(value)) {
                    return businessModeEnum;
                }
            }
            return null;
        }
    }
}
