跳到主要内容

@Excel字典翻译

  • 字典翻译
/**  
* 学生性别
*/
@Excel(name = "学生性别", replace = { "男_1", "女_2" }, suffix = "生", isImportField = "true_st")
private int sex;
  • 字典翻译 需要字段翻译的,dictCode对应jeecg系统的字典编码 数据库存储的是字典的值,导入导出时显示字典的文本
@Excel(name = "性别", width = 25,dicCode="sex")
private Integer sex;
  • 表字典翻译 需要字段翻译的,dictTable 对应jeecg系统的表名、dicText 对应表的显示字段、dicCode 对应保存的值字段 数据库存储的是字典的值,导入导出时显示字典的文本
@Excel(name="负责部门",width = 25,dictTable ="sys_depart",dicText = "depart_name",dicCode = "id")
private String departIds;