This commit is contained in:
dute7liang
2024-01-29 21:29:17 +08:00
parent e200a7bac3
commit ea111d983e
21 changed files with 399 additions and 14 deletions

View File

@@ -9,6 +9,7 @@ public enum SystemPushTypeEnum {
TEXT(1,"文本消息"),
SIMPLE_IMAGE_TEXT(2,"单图文消息"),
IMAGE_TEXT(3,"多图文消息"),
ONLY_IMAGE(4,"纯图文消息"),
;
private final Integer code;
private final String text;
@@ -17,4 +18,14 @@ public enum SystemPushTypeEnum {
this.code = code;
this.text = text;
}
public static SystemPushTypeEnum getByCode(Integer type) {
SystemPushTypeEnum[] values = SystemPushTypeEnum.values();
for (SystemPushTypeEnum value : values) {
if(value.getCode().equals(type)){
return value;
}
}
return null;
}
}