package jnpf.enums.attendance;

import lombok.Getter;

/**
 * 审批类型枚举
 *
 * @author yanwenfu
 * @create 2025-09-23
 */
@Getter
public enum ApplyTypeEnum {

    /** 补卡 */
    REPAIR(1),
    /** 出勤变更 */
    RESULT_CHANGE(2),
    /** 外勤 */
    OUTSIDE(3),
    /** 违规 */
    VIOLATION(4),
    ;

    private final Integer value;

    ApplyTypeEnum(Integer value) {
        this.value = value;
    }

    public static ApplyTypeEnum getApplyTypeEnum(Integer value) {

        ApplyTypeEnum[] values = ApplyTypeEnum.values();
        for (ApplyTypeEnum v : values) {
            if (v.getValue().equals(value)) {
                return v;
            }
        }
        return null;
    }
}
