package com.engine.salary.enums.salaryarchive;

import org.apache.commons.lang3.StringUtils;

/**
 * 薪资档案列表类型
 * <p>Copyright: Copyright (c) 2022</p>
 * <p>Company: 泛微软件</p>
 *
 * @author qiantao
 * @version 1.0
 **/
public enum SalaryArchiveListTypeEnum {

    PENDING("PENDING", "待定薪", 107875),
    FIXED("FIXED", "发薪", 109713),
    SUSPEND("SUSPEND", "待停薪", 107879),
    STOP("STOP", "停薪", 109348),
    EXT("EXT", "非系统人员", 109348);

    private String value;

    private String defaultLabel;

    private int labelId;

    SalaryArchiveListTypeEnum(String value, String defaultLabel, int labelId) {
        this.value = value;
        this.defaultLabel = defaultLabel;
        this.labelId = labelId;
    }

    public String getValue() {
        return value;
    }

    public String getDefaultLabel() {
        return defaultLabel;
    }

    public int getLabelId() {
        return labelId;
    }

    public static SalaryArchiveListTypeEnum parseByValue(String value) {
        for (SalaryArchiveListTypeEnum enums : SalaryArchiveListTypeEnum.values()) {
            if (StringUtils.equals(enums.getValue(), value)) {
                return enums;
            }
        }
        return null;
    }
}
