comment.go
1.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
package protocol
const (
SourceType_Chance = 1
SourceType_Comment = 2
)
/*IComment */
type ICommentRequest struct {
Content string `json:"content" valid:"Required"`
SourceType int `json:"type" valid:"Required"`
Id int64 `json:"id" valid:"Required"`
}
type ICommentResponse struct {
Id int64 `json:"id"`
Provider *BaseUserInfo `json:"provider"`
CreateTime int64 `json:"createTime"`
Content string `json:"content"`
}
/*IComments */
type ICommentsRequest struct {
LastId int `json:"lastId"`
PageSize int `json:"pageSize" valid:"Required"`
}
type ICommentsResponse struct {
Comments []*IComments `json:"comments"`
Total int `json:"total"`
}
type IComments struct {
//question `json:"question"`
Comment *ICommentResponse `json:"comment"`
}
/*机会评论*/
type CommentsRequest struct {
LastId int `json:"lastId"`
PageSize int `json:"pageSize" valid:"Required"`
SourceId int64 `json:"id" valid:"Required"`
}
type CommentsResponse struct {
Total int `json:"total"`
Comments []*Comments `json:"comments"`
}
/*评论列表*/
type Comments struct {
Id int64 `json:"id"`
Provider *BaseUserInfo `json:"provider"`
Content string `json:"content"`
ViewTotal int `json:"pageView"`
CommentTotal int `json:"commentTotal"`
ZanTotal int `json:"zanTotal"`
CreateTime int64 `json:"createTime"`
}