package com.hfkj.sysenum;

import java.util.Objects;

/**
 * @className: MerLedgerStatusEnum
 * @author: HuRui
 * @date: 2023/4/18
 **/
public enum ProfitSharingStatusEnum {
    status0(0, "待处理"),
    status1(1, "已完成"),
    status2(2, "处理中"),
    status3(3, "已受理"),
    status4(4, "失败"),
    ;

    private Integer number;

    private String name;


    ProfitSharingStatusEnum(int number, String name) {
        this.number = number;
        this.name = name;
    }

    public static ProfitSharingStatusEnum getDataByNumber(Integer number) {
        for (ProfitSharingStatusEnum ele : values()) {
            if (Objects.equals(number,ele.getNumber())) {
                return ele;
            }
        }
        return null;
    }

    public Integer getNumber() {
        return number;
    }

    public void setNumber(Integer number) {
        this.number = number;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

}
