refactor: reorganize modules and add Linux build tooling
This commit is contained in:
22
module/social/feed/internal/models/feed_post.go
Normal file
22
module/social/feed/internal/models/feed_post.go
Normal file
@@ -0,0 +1,22 @@
|
||||
package models
|
||||
|
||||
import (
|
||||
"git.apinb.com/bsm-sdk/core/types"
|
||||
)
|
||||
|
||||
// feed推文表
|
||||
type FeedPost struct {
|
||||
types.Std_IICUDS
|
||||
types.Std_Passport
|
||||
Content string `gorm:"column:content;type:text;default:'';" json:"content"` // 正文
|
||||
IsOpen bool `gorm:"column:is_open;default:true;" json:"is_open"` // 默认为true-公开,false-不公开
|
||||
CntLike int64 `gorm:"column:cnt_like;type:int;default:0;" json:"cnt_like"` // 点赞数
|
||||
CntUnlike int64 `gorm:"column:cnt_unlike;type:int;default:0;" json:"cnt_unlike"` // 点踩数
|
||||
CntComment int64 `gorm:"column:cnt_comment;type:int;default:0;" json:"cnt_comment"` // 评论数
|
||||
Attachs []FeedRelateAttach `gorm:"-"`
|
||||
Tags []FeedRelateTags `gorm:"-"`
|
||||
}
|
||||
|
||||
func (c *FeedPost) TableName() string {
|
||||
return "feed_post"
|
||||
}
|
||||
Reference in New Issue
Block a user