package com.nanometer.smartlab.entity.enumtype;
|
|
import java.util.HashMap;
|
|
public enum ApplyStatusVo {
|
STORAGE(4, "已入库"),SUPPLIER_CONFIRM(6,"已确认");
|
private int key;
|
|
private String text;
|
|
private ApplyStatusVo(int key, String text) {
|
this.key = key;
|
this.text = text;
|
}
|
|
public int getKey() {
|
return key;
|
}
|
|
public String getText() {
|
return text;
|
}
|
|
private static HashMap<Integer,ApplyStatusVo> map = new HashMap<Integer,ApplyStatusVo>();
|
static {
|
for(ApplyStatusVo d : ApplyStatusVo.values()){
|
map.put(d.key, d);
|
}
|
}
|
|
public static ApplyStatusVo parse(Integer index) {
|
if(map.containsKey(index)){
|
return map.get(index);
|
}
|
return null;
|
}
|
|
|
}
|