fix: 补全 ShopProfile 和 Post 响应中缺失的后端字段
ShopProfile 补上 allowMultiShop/allowIndependentOrders/dispatchMode,Post 补上 pinned/linkedOrderId。这些字段在 RPC proto、数据库和写入逻辑中均已存在,但 API 响应类型和映射函数遗漏了它们。同时补回 community.api 中 CreateCommentReq 的 PostId 字段定义。
This commit is contained in:
+13
-10
@@ -7,16 +7,18 @@ type (
|
||||
Id int64 `path:"id"`
|
||||
}
|
||||
Post {
|
||||
Id int64 `json:"id"`
|
||||
Title string `json:"title"`
|
||||
Content string `json:"content"`
|
||||
Images []string `json:"images"`
|
||||
Tags []string `json:"tags"`
|
||||
LikeCount int64 `json:"likeCount"`
|
||||
CommentCount int64 `json:"commentCount"`
|
||||
Liked bool `json:"liked"`
|
||||
Author UserProfile `json:"author"`
|
||||
CreatedAt string `json:"createdAt"`
|
||||
Id int64 `json:"id"`
|
||||
Title string `json:"title"`
|
||||
Content string `json:"content"`
|
||||
Images []string `json:"images"`
|
||||
Tags []string `json:"tags"`
|
||||
LinkedOrderId int64 `json:"linkedOrderId,optional"`
|
||||
Pinned bool `json:"pinned"`
|
||||
LikeCount int64 `json:"likeCount"`
|
||||
CommentCount int64 `json:"commentCount"`
|
||||
Liked bool `json:"liked"`
|
||||
Author UserProfile `json:"author"`
|
||||
CreatedAt string `json:"createdAt"`
|
||||
}
|
||||
CreatePostReq {
|
||||
Title string `json:"title"`
|
||||
@@ -47,6 +49,7 @@ type (
|
||||
Meta PageMeta `json:"meta"`
|
||||
}
|
||||
CreateCommentReq {
|
||||
PostId int64 `json:"-"`
|
||||
Content string `json:"content"`
|
||||
}
|
||||
ListCommentsReq {
|
||||
|
||||
Reference in New Issue
Block a user