controller

package
v0.0.0-...-b32e05d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 13, 2025 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AlbumController

type AlbumController struct {
	// contains filtered or unexported fields
}

func NewAlbumController

func NewAlbumController(svcCtx *svctx.ServiceContext) *AlbumController

func (*AlbumController) FindAlbumList

func (s *AlbumController) FindAlbumList(c *gin.Context)

@Tags Album @Summary "获取相册列表" @accept application/json @Produce application/json @Param data body dto.AlbumQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/album/find_album_list [POST]

func (*AlbumController) FindPhotoList

func (s *AlbumController) FindPhotoList(c *gin.Context)

@Tags Album @Summary "获取相册下的照片列表" @accept application/json @Produce application/json @Param data body dto.PhotoQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/album/find_photo_list [POST]

func (*AlbumController) GetAlbum

func (s *AlbumController) GetAlbum(c *gin.Context)

@Tags Album @Summary "获取相册" @accept application/json @Produce application/json @Param data body dto.IdReq true "请求参数" @Success 200 {object} response.Body{data=dto.Album} "返回信息" @Router /api/v1/album/get_album [POST]

type ArticleController

type ArticleController struct {
	// contains filtered or unexported fields
}

func NewArticleController

func NewArticleController(svcCtx *svctx.ServiceContext) *ArticleController

func (*ArticleController) FindArticleArchives

func (s *ArticleController) FindArticleArchives(c *gin.Context)

@Tags Article @Summary "文章归档(时间轴)" @accept application/json @Produce application/json @Param data body dto.ArticleArchivesQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/article/get_article_archives [POST]

func (*ArticleController) FindArticleClassifyCategory

func (s *ArticleController) FindArticleClassifyCategory(c *gin.Context)

@Tags Article @Summary "通过分类获取文章列表" @accept application/json @Produce application/json @Param data body dto.ArticleClassifyQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/article/get_article_classify_category [POST]

func (*ArticleController) FindArticleClassifyTag

func (s *ArticleController) FindArticleClassifyTag(c *gin.Context)

@Tags Article @Summary "通过标签获取文章列表" @accept application/json @Produce application/json @Param data body dto.ArticleClassifyQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/article/get_article_classify_tag [POST]

func (*ArticleController) FindArticleHomeList

func (s *ArticleController) FindArticleHomeList(c *gin.Context)

@Tags Article @Summary "获取首页文章列表" @accept application/json @Produce application/json @Param data body dto.ArticleHomeQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/article/get_article_home_list [POST]

func (*ArticleController) FindArticleRecommend

func (s *ArticleController) FindArticleRecommend(c *gin.Context)

@Tags Article @Summary "获取首页推荐文章列表" @accept application/json @Produce application/json @Param data body dto.EmptyReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/article/get_article_recommend [POST]

func (*ArticleController) GetArticleDetails

func (s *ArticleController) GetArticleDetails(c *gin.Context)

@Tags Article @Summary "获取文章详情" @accept application/json @Produce application/json @Param data body dto.IdReq true "请求参数" @Success 200 {object} response.Body{data=dto.ArticleDetails} "返回信息" @Router /api/v1/article/get_article_details [POST]

func (*ArticleController) LikeArticle

func (s *ArticleController) LikeArticle(c *gin.Context)

@Tags Article @Summary "点赞文章" @accept application/json @Produce application/json @Param data body dto.IdReq true "请求参数" @Success 200 {object} response.Body{data=dto.EmptyResp} "返回信息" @Router /api/v1/article/like_article [POST]

type AuthController

type AuthController struct {
	// contains filtered or unexported fields
}

func NewAuthController

func NewAuthController(svcCtx *svctx.ServiceContext) *AuthController

func (*AuthController) BindUserEmail

func (s *AuthController) BindUserEmail(c *gin.Context)

@Tags Auth @Summary "绑定邮箱" @accept application/json @Produce application/json @Param data body dto.BindUserEmailReq true "请求参数" @Success 200 {object} response.Body{data=dto.EmptyResp} "返回信息" @Router /api/v1/bind_user_email [POST]

func (*AuthController) Login

func (s *AuthController) Login(c *gin.Context)

@Tags Auth @Summary "登录" @accept application/json @Produce application/json @Param data body dto.LoginReq true "请求参数" @Success 200 {object} response.Body{data=dto.LoginResp} "返回信息" @Router /api/v1/login [POST]

func (*AuthController) Logoff

func (s *AuthController) Logoff(c *gin.Context)

@Tags Auth @Summary "注销" @accept application/json @Produce application/json @Param data body dto.EmptyReq true "请求参数" @Success 200 {object} response.Body{data=dto.EmptyResp} "返回信息" @Router /api/v1/logoff [POST]

func (*AuthController) Logout

func (s *AuthController) Logout(c *gin.Context)

@Tags Auth @Summary "登出" @accept application/json @Produce application/json @Param data body dto.EmptyReq true "请求参数" @Success 200 {object} response.Body{data=dto.EmptyResp} "返回信息" @Router /api/v1/logout [POST]

func (*AuthController) OauthAuthorizeUrl

func (s *AuthController) OauthAuthorizeUrl(c *gin.Context)

@Tags Auth @Summary "第三方登录授权地址" @accept application/json @Produce application/json @Param data body dto.OauthLoginReq true "请求参数" @Success 200 {object} response.Body{data=dto.OauthLoginUrlResp} "返回信息" @Router /api/v1/oauth_authorize_url [POST]

func (*AuthController) OauthLogin

func (s *AuthController) OauthLogin(c *gin.Context)

@Tags Auth @Summary "第三方登录" @accept application/json @Produce application/json @Param data body dto.OauthLoginReq true "请求参数" @Success 200 {object} response.Body{data=dto.LoginResp} "返回信息" @Router /api/v1/oauth_login [POST]

func (*AuthController) Register

func (s *AuthController) Register(c *gin.Context)

@Tags Auth @Summary "注册" @accept application/json @Produce application/json @Param data body dto.RegisterReq true "请求参数" @Success 200 {object} response.Body{data=dto.EmptyResp} "返回信息" @Router /api/v1/register [POST]

func (*AuthController) ResetPassword

func (s *AuthController) ResetPassword(c *gin.Context)

@Tags Auth @Summary "重置密码" @accept application/json @Produce application/json @Param data body dto.ResetPasswordReq true "请求参数" @Success 200 {object} response.Body{data=dto.EmptyResp} "返回信息" @Router /api/v1/user/reset_password [POST]

func (*AuthController) SendBindEmail

func (s *AuthController) SendBindEmail(c *gin.Context)

@Tags Auth @Summary "发送绑定邮箱验证码" @accept application/json @Produce application/json @Param data body dto.UserEmailReq true "请求参数" @Success 200 {object} response.Body{data=dto.EmptyResp} "返回信息" @Router /api/v1/send_bind_email [POST]

func (*AuthController) SendRegisterEmail

func (s *AuthController) SendRegisterEmail(c *gin.Context)

@Tags Auth @Summary "发送注册账号邮件" @accept application/json @Produce application/json @Param data body dto.UserEmailReq true "请求参数" @Success 200 {object} response.Body{data=dto.EmptyResp} "返回信息" @Router /api/v1/send_register_email [POST]

func (*AuthController) SendResetEmail

func (s *AuthController) SendResetEmail(c *gin.Context)

@Tags Auth @Summary "发送重置密码邮件" @accept application/json @Produce application/json @Param data body dto.UserEmailReq true "请求参数" @Success 200 {object} response.Body{data=dto.EmptyResp} "返回信息" @Router /api/v1/user/send_reset_email [POST]

type BannerController

type BannerController struct {
	// contains filtered or unexported fields
}

func NewBannerController

func NewBannerController(svcCtx *svctx.ServiceContext) *BannerController

func (*BannerController) FindBannerList

func (s *BannerController) FindBannerList(c *gin.Context)

@Tags Banner @Summary "分页获取页面列表" @accept application/json @Produce application/json @Param data body dto.BannerQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/banner/find_banner_list [POST]

type CategoryController

type CategoryController struct {
	// contains filtered or unexported fields
}

func NewCategoryController

func NewCategoryController(svcCtx *svctx.ServiceContext) *CategoryController

func (*CategoryController) FindCategoryList

func (s *CategoryController) FindCategoryList(c *gin.Context)

@Tags Category @Summary "分页获取文章分类列表" @accept application/json @Produce application/json @Param data body dto.CategoryQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/category/find_category_list [POST]

type ChatController

type ChatController struct {
	// contains filtered or unexported fields
}

func NewChatController

func NewChatController(svcCtx *svctx.ServiceContext) *ChatController

func (*ChatController) GetChatMessages

func (s *ChatController) GetChatMessages(c *gin.Context)

@Tags Chat @Summary "查询聊天记录" @accept application/json @Produce application/json @Param data body dto.ChatMessageQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/chat/messages [POST]

type CommentController

type CommentController struct {
	// contains filtered or unexported fields
}

func NewCommentController

func NewCommentController(svcCtx *svctx.ServiceContext) *CommentController

func (*CommentController) AddComment

func (s *CommentController) AddComment(c *gin.Context)

@Tags Comment @Summary "创建评论" @accept application/json @Produce application/json @Param data body dto.CommentNewReq true "请求参数" @Success 200 {object} response.Body{data=dto.Comment} "返回信息" @Router /api/v1/comment/add_comment [POST]

func (*CommentController) FindCommentList

func (s *CommentController) FindCommentList(c *gin.Context)

@Tags Comment @Summary "查询评论列表" @accept application/json @Produce application/json @Param data body dto.CommentQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/comment/find_comment_list [POST]

func (*CommentController) FindCommentRecentList

func (s *CommentController) FindCommentRecentList(c *gin.Context)

@Tags Comment @Summary "查询最新评论回复列表" @accept application/json @Produce application/json @Param data body dto.CommentQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/comment/find_comment_recent_list [POST]

func (*CommentController) FindCommentReplyList

func (s *CommentController) FindCommentReplyList(c *gin.Context)

@Tags Comment @Summary "查询评论回复列表" @accept application/json @Produce application/json @Param data body dto.CommentQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/comment/find_comment_reply_list [POST]

func (*CommentController) LikeComment

func (s *CommentController) LikeComment(c *gin.Context)

@Tags Comment @Summary "点赞评论" @accept application/json @Produce application/json @Param data body dto.IdReq true "请求参数" @Success 200 {object} response.Body{data=dto.EmptyResp} "返回信息" @Router /api/v1/comment/like_comment [POST]

type CommonController

type CommonController struct {
	// contains filtered or unexported fields
}

func NewCommonController

func NewCommonController(svcCtx *svctx.ServiceContext) *CommonController

func (*CommonController) Ping

func (s *CommonController) Ping(c *gin.Context)

@Tags Common @Summary "ping" @accept application/json @Produce application/json @Param data body dto.PingReq true "请求参数" @Success 200 {object} response.Body{data=dto.PingResp} "返回信息" @Router /api/v1/ping [GET]

type FileController

type FileController struct {
	// contains filtered or unexported fields
}

func NewFileController

func NewFileController(svcCtx *svctx.ServiceContext) *FileController

func (*FileController) MultiUploadFile

func (s *FileController) MultiUploadFile(c *gin.Context)

@Tags File @Summary "上传文件列表" @accept application/json @Produce application/json @Param data body dto.MultiUploadFileReq true "请求参数" @Success 200 {object} response.Body{data=[]dto.FileBackDTO} "返回信息" @Router /api/v1/file/multi_upload_file [POST]

func (*FileController) UploadFile

func (s *FileController) UploadFile(c *gin.Context)

@Tags File @Summary "上传文件" @accept application/json @Produce application/json @Param data body dto.UploadFileReq true "请求参数" @Success 200 {object} response.Body{data=dto.FileBackDTO} "返回信息" @Router /api/v1/file/upload_file [POST]

type FriendController

type FriendController struct {
	// contains filtered or unexported fields
}

func NewFriendController

func NewFriendController(svcCtx *svctx.ServiceContext) *FriendController

func (*FriendController) FindFriendList

func (s *FriendController) FindFriendList(c *gin.Context)

@Tags Friend @Summary "分页获取友链列表" @accept application/json @Produce application/json @Param data body dto.FriendQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/friend_link/find_friend_list [POST]

type RemarkController

type RemarkController struct {
	// contains filtered or unexported fields
}

func NewRemarkController

func NewRemarkController(svcCtx *svctx.ServiceContext) *RemarkController

func (*RemarkController) AddRemark

func (s *RemarkController) AddRemark(c *gin.Context)

@Tags Remark @Summary "创建留言" @accept application/json @Produce application/json @Param data body dto.RemarkNewReq true "请求参数" @Success 200 {object} response.Body{data=dto.Remark} "返回信息" @Router /api/v1/remark/add_remark [POST]

func (*RemarkController) FindRemarkList

func (s *RemarkController) FindRemarkList(c *gin.Context)

@Tags Remark @Summary "分页获取留言列表" @accept application/json @Produce application/json @Param data body dto.RemarkQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/remark/find_remark_list [POST]

type TagController

type TagController struct {
	// contains filtered or unexported fields
}

func NewTagController

func NewTagController(svcCtx *svctx.ServiceContext) *TagController

func (*TagController) FindTagList

func (s *TagController) FindTagList(c *gin.Context)

@Tags Tag @Summary "分页获取标签列表" @accept application/json @Produce application/json @Param data body dto.TagQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/tag/find_tag_list [POST]

type TalkController

type TalkController struct {
	// contains filtered or unexported fields
}

func NewTalkController

func NewTalkController(svcCtx *svctx.ServiceContext) *TalkController

func (*TalkController) FindTalkList

func (s *TalkController) FindTalkList(c *gin.Context)

@Tags Talk @Summary "分页获取说说列表" @accept application/json @Produce application/json @Param data body dto.TalkQueryReq true "请求参数" @Success 200 {object} response.Body{data=dto.PageResp} "返回信息" @Router /api/v1/talk/find_talk_list [POST]

func (*TalkController) GetTalk

func (s *TalkController) GetTalk(c *gin.Context)

@Tags Talk @Summary "查询说说" @accept application/json @Produce application/json @Param data body dto.IdReq true "请求参数" @Success 200 {object} response.Body{data=dto.Talk} "返回信息" @Router /api/v1/talk/get_talk [POST]

func (*TalkController) LikeTalk

func (s *TalkController) LikeTalk(c *gin.Context)

@Tags Talk @Summary "点赞说说" @accept application/json @Produce application/json @Param data body dto.IdReq true "请求参数" @Success 200 {object} response.Body{data=dto.EmptyResp} "返回信息" @Router /api/v1/talk/like_talk [PUT]

type UserController

type UserController struct {
	// contains filtered or unexported fields
}

func NewUserController

func NewUserController(svcCtx *svctx.ServiceContext) *UserController

func (*UserController) GetUserInfo

func (s *UserController) GetUserInfo(c *gin.Context)

@Tags User @Summary "获取用户信息" @accept application/json @Produce application/json @Param data body dto.EmptyReq true "请求参数" @Success 200 {object} response.Body{data=dto.UserInfoResp} "返回信息" @Router /api/v1/user/get_user_info [GET]

func (*UserController) GetUserLike

func (s *UserController) GetUserLike(c *gin.Context)

@Tags User @Summary "获取用户点赞列表" @accept application/json @Produce application/json @Param data body dto.EmptyReq true "请求参数" @Success 200 {object} response.Body{data=dto.UserLikeResp} "返回信息" @Router /api/v1/user/get_user_like [GET]

func (*UserController) UpdateUserAvatar

func (s *UserController) UpdateUserAvatar(c *gin.Context)

@Tags User @Summary "修改用户头像" @accept application/json @Produce application/json @Param data body dto.UpdateUserAvatarReq true "请求参数" @Success 200 {object} response.Body{data=dto.EmptyResp} "返回信息" @Router /api/v1/user/update_user_avatar [POST]

func (*UserController) UpdateUserInfo

func (s *UserController) UpdateUserInfo(c *gin.Context)

@Tags User @Summary "修改用户信息" @accept application/json @Produce application/json @Param data body dto.UpdateUserInfoReq true "请求参数" @Success 200 {object} response.Body{data=dto.EmptyResp} "返回信息" @Router /api/v1/user/update_user_info [POST]

type WebsiteController

type WebsiteController struct {
	// contains filtered or unexported fields
}

func NewWebsiteController

func NewWebsiteController(svcCtx *svctx.ServiceContext) *WebsiteController

func (*WebsiteController) GetAboutMe

func (s *WebsiteController) GetAboutMe(c *gin.Context)

@Tags Website @Summary "获取关于我的信息" @accept application/json @Produce application/json @Param data body dto.GetAboutMeReq true "请求参数" @Success 200 {object} response.Body{data=dto.GetAboutMeResp} "返回信息" @Router /api/v1/blog/about_me [GET]

func (*WebsiteController) GetBlogHomeInfo

func (s *WebsiteController) GetBlogHomeInfo(c *gin.Context)

@Tags Website @Summary "获取博客前台首页信息" @accept application/json @Produce application/json @Param data body dto.GetBlogHomeInfoReq true "请求参数" @Success 200 {object} response.Body{data=dto.GetBlogHomeInfoResp} "返回信息" @Router /api/v1/blog [GET]

type WebsocketController

type WebsocketController struct {
	// contains filtered or unexported fields
}

func NewWebsocketController

func NewWebsocketController(svcCtx *svctx.ServiceContext) *WebsocketController

func (*WebsocketController) WebSocket

func (s *WebsocketController) WebSocket(c *gin.Context)

@Tags Websocket @Summary "WebSocket消息" @accept application/json @Produce application/json @Router /api/v1/websocket [GET]

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL