Example #1
0
        public void Consume(BonusCreated message)
        {
            _repository.Bonuses.Add(new Interface.Data.Bonus
            {
                Id        = message.AggregateId,
                Name      = message.Name,
                Code      = message.Code,
                IsActive  = message.IsActive,
                BonusType = (BonusType)message.BonusType,
                BrandId   = message.BrandId
            });

            _repository.SaveChanges();
        }
 public void Consume(BonusCreated message)
 {
     _eventHandlers.Handle(message);
 }
Example #3
0
 public void Handle(BonusCreated @event)
 {
     AddActivityLog(AdminActivityLogCategory.Bonus, @event);
 }