-
导入界面和静态资源文件
-
编写实体类
以
com.llanero.news.po.News
类为例@Entity @Table(name = "t_news") public class News { @Id @GeneratedValue(strategy = GenerationType.IDENTITY) private Long id; private String title; @Basic(fetch = FetchType.LAZY) @Lob private String content; private String firstPicture; private String flag; private String views; private boolean appreciation; private boolean shareStatement; private boolean commenttabled; private boolean published; private boolean recommend; @Temporal(TemporalType.TIMESTAMP) private Date createTime; @Temporal(TemporalType.TIMESTAMP) private Date updateTime; @ManyToOne private Type type; @ManyToOne private User user; public News() { } public Long getId() { return id; } public void setId(Long id) { this.id = id; } public String getTitle() { return title; } public void setTitle(String title) { this.title = title; } public String getContent() { return content; } public void setContent(String content) { this.content = content; } public String getFirstPicture() { return firstPicture; } public void setFirstPicture(String firstPicture) { this
Spring boot登录实例
最新推荐文章于 2023-06-20 18:53:37 发布