models

package
v0.0.0-...-722e3b2 Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2018 License: MIT Imports: 9 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

DB is a connection to your database to be used throughout your application.

Functions

This section is empty.

Types

type Droplet

type Droplet struct {
	ID        uuid.UUID     `json:"id" db:"id"`
	CreatedAt time.Time     `json:"created_at" db:"created_at"`
	UpdatedAt time.Time     `json:"updated_at" db:"updated_at"`
	Droplet   string        `json:"droplet" db:"droplet"`
	Droplets  slices.String `json:"droplets" db:"droplets"`
	DoToken   string        `json:"doToken" db:"doToken"`
}

func (Droplet) String

func (d Droplet) String() string

String is not required by pop and may be deleted

func (*Droplet) Validate

func (d *Droplet) Validate(tx *pop.Connection) (*validate.Errors, error)

Validate gets run every time you call a "pop.Validate*" (pop.ValidateAndSave, pop.ValidateAndCreate, pop.ValidateAndUpdate) method. This method is not required and may be deleted.

func (*Droplet) ValidateCreate

func (d *Droplet) ValidateCreate(tx *pop.Connection) (*validate.Errors, error)

ValidateCreate gets run every time you call "pop.ValidateAndCreate" method. This method is not required and may be deleted.

func (*Droplet) ValidateUpdate

func (d *Droplet) ValidateUpdate(tx *pop.Connection) (*validate.Errors, error)

ValidateUpdate gets run every time you call "pop.ValidateAndUpdate" method. This method is not required and may be deleted.

type Droplets

type Droplets []Droplet

Droplets is not required by pop and may be deleted

func (Droplets) String

func (d Droplets) String() string

String is not required by pop and may be deleted

type Link struct {
	ID        uuid.UUID `json:"id" db:"id"`
	CreatedAt time.Time `json:"created_at" db:"created_at"`
	UpdatedAt time.Time `json:"updated_at" db:"updated_at"`
	Link      string    `json:"link" db:"link"`
}

func (Link) String

func (l Link) String() string

String is not required by pop and may be deleted

func (*Link) Validate

func (l *Link) Validate(tx *pop.Connection) (*validate.Errors, error)

Validate gets run every time you call a "pop.Validate*" (pop.ValidateAndSave, pop.ValidateAndCreate, pop.ValidateAndUpdate) method. This method is not required and may be deleted.

func (*Link) ValidateCreate

func (l *Link) ValidateCreate(tx *pop.Connection) (*validate.Errors, error)

ValidateCreate gets run every time you call "pop.ValidateAndCreate" method. This method is not required and may be deleted.

func (*Link) ValidateUpdate

func (l *Link) ValidateUpdate(tx *pop.Connection) (*validate.Errors, error)

ValidateUpdate gets run every time you call "pop.ValidateAndUpdate" method. This method is not required and may be deleted.

type Links []Link

Links is not required by pop and may be deleted

func (Links) String

func (l Links) String() string

String is not required by pop and may be deleted

type Quote

type Quote struct {
	ID        uuid.UUID     `json:"id" db:"id"`
	CreatedAt time.Time     `json:"created_at" db:"created_at"`
	UpdatedAt time.Time     `json:"updated_at" db:"updated_at"`
	Name      string        `json:"name" db:"name"`
	Quote     string        `json:"quote" db:"quote"`
	Quotes    slices.String `json:"quotes" db:"quotes"`
}

func (Quote) String

func (q Quote) String() string

String is not required by pop and may be deleted

func (*Quote) Validate

func (q *Quote) Validate(tx *pop.Connection) (*validate.Errors, error)

Validate gets run every time you call a "pop.Validate*" (pop.ValidateAndSave, pop.ValidateAndCreate, pop.ValidateAndUpdate) method. This method is not required and may be deleted.

func (*Quote) ValidateCreate

func (q *Quote) ValidateCreate(tx *pop.Connection) (*validate.Errors, error)

ValidateCreate gets run every time you call "pop.ValidateAndCreate" method. This method is not required and may be deleted.

func (*Quote) ValidateUpdate

func (q *Quote) ValidateUpdate(tx *pop.Connection) (*validate.Errors, error)

ValidateUpdate gets run every time you call "pop.ValidateAndUpdate" method. This method is not required and may be deleted.

type Quotes

type Quotes []Quote

Quotes is not required by pop and may be deleted

func (Quotes) String

func (q Quotes) String() string

String is not required by pop and may be deleted

type Show

type Show struct {
	ID         uuid.UUID `json:"id" db:"id"`
	CreatedAt  time.Time `json:"created_at" db:"created_at"`
	UpdatedAt  time.Time `json:"updated_at" db:"updated_at"`
	Name       string    `json:"name" db:"name"`
	Nick       string    `json:"nick" db:"nick"`
	Suggestion string    `json:"suggestion" db:"suggestion"`
}

func (Show) String

func (s Show) String() string

String is not required by pop and may be deleted

func (*Show) Validate

func (s *Show) Validate(tx *pop.Connection) (*validate.Errors, error)

Validate gets run every time you call a "pop.Validate*" (pop.ValidateAndSave, pop.ValidateAndCreate, pop.ValidateAndUpdate) method. This method is not required and may be deleted.

func (*Show) ValidateCreate

func (s *Show) ValidateCreate(tx *pop.Connection) (*validate.Errors, error)

ValidateCreate gets run every time you call "pop.ValidateAndCreate" method. This method is not required and may be deleted.

func (*Show) ValidateUpdate

func (s *Show) ValidateUpdate(tx *pop.Connection) (*validate.Errors, error)

ValidateUpdate gets run every time you call "pop.ValidateAndUpdate" method. This method is not required and may be deleted.

type Shows

type Shows []Show

Shows is not required by pop and may be deleted

func (Shows) String

func (s Shows) String() string

String is not required by pop and may be deleted

Jump to

Keyboard shortcuts

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