article_comment.go 1.1 KB
package domain

import "time"

// 文章评论
type ArticleComment struct {
	Id               int64     // 评论id
	UpdatedAt        time.Time // 更新时间
	DeletedAt        *time.Time
	CreatedAt        time.Time
	Pid              int64       // 对哪个评论进行回复
	TopId            int64       // 归属于最上级的哪个评论
	ArticleId        int64       // 文章id
	ArticleSectionId int64       // 文本内容id
	SectionContent   string      // 引用的文章内容文本
	FromUserId       int64       // 谁填写的评论
	FromUser         CommentUser // 谁填写的评论
	ToUserId         int64       // 回复谁的评论
	ToUser           CommentUser // 回复谁的评论
	Content          string      // 评论内容
	CountReply       int         // 回复数量
	CountUserLove    int         // 用户点赞数量
	CountAdminLove   int         // 运营点赞数量
	// ...more
}

// 评论的填写人
type CommentUser struct {
	Id     int64  // 人员id
	Name   string // 人员的名字
	Avatar string // 人员头像URL
	Group  string // 人员的分组
}