|
|
|
@ -82,16 +82,18 @@ public class AndonEnumUtil {
|
|
|
|
|
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
|
|
|
|
|
public enum ALARM_FLAG{
|
|
|
|
|
|
|
|
|
|
CALL(1,"呼叫"),
|
|
|
|
|
SIGN(2,"签到"),
|
|
|
|
|
RESOLVE(3, "解决"),
|
|
|
|
|
CANCEL(4, "撤销");
|
|
|
|
|
CALL(1,"10","呼叫"),
|
|
|
|
|
SIGN(2,"20","签到"),
|
|
|
|
|
RESOLVE(3,"30","解决"),
|
|
|
|
|
CANCEL(4,"40", "撤销");
|
|
|
|
|
|
|
|
|
|
private int value;
|
|
|
|
|
private String code;
|
|
|
|
|
private String description;
|
|
|
|
|
|
|
|
|
|
ALARM_FLAG(int value, String description) {
|
|
|
|
|
ALARM_FLAG(int value,String code, String description) {
|
|
|
|
|
this.value = value;
|
|
|
|
|
this.code = code;
|
|
|
|
|
this.description = description;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -99,6 +101,8 @@ public class AndonEnumUtil {
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public String getCode(){ return code; }
|
|
|
|
|
|
|
|
|
|
public String getDescription() {
|
|
|
|
|
return description;
|
|
|
|
|
}
|
|
|
|
@ -143,4 +147,43 @@ public class AndonEnumUtil {
|
|
|
|
|
return description;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 优先级别
|
|
|
|
|
* 1 - 一级,2 - 二级,3 - 三级,4 - 四级
|
|
|
|
|
*/
|
|
|
|
|
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
|
|
|
|
|
public enum ALARM_PRIORITY{
|
|
|
|
|
|
|
|
|
|
FIRST(1,"一级"),
|
|
|
|
|
SECOND(2,"二级"),
|
|
|
|
|
THIRD(3,"三级"),
|
|
|
|
|
FOURTH(4,"四级");
|
|
|
|
|
|
|
|
|
|
private int value;
|
|
|
|
|
private String description;
|
|
|
|
|
|
|
|
|
|
ALARM_PRIORITY(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;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|