修复待处理换货资产归属
All checks were successful
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 9m53s
All checks were successful
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 9m53s
This commit is contained in:
@@ -519,7 +519,12 @@ func (s *Service) GetPending(ctx context.Context, identifier string) (*dto.Clien
|
||||
return nil, err
|
||||
}
|
||||
|
||||
if !s.customerOwnsAsset(ctx, asset) {
|
||||
customerID := middleware.GetCustomerIDFromContext(ctx)
|
||||
owned, err := s.customerBinding.OwnsAsset(ctx, customerID, asset.AssetType, asset.AssetID)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if !owned {
|
||||
return nil, errors.New(errors.CodeAssetNotFound)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user