fix: int64 ID 字段序列化为 JSON string
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
package types
|
||||
|
||||
type Comment struct {
|
||||
Id int64 `json:"id"`
|
||||
Id int64 `json:"id,string"`
|
||||
Content string `json:"content"`
|
||||
Author UserProfile `json:"author"`
|
||||
LikeCount int64 `json:"likeCount"`
|
||||
@@ -54,12 +54,12 @@ type PathId struct {
|
||||
}
|
||||
|
||||
type Post struct {
|
||||
Id int64 `json:"id"`
|
||||
Id int64 `json:"id,string"`
|
||||
Title string `json:"title"`
|
||||
Content string `json:"content"`
|
||||
Images []string `json:"images"`
|
||||
Tags []string `json:"tags"`
|
||||
LinkedOrderId int64 `json:"linkedOrderId,optional"`
|
||||
LinkedOrderId int64 `json:"linkedOrderId,string,optional"`
|
||||
Pinned bool `json:"pinned"`
|
||||
LikeCount int64 `json:"likeCount"`
|
||||
CommentCount int64 `json:"commentCount"`
|
||||
|
||||
Reference in New Issue
Block a user