// GET api/values/5 public CoachingCourseDTO Get(Guid id) { var coachingCourseRepository = new CoachingCourseRepositoryDocumentDB(); return(CoachingCourseDTOConverter.ConvertToDTO( coachingCourseRepository.GetItems(i => i.Id == id).SingleOrDefault())); }
// GET api/values public IEnumerable <CoachingCourseDTO> Get() { //TODO: Find user var coachingCourseRepository = new CoachingCourseRepositoryDocumentDB(); return(coachingCourseRepository.GetAllItems().Select(c => CoachingCourseDTOConverter.ConvertToDTO(c))); }