package com.inkasso.factoring.common.enums;

import lombok.Getter;


@Getter
public enum AssessStatusEnum {

    TO_BE_PAID("assessStatusToBePaid","待支付"),

    TO_BE_GENERATED("assessStatusToBeGenerated","评估中"),

    GENERATED("assessStatusGenerated","已生成"),

    RETURNED("assessStatusReturned","已退回"),

    REJECTED("assessStatusRejected","事故车拒评");

    String code;

    String desc;

    AssessStatusEnum(String code, String desc){
        this.code = code;
        this.desc = desc;
    }

    public static AssessStatusEnum getByCode(String code){
        for(AssessStatusEnum ft:values()){
            if(ft.code.equals(code)){
                return ft;
            }
        }
        return null;
    }
}
