Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CategoryService ¶
type CategoryService interface { Create(req domain.Category) (*web.CategoryCreated, error) GetCategoryBySearch(page int, perPage int, search string, buf bytes.Buffer) (map[string]interface{}, error) }
func NewCategoryService ¶
func NewCategoryService(repo repository.CategoryRepository, validate middleware.ValidationInterface, es *elasticsearch.Client, trace trace.Tracer, meter metric.MeterProvider) CategoryService
type OrderService ¶
type OrderService interface { AddToCart(req domain.Cart) (*web.Cart, error) FindID(uuid string) (*web.OrderResponse, error) History(userID uint, page int, perPage int) (*web.Pagination, error) Buy(req domain.Order) (*web.BuyResponse, error) Pay(uuid string, userID uint) (*web.PaymentResponse, error) Checkout(id uint) (*web.BuyResponse, error) Cart(userID uint, page int, perPage int) (*web.Pagination, error) }
func NewOrderService ¶
func NewOrderService(repo repository.OrderRepository, validate middleware.ValidationInterface, conf config.App, trace trace.Tracer, meter metric.MeterProvider) OrderService
type ProductService ¶
type ProductService interface { Create(req domain.ProductRequest) (*web.ProductResponse, error) FindID(id uint) (*web.ProductResponse, error) FindAll(page int, perPage int) (*web.Pagination, error) FindAllByCategoryID(categoryID uint, page int, perPage int) (*web.Pagination, error) GetProductBySearch(page int, perPage int, search string, buf bytes.Buffer) (map[string]interface{}, error) }
func NewProductService ¶
func NewProductService(repo repository.ProductRepository, validation middleware.ValidationInterface, es *elasticsearch.Client, trace trace.Tracer, meter metric.MeterProvider) ProductService
type UserService ¶
type UserService interface { Register(req domain.UserRequest) (*web.UserRegister, error) Login(req domain.UserLogin) (*web.UserLogin, error) }
func NewUserService ¶
func NewUserService(repo repository.UserRepository, validate middleware.ValidationInterface, trace trace.Tracer, meter metric.MeterProvider) UserService
Click to show internal directories.
Click to hide internal directories.