feat: swagger format
This commit is contained in:
@@ -16,7 +16,7 @@ type PostApi struct{}
|
||||
// @Tags 帖子
|
||||
// @Summary 发布帖子
|
||||
// @Security BearerAuth
|
||||
// @accept json
|
||||
// @accept application/json
|
||||
// @Produce application/json
|
||||
// @Param data body plantReq.CreatePost true "发布帖子"
|
||||
// @Success 200 {string} string "{"success":true,"data":{},"msg":"发布成功"}"
|
||||
@@ -43,7 +43,7 @@ func (a *PostApi) PublishPost(c *gin.Context) {
|
||||
// @Tags 帖子
|
||||
// @Summary 帖子列表
|
||||
// @Security BearerAuth
|
||||
// @accept json
|
||||
// @accept application/json
|
||||
// @Produce application/json
|
||||
// @Param data body plantReq.PostPage true "分页获取帖子列表"
|
||||
// @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}"
|
||||
@@ -74,7 +74,7 @@ func (a *PostApi) PostPage(c *gin.Context) {
|
||||
// @Tags 帖子
|
||||
// @Summary 我的发布
|
||||
// @Security BearerAuth
|
||||
// @accept json
|
||||
// @accept application/json
|
||||
// @Produce application/json
|
||||
// @Param data body plantReq.PostPage true "分页获取帖子列表"
|
||||
// @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}"
|
||||
@@ -127,7 +127,7 @@ func (a *PostApi) LikePost(c *gin.Context) {
|
||||
// @Tags 帖子
|
||||
// @Summary 评论帖子
|
||||
// @Security BearerAuth
|
||||
// @accept json
|
||||
// @accept application/json
|
||||
// @Produce application/json
|
||||
// @Param data body plantReq.CreateComment true "评论帖子"
|
||||
// @Success 200 {string} string "{"success":true,"data":{},"msg":"评论成功"}"
|
||||
|
||||
Reference in New Issue
Block a user