Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Configuration ¶
type Configuration struct {
Port int
DBStringLocation string `json:"DBStringLocation"`
Path string
Production bool `json:"Production"`
CSRFString string
}
Configuration contains all the configurable variables for this app
type Crypto ¶
type Crypto struct {
gorm.Model
PostID int
Hash string `json:"Password" gorm:"Column:hash"`
Salt string `json:"Salt" gorm:"Column:salt"`
AuthHash string `json:"authHash" gorm:"-"`
Key string `json:"Key" gorm:"Column:key"`
}
Crypto contains the cryptographic aspect of the post
type Data ¶
type Data struct {
gorm.Model
PostID int
Title string `json:"Title" gorm:"Column:title"`
PostPerms int `json:"PostPerms,string" gorm:"Column:postperms"`
Content string `json:"Content" gorm:"Column:text"`
}
Data contains all the info related to the posts
type Edit ¶
type Edit struct {
EditID int `json:"EditID" gorm:"Column:editid"`
}
Edit is used for editing a post
type Markdown ¶
type Markdown struct {
MD template.HTML `json:"" gorm:"-"`
TitleMD template.HTML `json:"" gorm:"-"`
IMG template.HTML `json:"" gorm:"-"`
}
Markdown Contains the data used for rendering the post on the HTML frontend
type Post ¶
type Post struct {
ID int `json:"ID" gorm:"primary_key"`
Data Data
Meta Meta
Edit Edit `json:"-"`
Crypto Crypto `json:"-"`
Markdown Markdown `json:"-"`
}
Post is the "master" struct
type PostCounter ¶
PostCounter is used on index to provide some metadata about current posts
Click to show internal directories.
Click to hide internal directories.