Esempio n. 1
0
 public Task HandleAsync(OrderCreated @event)
 {
     _dbContext.OrderMaterializedView().InsertOne(new OrderMaterializedView()
     {
         OrderNumber = @event.OrderNumber,
         Owner       = @event.Owner,
         CreatedOn   = @event.CreatedOn,
         Id          = @event.AggregateId,
     });
     return(Task.CompletedTask);
 }