Documentation ¶
Index ¶
- type ArticleCreateReq
- type ArticleCreateRes
- type ArticleDeleteReq
- type ArticleDeleteRes
- type ArticleListReq
- type ArticleListRes
- type ArticleUpdateReq
- type ArticleUpdateRes
- type CommentCreateReq
- type CommentCreateRes
- type CommentDeleteReq
- type CommentDeleteRes
- type CommentListReq
- type CommentListRes
- type CommentUpdateReq
- type CommentUpdateRes
- type TagAllReq
- type TagAllRes
- type TagCreateReq
- type TagCreateRes
- type TagDeleteReq
- type TagDeleteRes
- type TagListReq
- type TagListRes
- type TagUpdateReq
- type TagUpdateRes
- type UserChangePwdReq
- type UserChangePwdRes
- type UserCreateReq
- type UserCreateRes
- type UserDeleteReq
- type UserDeleteRes
- type UserListReq
- type UserListRes
- type UserUpdateReq
- type UserUpdateRes
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ArticleCreateReq ¶
type ArticleCreateReq struct { Title string `json:"title" form:"title" binding:"required,min=1,max=255"` Sketch string `json:"sketch" form:"sketch" binding:"min=0,max=255"` Content string `json:"content" form:"content" binding:"required,min=1,max=65535"` TagId int `json:"tagId" form:"tagId" binding:"required,min=1"` Weight int `json:"weight" form:"weight" binding:"min=0,max=100"` ArticleStatus int `json:"articleStatus" form:"articleStatus" binding:"required,min=1,max=2"` }
ArticleCreateReq 文章创建
type ArticleCreateRes ¶
type ArticleCreateRes struct {
Id int `json:"id"`
}
type ArticleDeleteReq ¶
type ArticleDeleteReq struct {
Id int `json:"id" form:"id"`
}
ArticleDeleteReq 文章删除
type ArticleDeleteRes ¶
type ArticleDeleteRes struct {
Id int `json:"id"`
}
type ArticleListReq ¶
type ArticleListReq struct { Id int `json:"id" form:"id" binding:"min=0"` Title string `json:"title" form:"title" binding:"max=255"` TagId int `json:"tagId" form:"tagId" binding:"min=0"` ArticleStatus int `json:"articleStatus" form:"articleStatus" binding:"min=0"` PageNum int `json:"pageNum" form:"pageNum"` PageSize int `json:"pageSize" form:"pageSize"` }
ArticleListReq 文章列表
type ArticleListRes ¶
type ArticleUpdateReq ¶
type ArticleUpdateReq struct { Id int `json:"id" form:"id"` // 从路由获取注入 Title string `json:"title" form:"title" binding:"required,min=1,max=255"` Sketch string `json:"sketch" form:"sketch" binding:"min=0,max=255"` Content string `json:"content" form:"content" binding:"required,min=1,max=65535"` TagId int `json:"tagId" form:"tagId" binding:"required,min=1"` Weight int `json:"weight" form:"weight" binding:"min=0,max=100"` ArticleStatus int `json:"articleStatus" form:"articleStatus" binding:"required,min=1,max=2"` }
ArticleUpdateReq 编辑
type ArticleUpdateRes ¶
type ArticleUpdateRes struct {
Id int `json:"id"`
}
type CommentCreateReq ¶
type CommentCreateReq struct { UserId int `json:"userId" form:"userId"` // 登陆状态中获取 MentionUserId int `json:"mentionUserId" form:"mentionUserId" binding:"min=0"` ArticleId int `json:"articleId" form:"articleId" binding:"required,min=0"` Content string `json:"content" form:"content" binding:"required,min=1,max=1024"` }
CommentCreateReq 创建
type CommentCreateRes ¶
type CommentCreateRes struct {
Id int `json:"id"`
}
type CommentDeleteReq ¶
type CommentDeleteReq struct {
Id int `json:"id" form:"id"`
}
CommentDeleteReq 删除
type CommentDeleteRes ¶
type CommentDeleteRes struct {
Id int `json:"id"`
}
type CommentListReq ¶
type CommentListReq struct { Id int `json:"id" form:"id" binding:"min=0"` ArticleId int `json:"articleId" form:"articleId" binding:"min=0"` UserId int `json:"userId" form:"userId" binding:"min=0"` CommentStatus int `json:"commentStatus" form:"commentStatus" binding:"min=0"` PageNum int `json:"pageNum" form:"pageNum"` PageSize int `json:"pageSize" form:"pageSize"` }
CommentListReq 列表
type CommentListRes ¶
type CommentUpdateReq ¶
type CommentUpdateReq struct { Id int `json:"id" form:"id"` // 从路由获取注入 ArticleId int `json:"articleId" form:"articleId" binding:"required,min=0"` UserId int `json:"userId" form:"userId" binding:"required,min=0"` MentionUserId int `json:"mentionUserId" form:"mentionUserId" binding:"required,min=0"` Content string `json:"content" form:"title" binding:"required,min=1,max=1024"` CommentStatus int `json:"commentStatus" form:"commentStatus" binding:"required,min=1,max=2"` }
CommentUpdateReq 编辑
type CommentUpdateRes ¶
type CommentUpdateRes struct {
Id int `json:"id"`
}
type TagCreateReq ¶
type TagCreateReq struct { TagName string `json:"tagName" form:"tagName" binding:"required,min=1,max=64"` Weight int `json:"weight" form:"weight" binding:"min=0,max=100"` TagStatus int `json:"tagStatus" form:"tagStatus" binding:"required,min=1,max=2"` }
TagCreateReq 标签创建
type TagCreateRes ¶
type TagCreateRes struct {
Id int `json:"id"`
}
type TagDeleteRes ¶
type TagDeleteRes struct {
Id int `json:"id"`
}
type TagListReq ¶
type TagListReq struct { Id int `json:"id" form:"id" binding:"min=0"` TagName string `json:"tagName" form:"tagName" binding:"max=100"` TagStatus int `json:"tagStatus" form:"tagStatus" binding:"min=0"` PageNum int `json:"pageNum" form:"pageNum"` PageSize int `json:"pageSize" form:"pageSize"` }
TagListReq 标签列表
type TagListRes ¶
type TagUpdateReq ¶
type TagUpdateReq struct { Id int `json:"id" form:"id"` // 从路由获取注入 TagName string `json:"tagName" form:"tagName" binding:"required,min=1,max=64"` Weight int `json:"weight" form:"weight" binding:"min=0,max=100"` TagStatus int `json:"tagStatus" form:"tagStatus" binding:"required,min=1,max=2"` }
TagUpdateReq 标签编辑
type TagUpdateRes ¶
type TagUpdateRes struct {
Id int `json:"id"`
}
type UserChangePwdReq ¶
type UserChangePwdReq struct { Pwd string `json:"pwd" form:"pwd"` // 旧密码 Password string `json:"password" form:"password"` // 新密码 Confirm string `json:"confirm" form:"confirm"` // 新密码确认 }
UserChangePwdReq 删除
type UserChangePwdRes ¶
type UserChangePwdRes struct {
Id int `json:"id"`
}
type UserCreateReq ¶
type UserCreateReq struct { Username string `json:"username" form:"username" binding:"required,min=1,max=64"` Email string `json:"email" form:"email" binding:"required,min=1,max=64"` Pwd string `json:"pwd" form:"pwd" binding:"required,min=1,max=64"` }
UserCreateReq 创建
type UserCreateRes ¶
type UserCreateRes struct {
Id int `json:"id"`
}
type UserDeleteRes ¶
type UserDeleteRes struct {
Id int `json:"id"`
}
type UserListReq ¶
type UserListReq struct { Id int `json:"id" form:"id" binding:"min=0"` Username string `json:"title" form:"title" binding:"max=64"` PageNum int `json:"pageNum" form:"pageNum"` PageSize int `json:"pageSize" form:"pageSize"` }
UserListReq 列表
type UserListRes ¶
type UserUpdateReq ¶
type UserUpdateReq struct { Id int `json:"id" form:"id"` // 从路由获取注入 Username string `json:"username" form:"username" binding:"required,min=1,max=64"` Email string `json:"email" form:"email" binding:"required,min=1,max=64"` Pwd string `json:"pwd" form:"pwd" binding:"required,min=1,max=64"` }
UserUpdateReq 编辑
type UserUpdateRes ¶
type UserUpdateRes struct {
Id int `json:"id"`
}
Click to show internal directories.
Click to hide internal directories.