models

package
v0.0.0-...-bf23469 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2022 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNoRecord           = errors.New("error: no record found")
	ErrInvalidCredentials = errors.New("models : invalid credentials")
	ErrDuplicateEmail     = errors.New("models: duplicate email")
)

Functions

This section is empty.

Types

type Snippet

type Snippet struct {
	ID      int       `json:"id" gorm:"Column:id"`
	Title   string    `json:"title" gorm:"Column:title"`
	Content string    `json:"content" gorm:"Column:content"`
	Created time.Time `json:"created_at" gorm:"Column:created"`
	Expires time.Time `json:"expires_at" gorm:"Column:expires"`
}

type User

type User struct {
	ID             int    `json:"id" gorm:"Column:id"`
	Name           string `json:"name" gorm:"Column:name"`
	Email          string `json:"email" gorm:"Column:email"`
	HashedPassword []byte `gorm:"Column:hashed_password"`
	Created        time.Time
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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