repo

package
v0.0.0-...-1551971 Latest Latest
Warning

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

Go to latest
Published: Dec 27, 2021 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ProductsRepo

type ProductsRepo interface {
	CreateProduct(product model.Product) (productID int64, err error)
	UpdateProduct(product model.Product) error
	GetProducts() (products []model.Product, err error)
	GetProductByID(prodId int64) (product model.Product, err error)
	DeleteProductByID(prodId int64) (err error)
}

func NewProductsRepo

func NewProductsRepo(db *sql.DB) ProductsRepo

type StripeRepo

type StripeRepo interface {
	CreateCustomer(customer model.StripeCustomer) error
	IsCustomer(userID int64) (string, bool, error)
	UpdateCustomer(customer model.StripeCustomer) error
}

func NewStripeRepo

func NewStripeRepo(db *sql.DB) StripeRepo

type UserAccountRepo

type UserAccountRepo interface {
	GetUserByEmail(email string) (*model.UserAccount, error)
	GetUserByID(id int64) (*model.UserAccount, error)
	CreateUser(user *model.UserAccount) (userId int64, err error)
}

func NewUserAccountRepo

func NewUserAccountRepo(db *sql.DB) UserAccountRepo

Jump to

Keyboard shortcuts

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