spring版本:4.2.5.RELEASE 查看“org.springframework.http.converter.StringHttpMessageConverter”源码,中有一段说明: By ;&#;&#;}), and writes with a {@code Content-Type} of {@code text/plain}. This can be overridden by setting the {@link #setSupportedMediaTypes sup
一:需求背景 在业务开发中经常会有这个一个场景,A(业务表)表中会记录数据的创建人,通常我们会用userId字段记录该数据的创建者,但数据的使用方会要求展示该数据的创建者姓名,故我们会关联用户表拿该用户的姓名.还有一些枚举值的含义也要展示给前端.导致原本一个单表的sql就要写成多表的关联sql,以及枚举含义的转换很是恶心. 例如:业务对象BusinessEntity.java public class BusinessEntity { /** * 创建者id */ private Long cr