package plant

import "github.com/gin-gonic/gin"

type PostRouter struct{}

func (p *PostRouter) InitPostRouter(Router *gin.RouterGroup) {
	postRouter := Router.Group("post")
	{
		// 帖子
		postRouter.POST("publish", postApi.PublishPost) // 发布帖子
		postRouter.POST("page", postApi.PostPage)       // 帖子列表
		postRouter.POST("myPost", postApi.MyPost)       // 我的发布
		postRouter.GET("like", postApi.LikePost)        // 点赞或者取消点赞
		postRouter.GET("star", postApi.StarPost)        // 收藏或者取消收藏帖子
		postRouter.POST("comment", postApi.CommentPost) // 评论
		postRouter.POST("delete", postApi.DeletePost)   // 删除帖子
		//postRouter.POST("deleteComment", postApi.delementComment) // 取消评论

	}
}
