Add Print Detail
This commit is contained in:
@@ -540,3 +540,13 @@ func (s *OrderService) GetByID(ctx mycontext.Context, id int64, referenceID stri
|
||||
|
||||
return order, nil
|
||||
}
|
||||
|
||||
func (s *OrderService) GetPrintDetail(ctx mycontext.Context, id int64) (*entity.OrderPrintDetail, error) {
|
||||
order, err := s.repo.FindPrintDetailByID(ctx, id)
|
||||
if err != nil {
|
||||
logger.ContextLogger(ctx).Error("error when getting products by IDs", zap.Error(err))
|
||||
return nil, err
|
||||
}
|
||||
|
||||
return order, nil
|
||||
}
|
||||
|
||||
@@ -124,6 +124,7 @@ type Order interface {
|
||||
GetDailySales(ctx mycontext.Context, req entity.OrderSearch) ([]entity.ProductDailySales, error)
|
||||
GetPaymentDistribution(ctx mycontext.Context, req entity.OrderSearch) ([]entity.PaymentTypeDistribution, error)
|
||||
GetByID(ctx mycontext.Context, id int64, referenceID string) (*entity.Order, error)
|
||||
GetPrintDetail(ctx mycontext.Context, id int64) (*entity.OrderPrintDetail, error)
|
||||
}
|
||||
|
||||
type OSSService interface {
|
||||
|
||||
Reference in New Issue
Block a user