package cmtmod import ( "91porn-server/models/v/usermod" "go.mongodb.org/mongo-driver/bson/primitive" "time" ) // ParentRespList 列表响应信息(父评论) type ParentRespList struct { //全局唯一评论ID ID string `form:"id" json:"id"` //评论对象的ID ObjID string `form:"objID" json:"objID"` //发表评论的 用户ID UserID uint64 `form:"userID" json:"userID"` //发表评论的 用户昵称 UserName string `form:"userName" json:"userName"` //头像 URL UserPortrait string `form:"userPortrait" json:"userPortrait" ` //评论内容 Content string `form:"content" json:"content"` Image string `form:"image" json:"image"` LinkStr string `form:"linkStr" json:"linkStr" bson:"linkStr"` //跳转配置 LinkType int `form:"linkType" json:"linkType"` //1:内链,2:外链 SearchKeyword string `form:"searchKeyword" json:"searchKeyword"` //搜索关键字 //此评论点赞次数 LikeCount int `form:"likeCount" json:"likeCount"` //此评论的评论数 CommCount int `form:"commCount" json:"commCount"` //此评论的评论数,冗余 CommCountBurden int `form:"commCountBurden" json:"commCountBurden"` //是否是作者 IsAuthor bool `form:"isAuthor" json:"isAuthor" ` //是否点过赞 IsLike bool `form:"isLike" json:"isLike"` //评论者是否已关注 IsFollow bool `form:"isFollow" json:"isFollow"` //是否已删除 IsDelete bool `form:"isDelete" json:"isDelete"` IsGodComment bool `form:"isGodComment" json:"isGodComment"` //是否是神评论 //性别 Gender string `form:"gender" json:"gender"` //此评论的状态 Status int `form:"status" json:"status"` //评论地点 City string `form:"city" json:"city"` //评论时间 CreatedAt time.Time `form:"createdAt" json:"createdAt"` //年龄 Age int `json:"age"` // 引用类型 vid视频 col用户播单 sec官方播单 cover图集 QuoteType string `json:"quoteType"` // 引用id QuoteID ObjectID `json:"quoteID"` // 引用资源图片 QuoteImg string `json:"quoteImg"` // 引用资源标题 QuoteTitle string `json:"quoteTitle"` //用户vip等级 Level int `json:"level"` VipLevel int `json:"vipLevel"` Awards []int `json:"awards"` //用户奖章 AwardsExpire []usermod.AwardsExpireResp `json:"awardsExpire" bson:"awardsExpire"` //奖章是否有效 SuperUser bool `json:"superUser" bson:"superUser"` //是否大V VipExpireDate time.Time `json:"vipExpireDate" bson:"vipExpireDate"` Info []ChildRespList } // ChildRespList 列表响应信息(子评论) type ChildRespList struct { ID string `form:"id" json:"id"` //全局唯一评论ID ObjID string `form:"objID" json:"objID"` //评论对象的ID CID string `form:"cid" json:"cid"` //评论的id UserID uint64 `form:"userID" json:"userID"` //发表评论的 用户ID UserName string `form:"userName" json:"userName"` //发表评论的 用户昵称 UserPortrait string `form:"userPortrait" json:"userPortrait"` //头像 URL ToUserID uint64 `form:"toUserID" json:"toUserID"` //对某用户回复评论 用户ID ToUserName string `form:"toUserName" json:"toUserName"` //对某用户回复评论 用户昵称 Content string `form:"content" json:"content"` //评论内容 Image string `form:"image" json:"image"` LinkStr string `form:"linkStr" json:"linkStr" bson:"linkStr"` //跳转配置 LikeCount int `form:"likeCount" json:"likeCount"` //此评论点赞次数 IsLike bool `form:"isLike" json:"isLike"` //是否点过赞 IsAuthor bool `form:"isAuthor" json:"isAuthor"` //是否是作者 IsFollow bool `form:"isFollow" json:"isFollow"` //评论者是否已关注 IsDelete bool `form:"isDelete" json:"isDelete"` //是否已删除 Gender string `form:"gender" json:"gender"` //性别 Status int `form:"status" json:"status"` //此评论的状态 City string `form:"city" json:"city"` //评论地点 QuoteType string `json:"quoteType"` // 引用类型 vid视频 col用户播单 sec官方播单 QuoteID ObjectID `json:"quoteID"` // 引用id QuoteImg string `json:"quoteImg"` // 引用资源图片 QuoteTitle string `json:"quoteTitle"` // 引用资源标题 CreatedAt time.Time `form:"createdAt" json:"createdAt"` //评论时间 Age int `json:"age"` //年龄 Level int `json:"level"` //用户评论层级 1:一级评论 2:二级评论 VipLevel int `json:"vipLevel"` //用户vip等级 Awards []int `json:"awards"` //用户奖章 AwardsExpire []usermod.AwardsExpireResp `json:"awardsExpire" bson:"awardsExpire"` //奖章是否有效 SuperUser bool `json:"superUser" bson:"superUser"` //是否大V VipExpireDate time.Time `json:"vipExpireDate" bson:"vipExpireDate"` } type PublishReqInfo struct { ObjID ObjectID `form:"objID" json:"objID"` // 评论对象的ID ObjType string `form:"objType" json:"objType"` // 评论对象类型 video:视频(默认) cartoon:动漫 AiPlaza:ai广场 CID string `form:"cid" json:"cid"` // 此评论是对某条评论的评论或回复,如果为空,则为对该视频的评论 RID string `form:"rid" json:"rid"` // 被回复评论的id ToUserID uint64 `form:"toUserID" json:"toUserID"` // 对某用户回复评论 用户ID Content string `form:"content" json:"content"` // 评论内容 Level int `form:"level" json:"level"` // 评论层级 1:一级评论 2:二级评论 Image string `json:"image" form:"image"` // 图片 QuoteType string `form:"quoteType" json:"quoteType"` // 引用类型 vid视频 col用户播单 sec官方播单 cover图集 QuoteID ObjectID `form:"quoteID" json:"quoteID"` // 引用id QuoteImg string `form:"quoteImg" json:"quoteImg"` // 引用资源图片 QuoteTitle string `form:"quoteTitle" json:"quoteTitle"` // 引用资源标题 } // CmtRespList 列表响应信息 type CmtRespList struct { //全局唯一评论ID ID ObjectID `form:"id" json:"id" bson:"_id"` //评论对象的ID ObjID string `form:"objID" json:"objID"` CID string `form:"cid json:"cid"` //二级评论时,为被评论的评论id //发表评论的 用户ID UserID uint64 `form:"userID" json:"userID"` //发表评论的 用户昵称 UserName string `form:"userName" json:"userName"` //头像 URL UserPortrait string `form:"userPortrait" json:"userPortrait" ` //是否认证 SuperUser int `form:"superUser" json:"superUser"` //评论内容 Content string `form:"content" json:"content"` //此评论点赞次数 LikeCount int `form:"likeCount" json:"likeCount"` //是否点过赞 IsLike bool `form:"isLike" json:"isLike"` VipExpireDate time.Time `json:"vipExpireDate" bson:"vipExpireDate"` //评论时间 CreatedAt time.Time `form:"createdAt" json:"createdAt"` //用户vip等级 Level int `json:"level"` VipLevel int `json:"vipLevel" bson:"vipLevel"` Info []CmtRespList } // MyCmtResp 列表响应信息(父评论) type MyCmtResp struct { List []MyCmt `json:"list"` HasNext bool `json:"hasNext"` } type MyCmt struct { // 全局唯一评论ID ID primitive.ObjectID `bson:"_id" json:"id"` // 评论对象的ID 帖子id ObjID primitive.ObjectID `bson:"objID" json:"objID"` // 评论内容 Content string `bson:"content" json:"content"` // 此评论点赞次数 LikeCount int `bson:"likeCount" json:"likeCount"` // 是否是神评论 IsGodComment bool `bson:"isGodComment" json:"isGodComment"` // 帖子标题 VidTitle string `json:"vidTitle"` // 帖子封面 VidCover string `json:"vidCover"` //评论时间 CreatedAt time.Time `bson:"createdAt" json:"createdAt"` }