natsio/model/social_post_response.go

62 lines
1.9 KiB
Go
Raw Normal View History

2022-11-14 07:45:26 +00:00
package model
import (
"go.mongodb.org/mongo-driver/bson/primitive"
"time"
)
// ResponseListSocialPostAppInfo ...
type ResponseListSocialPostAppInfo struct {
SocialPosts []SocialPostAppInfo `json:"socialPosts"`
}
// SocialPostAppInfo ...
type SocialPostAppInfo struct {
ID primitive.ObjectID `json:"_id"`
Title string `json:"title"`
Content string `json:"content"`
Statistic SocialPostStatistic `json:"statistic"`
Author *SocialPostSellerInfo `json:"author"`
Photos ListPhoto `json:"photos"`
PublishedAt time.Time `json:"publishedAt"`
IsLiked bool `json:"isLiked"`
IsPin bool `json:"isPin"`
Contributor *SocialPostSellerInfo `json:"contributor"`
CreatedAt time.Time `json:"createdAt"`
Status string `json:"status"`
HasUpdate bool `json:"hasUpdate"`
Order int `json:"order"`
Videos ListVideo `json:"videos"`
}
// SocialPostStatistic ...
type SocialPostStatistic struct {
Views int `json:"views"`
UniqueViews int `json:"uniqueViews"`
Likes int `json:"likes"`
Shares int `json:"shares"`
UniqueShares int `json:"uniqueShares"`
Comments int `json:"comments"`
}
// SocialPostSellerInfo ...
type SocialPostSellerInfo struct {
ID primitive.ObjectID `json:"_id"`
Name string `json:"name"`
Membership SellerMembershipInfo `json:"membership"`
2022-11-23 09:54:31 +00:00
Logo *FilePhoto `json:"avatar"`
2022-11-14 07:45:26 +00:00
IsMine bool `json:"isMine"`
}
2022-11-16 09:38:41 +00:00
2022-11-16 10:33:29 +00:00
// ResponseListSocialPostAdminInfo ...
type ResponseListSocialPostAdminInfo struct {
SocialPosts []SocialPostAdminInfo `json:"socialPosts"`
2022-11-16 09:38:41 +00:00
}
2022-11-17 02:27:45 +00:00
// SocialPostAdminInfo ...
2022-11-16 09:38:41 +00:00
type SocialPostAdminInfo struct {
ID primitive.ObjectID `json:"_id"`
Title string `json:"title"`
Status string `json:"status"`
}