blob: fcf42055633ef63f6d5ac2d77a374053bc888c66 [file] [log] [blame]
223011381c359102025-06-03 15:19:59 +08001package com.example.myproject.entity;
2
3import javax.persistence.*;
4import java.util.Date;
5
6@Entity
7@Table(name = "group_comments")
8public class GroupComments {
9
10 @Id
11 @GeneratedValue(strategy = GenerationType.IDENTITY)
12 @Column(name = "comment_id")
13 private Long commentId; // 评论ID
14
15 @Column(name = "group_post_id")
16 private Long groupPostId;
17
18 @Column(name = "user_id")
19 private Long userId;
20
21 private String content;
22
23 @Column(name = "parent_comment_id")
24 private Long parentCommentId;
25
26 @Column(name = "time")
27 private Date time; // 评论时间
28
29 // Getters and Setters
30 public Long getCommentId() {
31 return commentId;
32 }
33
34 public void setCommentId(Long commentId) {
35 this.commentId = commentId;
36 }
37
38 public Long getGroupPostId() {
39 return groupPostId;
40 }
41
42 public void setGroupPostId(Long groupPostId) {
43 this.groupPostId = groupPostId;
44 }
45
46 public Long getUserId() {
47 return userId;
48 }
49
50 public void setUserId(Long userId) {
51 this.userId = userId;
52 }
53
54 public String getContent() {
55 return content;
56 }
57
58 public void setContent(String content) {
59 this.content = content;
60 }
61
62 public Long getParentCommentId() {
63 return parentCommentId;
64 }
65
66 public void setParentCommentId(Long parentCommentId) {
67 this.parentCommentId = parentCommentId;
68 }
69
70 public Date getTime() {
71 return time;
72 }
73
74 public void setTime(Date time) {
75 this.time = time;
76 }
77}