1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
| package com.iailab.module.ansteel.common.enums;
|
| import lombok.AllArgsConstructor;
| import lombok.Getter;
| import org.apache.commons.lang3.StringUtils;
|
| @Getter
| @AllArgsConstructor
| public enum TraceProcessTypeEnum {
|
| BM("BM", "备煤工序"),
| LJ("LJ", "炼焦工序"),
| GXJ("GXJ", "干熄焦工序"),
| HC("HC", "化产工序"),
| UNKNOW("unkuow", "未知");
|
| private String code;
| private String process;
|
| public static TraceProcessTypeEnum getEumByCode(String code) {
| if (StringUtils.isBlank(code)) {
| return UNKNOW;
| }
| for (TraceProcessTypeEnum statusEnum : TraceProcessTypeEnum.values()) {
| if (statusEnum.getCode().equals(code.trim().toUpperCase())) {
| return statusEnum;
| }
| }
| return UNKNOW;
| }
| }
|
|