settings

package
v0.0.0-...-00e0705 Latest Latest
Warning

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

Go to latest
Published: Mar 11, 2018 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Model

type Model struct {
	ID        uint
	Key       string
	Value     []byte
	Encode    bool `sql:",notnull"`
	CreatedAt time.Time
	UpdatedAt time.Time
	// contains filtered or unexported fields
}

Model setting database model

type Settings

type Settings struct {
	// contains filtered or unexported fields
}

Settings settings

func New

func New(key []byte) (*Settings, error)

New new settings

func (*Settings) Get

func (p *Settings) Get(db *pg.DB, k string, v interface{}) error

Get get value

func (*Settings) Set

func (p *Settings) Set(db orm.DB, k string, v interface{}, f bool) error

Set set value

Jump to

Keyboard shortcuts

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