package enumeration.general; import com.baomidou.mybatisplus.annotation.EnumValue; import com.fasterxml.jackson.annotation.JsonValue; import lombok.Getter; /** * 工单下发方式 * * @author:gonghl * @date:2024/4/18 */ @Getter public enum WorkOrderDistributeWayEnum { SELECTED_DISTRIBUTE("SELECTED_DISTRIBUTE", "选择下发"), ALL_DISTRIBUTE("ALL_DISTRIBUTE", "全部下发"), FAST_DISTRIBUTE("FAST_DISTRIBUTE", "快捷下发"), DIRECT_DISTRIBUTE("DIRECT_DISTRIBUTE", "超阈值自动下发"), ; @EnumValue // 标明该字段存入数据库 @JsonValue // 标明在转JSON时使用该字段,即响应时 private final String value; private final String desc; WorkOrderDistributeWayEnum(String value, String desc) { this.value = value; this.desc = desc; } }