Update Order
This commit is contained in:
parent
6fef2bbfff
commit
cd630e57d8
@ -136,7 +136,7 @@ func (s *DiscoveryService) GetByID(ctx context.Context, id int64) (*entity.Site,
|
||||
return nil, err
|
||||
}
|
||||
|
||||
if site.Status == "Inactive" {
|
||||
if site.Status != "Active" {
|
||||
return nil, nil
|
||||
}
|
||||
|
||||
|
||||
@ -132,7 +132,7 @@ func (s *OrderService) CreateOrder(ctx mycontext.Context, req *entity.OrderReque
|
||||
return nil, err
|
||||
}
|
||||
|
||||
order, err = s.repo.FindByID(ctx, int64(order.Total))
|
||||
order, err = s.repo.FindByID(ctx, order.ID)
|
||||
if err != nil {
|
||||
logger.ContextLogger(ctx).Error("error when creating order", zap.Error(err))
|
||||
return nil, err
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user