pgsql

package
v0.0.0-...-faa3d42 Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2020 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type User

type User struct{}

User represents the client for user table

func NewUser

func NewUser() *User

NewUser returns a new User instance

func (*User) Create

func (s *User) Create(cl orm.DB, req easypay.User) (*easypay.User, error)

Create creates new user

func (*User) Delete

func (s *User) Delete(cl orm.DB, user *easypay.User) error

Delete delets a user by ID

func (*User) List

func (s *User) List(cl orm.DB, query string, limit, offset int) ([]easypay.User, error)

List returns list of all users retreivable for the current user, depending on role

func (*User) Update

func (s *User) Update(cl orm.DB, user *easypay.User) (*easypay.User, error)

Update updates a single user

func (*User) View

func (s *User) View(cl orm.DB, id int64) (*easypay.User, error)

View returns single user by ID/PrimaryKey

Jump to

Keyboard shortcuts

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