Exemple #1
0
        public IActionResult EditExam([FromBody] ExamViewModel exam)
        {
            var result = _examService.GetExamById(exam.ProfessorId, exam.Id);

            if (result == null)
            {
                return(BadRequest("Invalid exam"));
            }

            _examService.EditExam(exam.GetBlModel(), exam.Classrooms);
            return(NoContent());
        }