package com.yuchen.saas.manage.user.api.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;


@Getter
@AllArgsConstructor
public enum AccountStatusEnum {

	
	NOT_DISABLE(0, "正常"),

	
	DISABLE(1, "禁用")
	;

	final Integer type;
	final String name;


	public static AccountStatusEnum of(Integer type) {
		if (type == null) {
			return null;
		}
		AccountStatusEnum[] values = AccountStatusEnum.values();
		for (AccountStatusEnum smsEnum : values) {
			if (smsEnum.type.equals(type)) {
				return smsEnum;
			}
		}
		return NOT_DISABLE;
	}

}
