Documentation ¶
Index ¶
- Variables
- func AppController(c echo.Context) error
- func AssignUser(c echo.Context) error
- func AuthUser(c echo.Context) error
- func CreateArticle(c echo.Context) error
- func CreateFlicker(c echo.Context) error
- func CreateGallery(c echo.Context) error
- func CreateReaction(c echo.Context) error
- func DeletePost(c echo.Context) error
- func DeleteReaction(c echo.Context) error
- func DeleteUser(c echo.Context) error
- func GetArticleByID(c echo.Context) error
- func GetArticles(c echo.Context) error
- func GetFlickerByID(c echo.Context) error
- func GetFlickers(c echo.Context) error
- func GetGalleries(c echo.Context) error
- func GetGalleryByID(c echo.Context) error
- func GetPostReactionByID(c echo.Context) error
- func GetPostReactions(c echo.Context) error
- func GetPublicArticleByID(c echo.Context) error
- func GetPublicArticles(c echo.Context) error
- func GetPublicFlickerByID(c echo.Context) error
- func GetPublicFlickers(c echo.Context) error
- func GetPublicGalleries(c echo.Context) error
- func GetPublicGalleryByID(c echo.Context) error
- func GetUserByID(c echo.Context) error
- func GetUserPublicArticles(c echo.Context) error
- func GetUserPublicFlickers(c echo.Context) error
- func GetUserPublicGalleries(c echo.Context) error
- func GetUserReactions(c echo.Context) error
- func GetUsers(c echo.Context) error
- func InitRBAC() error
- func JoinUser(c echo.Context) error
- func PublishPost(c echo.Context) error
- func RetractPost(c echo.Context) error
- func TransferArticle(c echo.Context) error
- func TransferFlicker(c echo.Context) error
- func TransferGallery(c echo.Context) error
- func UpdateArticle(c echo.Context) error
- func UpdateFlicker(c echo.Context) error
- func UpdateGallery(c echo.Context) error
- func UpdatePass(c echo.Context) error
- func UpdateReaction(c echo.Context) error
- func UpdateUser(c echo.Context) error
- type ArticlesResponse
- type FlickersResponse
- type GalleriesResponse
- type JwtCustomClaims
- type PostResponse
- type ReactionResponse
- type ReactionsResponse
- type Response
- type UserResponse
- type UsersResponse
Constants ¶
This section is empty.
Variables ¶
var (
RBAC *gorbac.RBAC
)
RBAC is an instance of the Role-Based Access Control
Functions ¶
func AssignUser ¶
func AssignUser(c echo.Context) error
AssignUser handles the "/users/:id/assign" route.
func CreateArticle ¶
func CreateArticle(c echo.Context) error
CreateArticle handles the "/posts/articles/create" route.
func CreateFlicker ¶
func CreateFlicker(c echo.Context) error
CreateFlicker handles the "/posts/flickers/create" route.
func CreateGallery ¶
func CreateGallery(c echo.Context) error
CreateGallery handles the "/posts/galleries/create" route.
func CreateReaction ¶
func CreateReaction(c echo.Context) error
CreateReaction handles the "/reactions/create" route.
func DeletePost ¶
func DeletePost(c echo.Context) error
DeletePost handles the "/posts/:id/delete" route.
func DeleteReaction ¶
func DeleteReaction(c echo.Context) error
DeleteReaction handles the "/reactions/:id/delete" route.
func DeleteUser ¶
func DeleteUser(c echo.Context) error
DeleteUser handles the "/users/:id/delete" route.
func GetArticleByID ¶
func GetArticleByID(c echo.Context) error
GetArticleByID handles the "/posts/articles/:id" route.
func GetArticles ¶
func GetArticles(c echo.Context) error
GetArticles handles the "/posts/articles" route.
func GetFlickerByID ¶
func GetFlickerByID(c echo.Context) error
GetFlickerByID handles the "/posts/flickers/:id" route.
func GetFlickers ¶
func GetFlickers(c echo.Context) error
GetFlickers handles the "/posts/flickers" route.
func GetGalleries ¶
func GetGalleries(c echo.Context) error
GetGalleries handles the "/posts/galleries" route.
func GetGalleryByID ¶
func GetGalleryByID(c echo.Context) error
GetGalleryByID handles the "/posts/galleries/:id" route.
func GetPostReactionByID ¶
func GetPostReactionByID(c echo.Context) error
GetPostReactionByID handles the "/reactions/:id" route.
func GetPostReactions ¶
func GetPostReactions(c echo.Context) error
GetPostReactions handles the "/posts/:id/reactions" route.
func GetPublicArticleByID ¶
func GetPublicArticleByID(c echo.Context) error
GetPublicArticleByID handles the "/posts/articles/public/:id" route.
func GetPublicArticles ¶
func GetPublicArticles(c echo.Context) error
GetPublicArticles handles the "/posts/articles/public" route.
func GetPublicFlickerByID ¶
func GetPublicFlickerByID(c echo.Context) error
GetPublicFlickerByID handles the "/posts/flickers/public/:id" route.
func GetPublicFlickers ¶
func GetPublicFlickers(c echo.Context) error
GetPublicFlickers handles the "/posts/flickers/public" route.
func GetPublicGalleries ¶
func GetPublicGalleries(c echo.Context) error
GetPublicGalleries handles the "/posts/galleries/public" route.
func GetPublicGalleryByID ¶
func GetPublicGalleryByID(c echo.Context) error
GetPublicGalleryByID handles the "/posts/galleries/public/:id" route.
func GetUserByID ¶
func GetUserByID(c echo.Context) error
GetUserByID handles the "/users/:id" route.
func GetUserPublicArticles ¶
func GetUserPublicArticles(c echo.Context) error
GetUserPublicArticles handles the "/users/:id/posts/articles" route.
func GetUserPublicFlickers ¶
func GetUserPublicFlickers(c echo.Context) error
GetUserPublicFlickers handles the "/users/:id/posts/flickers" route.
func GetUserPublicGalleries ¶
func GetUserPublicGalleries(c echo.Context) error
GetUserPublicGalleries handles the "/users/:id/posts/galleries" route.
func GetUserReactions ¶
func GetUserReactions(c echo.Context) error
GetUserReactions handles the "/users/:id/reactions" route.
func InitRBAC ¶
func InitRBAC() error
InitRBAC initializes the Role-Based Access Control HACK Ignored error handling
func PublishPost ¶
func PublishPost(c echo.Context) error
PublishPost handles the "/posts/:id/publish" route.
func RetractPost ¶
func RetractPost(c echo.Context) error
RetractPost handles the "/posts/:id/retract" route.
func TransferArticle ¶
func TransferArticle(c echo.Context) error
TransferArticle handles the "/posts/articles/:id/transfer" route.
func TransferFlicker ¶
func TransferFlicker(c echo.Context) error
TransferFlicker handles the "/posts/flickers/:id/transfer" route.
func TransferGallery ¶
func TransferGallery(c echo.Context) error
TransferGallery handles the "/posts/galleries/:id/transfer" route.
func UpdateArticle ¶
func UpdateArticle(c echo.Context) error
UpdateArticle handles the "/posts/articles/:id/update" route.
func UpdateFlicker ¶
func UpdateFlicker(c echo.Context) error
UpdateFlicker handles the "/posts/flickers/:id/update" route.
func UpdateGallery ¶
func UpdateGallery(c echo.Context) error
UpdateGallery handles the "/posts/galleries/:id/update" route.
func UpdatePass ¶
func UpdatePass(c echo.Context) error
UpdatePass handles the "/users/me/change" route.
func UpdateReaction ¶
func UpdateReaction(c echo.Context) error
UpdateReaction handles the "/reactions/:id/update" route.
func UpdateUser ¶
func UpdateUser(c echo.Context) error
UpdateUser handles the "/users/me/update" route.
Types ¶
type ArticlesResponse ¶
ArticlesResponse is a response containing a slice of Articles
type FlickersResponse ¶
FlickersResponse is a response containing a slice of Flickers
type GalleriesResponse ¶
GalleriesResponse is a response containing a slice of Galleries
type JwtCustomClaims ¶
type JwtCustomClaims struct { User uuid.UUID `json:"user"` Role model.UserRole `json:"role"` jwt.StandardClaims }
JwtCustomClaims are custom claims extending default ones.
type PostResponse ¶
PostResponse is a response containing one Post
type ReactionResponse ¶
ReactionResponse is a response containing one Reaction
type ReactionsResponse ¶
ReactionsResponse is a response containing a slice of Reactions
type UserResponse ¶
UserResponse is a response containing one User
type UsersResponse ¶
UsersResponse is a response containing a slice of Users