public void Create(User organizer, Institution institution, string name, DateTime beginDate, DateTime endDate, DateTime registrationAvaliable, string mainPlaceName, Coordinates coordinates, string placeDescription = null) { var newEvent = new Event(name, beginDate, endDate, registrationAvaliable, mainPlaceName, coordinates, placeDescription, dateTimeProvider); var organizeruser = newEvent.RegisterOrganizer(organizer, institution); eventRepository.Create(newEvent); assistantRepository.Register(organizeruser); }
public void RegisterAssistant(Event myEvent, User user) { var partaker = myEvent.RegisterAssistant(user); assistantRepository.Register(partaker); }