repository

package
v0.0.0-...-3ab84a5 Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DB *gorm.DB

Functions

func Init

func Init()

Types

type Product2CRepositoryImpl

type Product2CRepositoryImpl struct{}

func (Product2CRepositoryImpl) MGetProducts2C

func (i Product2CRepositoryImpl) MGetProducts2C(ctx context.Context, productIds []int64) ([]*entity.ProductEntity, error)

func (Product2CRepositoryImpl) SearchProducts

func (i Product2CRepositoryImpl) SearchProducts(ctx context.Context, name, description, spuName *string) ([]*entity.ProductEntity, error)

type ProductRepositoryImpl

type ProductRepositoryImpl struct{}

func (ProductRepositoryImpl) AddProduct

func (i ProductRepositoryImpl) AddProduct(ctx context.Context, product *entity.ProductEntity) error

func (ProductRepositoryImpl) GetProductById

func (i ProductRepositoryImpl) GetProductById(ctx context.Context, productId int64) (*entity.ProductEntity, error)

func (ProductRepositoryImpl) ListProducts

func (i ProductRepositoryImpl) ListProducts(ctx context.Context, filterParam map[string]interface{}) ([]*entity.ProductEntity, error)

func (ProductRepositoryImpl) UpdateProduct

func (i ProductRepositoryImpl) UpdateProduct(ctx context.Context, origin, target *entity.ProductEntity) error

type StockRepositoryImpl

type StockRepositoryImpl struct{}

func (StockRepositoryImpl) DecrStock

func (i StockRepositoryImpl) DecrStock(ctx context.Context, productId, stockNum int64) error

func (StockRepositoryImpl) IncrStock

func (i StockRepositoryImpl) IncrStock(ctx context.Context, productId, stockNum int64) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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