コード例 #1
0
        public void BookingMade(BookingMadeEvent @event)
        {
            _bookingRepository.Save(@event.Source);

            var bookingMade = new BookingMade
            {
                Id            = @event.Source.Id.Value,
                EmployeeId    = @event.Source.EmployeeId,
                Start         = @event.Source.Start,
                End           = @event.Source.End,
                BookingTypeId = @event.Source.BookingType.Id.Value
            };

            _bus.Publish(bookingMade);
        }
コード例 #2
0
 public void Apply(BookingMade e)
 {
     bookingsMade.Add(e);
 }