springboot在实体上格式化时间
@Getter
@Setter
@TableName("contact_us")
@ApiModel(value = "需求提交记录表", description = "需求提交记录表")
public class ContactUs {@ApiModelProperty("主键")@TableId("pk_id")private String pkId;@ApiModelProperty("创建时间")@TableField("create_time")@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm")@DateTimeFormat(pattern="yyyy-MM-dd HH:mm")private Date createTime;
}