controllers

package
v0.0.0-...-594a47b Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2026 License: AGPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

Variables

This section is empty.

Functions

func CreateHTML

func CreateHTML(c *gin.Context)

<=============== GET /create ===============>

func CreatePost

func CreatePost(c *gin.Context)

func Feed

func Feed(c *gin.Context)

func GetPost

func GetPost(c *gin.Context)

<=============== GET /post/:id ===============>

func GetPosts

func GetPosts(c *gin.Context)

<=============== GET /posts ===============>

func Login

func Login(c *gin.Context)

func LoginHTML

func LoginHTML(c *gin.Context)

<=============== GET /login ===============>

func Logout

func Logout(c *gin.Context)

<=============== GET /logout ===============>

func PostComment

func PostComment(c *gin.Context)

<=============== POST /post/id ===============>

func Register

func Register(c *gin.Context)

func RegisterHTML

func RegisterHTML(c *gin.Context)

<=============== GET /register ===============>

func Uploads

func Uploads(c *gin.Context)

<=============== GET /uploads/:filename ===============>

Types

type Channel

type Channel struct {
	XMLName     xml.Name `xml:"channel"`
	Title       string   `xml:"title"`
	Link        string   `xml:"link"`
	Description string   `xml:"description"`
	Items       []Item   `xml:"item"`
}

type Item

type Item struct {
	XMLName     xml.Name `xml:"item"`
	Title       string   `xml:"title"`
	Link        string   `xml:"link"`
	Description string   `xml:"description"`
	Guid        string   `xml:"guid"`
	PubDate     string   `xml:"pubDate"`
}

type LoginUserInput

type LoginUserInput struct {
	UserName string `form:"username" binding:"required"`
	Password string `form:"password" binding:"required"`
}

<=============== POST /login ===============>

type PostInput

type PostInput struct {
	Title     string `form:"title" binding:"required"`
	Content   string `form:"content"`
	VideoLink string `form:"video_link"`
}

<=============== POST /create ===============>

type RSS

type RSS struct {
	XMLName xml.Name `xml:"rss"`
	Version string   `xml:"version,attr"`
	Channel Channel  `xml:"channel"`
}

type RegisterUserInput

type RegisterUserInput struct {
	UserName       string `form:"username" binding:"required"`
	Password       string `form:"password" binding:"required"`
	GlobalPassword string `form:"global_password" binding:"required"`
}

<=============== POST /register ===============>

Jump to

Keyboard shortcuts

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