package org.jeecg.modules.tms.enums; import lombok.Getter; /** * 刃磨状态枚举 */ @Getter public enum SharpenStatus { PENDING("1", "待刃磨"), IN_PROGRESS("2", "刃磨中"), COMPLETED("3", "已完成"); private final String value; private final String description; SharpenStatus(String value, String description) { this.value = value; this.description = description; } /** * 根据状态值获取枚举实例 * @param status 状态值 * @return 枚举实例或null */ public static SharpenStatus fromStatus(String status) { for (SharpenStatus value : values()) { if (value.getValue().equals(status)) { return value; } } return null; } }