mongo

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2024 License: MIT Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Repository

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

func New

func New(ctx context.Context, uri, dbName string) (*Repository, error)

func (*Repository) ListCustomers

func (*Repository) LockCustomer

func (r *Repository) LockCustomer(ctx context.Context, id string) (func(), error)

func (*Repository) LookupCustomerById

func (r *Repository) LookupCustomerById(ctx context.Context, id string) (*customerv1.Customer, []*customerv1.ImportState, error)

func (*Repository) LookupCustomerByMail

func (r *Repository) LookupCustomerByMail(ctx context.Context, mail string, p *commonv1.Pagination) ([]*customerv1.CustomerResponse, int, error)

func (*Repository) LookupCustomerByName

func (r *Repository) LookupCustomerByName(ctx context.Context, name string, p *commonv1.Pagination) ([]*customerv1.CustomerResponse, int, error)

func (*Repository) LookupCustomerByPhone

func (r *Repository) LookupCustomerByPhone(ctx context.Context, phone string, p *commonv1.Pagination) ([]*customerv1.CustomerResponse, int, error)

func (*Repository) LookupCustomerByRef

func (r *Repository) LookupCustomerByRef(ctx context.Context, importer, ref string) (*customerv1.Customer, []*customerv1.ImportState, error)

func (*Repository) SearchQueries

func (*Repository) StoreCustomer

func (r *Repository) StoreCustomer(ctx context.Context, customer *customerv1.Customer, states []*customerv1.ImportState) error

Jump to

Keyboard shortcuts

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