Documentation ¶
Index ¶
- type CatalogRepository
- func (r CatalogRepository) AddProduct(ctx context.Context, productID, storeID, name, description, sku string, ...) error
- func (r CatalogRepository) Find(ctx context.Context, productID string) (*domain.CatalogProduct, error)
- func (r CatalogRepository) GetCatalog(ctx context.Context, storeID string) (products []*domain.CatalogProduct, err error)
- func (r CatalogRepository) Rebrand(ctx context.Context, productID, name, description string) error
- func (r CatalogRepository) RemoveProduct(ctx context.Context, productID string) error
- func (r CatalogRepository) UpdatePrice(ctx context.Context, productID string, delta float64) error
- type MallRepository
- func (r MallRepository) AddStore(ctx context.Context, storeID, name, location string) error
- func (r MallRepository) All(ctx context.Context) (stores []*domain.MallStore, err error)
- func (r MallRepository) AllParticipating(ctx context.Context) (stores []*domain.MallStore, err error)
- func (r MallRepository) Find(ctx context.Context, storeID string) (*domain.MallStore, error)
- func (r MallRepository) RenameStore(ctx context.Context, storeID, name string) error
- func (r MallRepository) SetStoreParticipation(ctx context.Context, storeID string, participating bool) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CatalogRepository ¶
type CatalogRepository struct {
// contains filtered or unexported fields
}
func NewCatalogRepository ¶
func NewCatalogRepository(tableName string, db postgres.DB) CatalogRepository
func (CatalogRepository) AddProduct ¶
func (CatalogRepository) Find ¶
func (r CatalogRepository) Find(ctx context.Context, productID string) (*domain.CatalogProduct, error)
func (CatalogRepository) GetCatalog ¶
func (r CatalogRepository) GetCatalog(ctx context.Context, storeID string) (products []*domain.CatalogProduct, err error)
func (CatalogRepository) Rebrand ¶
func (r CatalogRepository) Rebrand(ctx context.Context, productID, name, description string) error
func (CatalogRepository) RemoveProduct ¶
func (r CatalogRepository) RemoveProduct(ctx context.Context, productID string) error
func (CatalogRepository) UpdatePrice ¶
type MallRepository ¶
type MallRepository struct {
// contains filtered or unexported fields
}
func NewMallRepository ¶
func NewMallRepository(tableName string, db postgres.DB) MallRepository
func (MallRepository) AddStore ¶
func (r MallRepository) AddStore(ctx context.Context, storeID, name, location string) error
func (MallRepository) AllParticipating ¶
func (MallRepository) RenameStore ¶
func (r MallRepository) RenameStore(ctx context.Context, storeID, name string) error
func (MallRepository) SetStoreParticipation ¶
Click to show internal directories.
Click to hide internal directories.