package cn.iocoder.yudao.module.bpm.handler.enums;

public enum WorkOvertimeEnum {
    WEEKDAY(1, "weekDay"),
    REST_DAY(2, "restDay"),
    HOLIDAY(3, "holiday"),
    ;
    private final Integer channelType;
    private final String serverName;

    WorkOvertimeEnum(Integer channelType, String name) {
        this.channelType = channelType;
        this.serverName = name;
    }

    public Integer getChannelType() {
        return channelType;
    }

    public String getServerName() {
        return serverName;
    }

    public static String getEnumServerName(Integer channelType) {
        for (WorkOvertimeEnum value : WorkOvertimeEnum.values()) {
            if (value.channelType.equals(channelType)) {
                return value.serverName;
            }
        }
        return null;
    }
}
