public void Apply(CreatedProductEvent e) { Id = e.AggregateId; Price = e.Price; Color = e.Color; Brand = e.Brand; ProductType = e.ProductType; Weight = e.Weight; Name = e.Name; Description = e.Description; Gender = e.Gender; ForBaby = e.ForBaby; Size = e.Size; Discount = e.Discount; CreateTime = e.CreateTime; Expiration = e.Expiration; Images = e.Images; }
public void BuildEvent(CreatedProductEvent @event) { Id = @event.AggregateId; Name = @event.Name; Price = @event.Price; }