protected void SaveEventAttribute(EventScheduleCommand command,
                                          EventDetail eventDetail)
        {
            EventAttribute eventAttribute       = new EventAttribute();
            var            eventTicketAttribute = _eventAttributeRepository.GetByEventDetailId(eventDetail.Id);

            if (eventTicketAttribute != null)
            {
                _eventAttributeRepository.Delete(eventTicketAttribute);
            }
            var eventAttributes = new EventAttribute
            {
                TimeZoneAbbreviation = command.EventScheduleModel.TimeZoneAbbrivation,
                EventDetailId        = eventDetail.Id,
                CreatedBy            = command.ModifiedBy,
                CreatedUtc           = DateTime.UtcNow,
                IsEnabled            = true,
                TimeZone             = command.EventScheduleModel.TimeZoneOffset,
                ModifiedBy           = command.ModifiedBy,
                UpdatedBy            = command.ModifiedBy,
                UpdatedUtc           = DateTime.UtcNow
            };

            _eventAttributeRepository.Save(eventAttributes);
        }
        protected void UpdateEventAttribute(FIL.Contracts.Commands.CreateEventV1.EventRecurranceCommand eventRecurranceCommand)
        {
            EventAttribute eventAttribute       = new EventAttribute();
            var            eventDetail          = _eventDetailRepository.GetByEventId(eventRecurranceCommand.EventId);
            var            eventTicketAttribute = _eventAttributeRepository.GetByEventDetailId(eventDetail.Id);

            if (eventTicketAttribute != null)
            {
                _eventAttributeRepository.Delete(eventTicketAttribute);
            }
            var eventAttributes = new EventAttribute
            {
                TimeZoneAbbreviation = eventRecurranceCommand.TimeZoneAbbrivation,
                EventDetailId        = eventDetail.Id,
                CreatedBy            = eventRecurranceCommand.ModifiedBy,
                CreatedUtc           = DateTime.UtcNow,
                IsEnabled            = true,
                TimeZone             = eventRecurranceCommand.TimeZoneOffSet,
                ModifiedBy           = eventRecurranceCommand.ModifiedBy,
                UpdatedBy            = eventRecurranceCommand.ModifiedBy,
                UpdatedUtc           = DateTime.UtcNow
            };

            _eventAttributeRepository.Save(eventAttributes);
        }