public async Task <int> AddAsync(RegistrationDTO entity) { if (entity.Status) { var seminar = await seminarRepository.GetAsync(entity.SeminarId); seminar.ParticipantsCount++; await seminarRepository.UpdateAsync(seminar); } return(await registrationRepository.AddAsync(entity)); }
public async Task <SeminarDTO> GetAsync(Guid id) { return(await seminarRepository.GetAsync(id)); }