Beispiel #1
0
        public void signUpUserToMeeting(string login, string name)
        {
            var meeting = this.getMeetingsByName(name);

            if (meeting == null || meeting.NumberOfFreePlaces == 0)
            {
                return;
            }

            var user = this.getUserByLogin(login);

            if (user == null)
            {
                return;
            }

            var participation = participationFactory.create(login, name);

            participationRepository.addParticipations(participation);
            meetingsRepository.decreaseNumberOfFreePlaces(meeting);
        }