public async Task Handle(Events.BasketClaimed e, IMessageHandlerContext ctx) { var user = await ctx.UoW().Get <Identity.User.Models.User>(e.UserName) .ConfigureAwait(false); var basket = await ctx.UoW().Get <Models.BasketIndex>(e.BasketId) .ConfigureAwait(false); basket.Customer = user.GivenName; basket.CustomerId = user.Id; basket.Updated = e.Stamp; await ctx.UoW().Update(e.BasketId, basket).ConfigureAwait(false); }
private void Handle(Events.BasketClaimed e) { this.UserName = e.UserName; }