Exemple #1
0
        public async Task Handle(OrderCompletedEvent domainEvent)
        {
            var order = await _orderRepository.Get(domainEvent.OrderId);

            await _denormalizer.UpdateOrderStatus(order);

            await _ordersDenormalizer.UpdateOrder(order);
        }
Exemple #2
0
        public async Task Handle(OrderDiscardedEvent domainEvent)
        {
            var order = await _orderRepository.Get(domainEvent.OrderId);

            await _denormalizer.DiscardOrder(order);

            await _ordersDenormalizer.UpdateOrder(order);
        }