package com.sinata.common.enums;
|
|
import com.sinata.common.enums.base.enums.BaseEnum;
|
|
/**
|
* 用户账户详细-触发类型
|
*/
|
public enum EnumUserBankDetailDoneType implements BaseEnum {
|
|
ADD_INTEGRAL_ORDER(21, "消费增加积分"),
|
SUB_INTEGRAL_CANCEL_ORDER(24, "取消订单"),
|
ADD_INTEGRAL_SHARE(22, "推荐新用户增加积分"),
|
ADD_INTEGRAL_SHARE_COMMISSION(23, "推荐购买商品增加积分"),
|
|
MALL_GOODS_PAY(200, "商品支付"),
|
MALL_GOODS_REFUND(201, "商品退款"),
|
;
|
|
public final int index;
|
public final String mark;
|
|
EnumUserBankDetailDoneType(int index, String mark) {
|
this.index = index;
|
this.mark = mark;
|
}
|
|
public int getIndex() {
|
return index;
|
}
|
|
public String getMark() {
|
return mark;
|
}
|
|
/**
|
* 通过index查询说明
|
*/
|
public static String getMarkByIndex(Integer index) {
|
if (index != null) {
|
for (EnumUserBankDetailDoneType obj : values()) {
|
if (obj.getIndex() == index) {
|
return obj.getMark();
|
}
|
}
|
}
|
return null;
|
}
|
|
/**
|
* 通过index查询说明
|
*/
|
public static EnumUserBankDetailDoneType getMarkByEnum(Integer index) {
|
if (index != null) {
|
for (EnumUserBankDetailDoneType obj : values()) {
|
if (obj.getIndex() == index) {
|
return obj;
|
}
|
}
|
}
|
return null;
|
}
|
}
|