package com.ots.common.enums;
|
|
/**
|
* @author zhijie
|
* @date 2021/03/19
|
* @Description: 报告邮件标题类
|
*/
|
public enum ReportTitle {
|
ZH("姓名","Chinese", "%s的%s测评报告附上了"),
|
US("Name","English", "%s's %s Report Is Attached"),
|
TAI("ชื่อ","Thai", "รายงานการประเมิน %s ของ %s"),
|
;
|
public final String field;
|
public final String langType;
|
public final String reportTitle;
|
|
|
|
ReportTitle(String field,String langType, String reportTitle) {
|
this.field = field;
|
this.langType = langType;
|
this.reportTitle = reportTitle;
|
}
|
|
public static String getReportTitle(String langType) {
|
ReportTitle[] types = ReportTitle.values();
|
for (ReportTitle type : types) {
|
if (type.langType.equals(langType)) {
|
return type.reportTitle;
|
}
|
}
|
return "";
|
}
|
|
public static String getField(String langType) {
|
ReportTitle[] types = ReportTitle.values();
|
for (ReportTitle type : types) {
|
if (type.langType.equals(langType)) {
|
return type.field;
|
}
|
}
|
return "";
|
}
|
}
|