Ejemplo n.º 1
0
        public IHttpActionResult GetClassByTeacherId(int id)
        {
            var classes = classRepo.GetClassesByTeacherId(id);

            if (!classes.Any())
            {
                return(Content(HttpStatusCode.NotFound, "List is empty"));
            }

            return(Ok(classes));
        }