mock

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Mar 17, 2021 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type OrganizationModel

type OrganizationModel struct{}

func (*OrganizationModel) Get

func (*OrganizationModel) Insert

func (m *OrganizationModel) Insert(identifier, name string) error

type ServiceModel

type ServiceModel struct{}

func (*ServiceModel) Get

func (m *ServiceModel) Get(org *models.Organization, id int) (*models.Service, error)

func (*ServiceModel) Insert

func (m *ServiceModel) Insert(org *models.Organization, identifier, title, description string, attributes []*models.ServiceAttribute, status int, owner string) (int, error)

func (*ServiceModel) Latest

func (m *ServiceModel) Latest(org *models.Organization, start, limit int) ([]*models.Service, error)

func (*ServiceModel) Update

func (m *ServiceModel) Update(service *models.Service) (int, error)

type UserModel

type UserModel struct{}

func (*UserModel) Authenticate

func (m *UserModel) Authenticate(email, password string) (int, error)

func (*UserModel) ChangePassword

func (m *UserModel) ChangePassword(id int, currentPassword, newPassword string) error

func (*UserModel) Get

func (m *UserModel) Get(id int) (*models.User, error)

func (*UserModel) Insert

func (m *UserModel) Insert(name, email, password string) error

func (*UserModel) Organizations

func (m *UserModel) Organizations(user *models.User) (orgs []*models.Organization, err error)

Jump to

Keyboard shortcuts

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