public void Handle(CustomAttributeValueAddedEvent @event)
 {
     try
     {
         EventStore.Save(@event);
     }
     catch
     {
         throw;
     }
 }
Ejemplo n.º 2
0
        public async Task AddValueForAttribute(Guid attributeId, object value)
        {
            try
            {
                var attribute = await Repository.GetByKeyAsync <CustomAttribute>(attributeId);

                attribute.AddValue(value);

                await Repository.SaveChangesAsync();

                var @event = new CustomAttributeValueAddedEvent(attributeId, value);
                EventBus.RaiseEvent(@event);
            }
            catch
            {
                throw;
            }
        }