feat: 更新评论和帖子模型,添加用户信息和原创标识,优化API请求和组件结构

This commit is contained in:
2025-07-28 06:22:07 +08:00
parent 5c20a310e3
commit d73ed493be
20 changed files with 260 additions and 181 deletions

View File

@ -102,13 +102,12 @@ func (cc *CommentController) GetCommentList(ctx context.Context, c *app.RequestC
resps.BadRequest(c, "无效的 target_id")
return
}
req := dto.GetCommentListReq{
Desc: pagination.Desc,
OrderBy: pagination.OrderBy,
Page: pagination.Page,
Size: pagination.Size,
TargetID: uint(targetID),
Desc: pagination.Desc,
OrderBy: pagination.OrderBy,
Page: pagination.Page,
Size: pagination.Size,
TargetID: uint(targetID),
TargetType: c.Query("target_type"),
}
resp, err := cc.service.GetCommentList(ctx, &req)
@ -120,4 +119,6 @@ func (cc *CommentController) GetCommentList(ctx context.Context, c *app.RequestC
resps.Ok(c, resps.Success, resp)
}
func (cc *CommentController) ReactComment(ctx context.Context, c *app.RequestContext) {}
func (cc *CommentController) ReactComment(ctx context.Context, c *app.RequestContext) {
}