//从数据库取出解析成json
@TableName(value = "submit",autoResultMap = true)
public class Text {
@TableId(value = "id",type = IdType.AUTO)
private String id;
private String title;
//放入数据库解析成json
@TableField(typeHandler = FastjsonTypeHandler.class)
private List<String> list;
}
结果如下
{
"id": "3",
"title": "CAP-3 首次氧合评估情况",
"list": [
"123",
"456"
]
}