public async Task <ApiResponse> checkSubjectiveAnswers([FromBody] IEnumerable <Result> model) { try { Console.WriteLine("api called to mark subjective answer"); Console.WriteLine(model.FirstOrDefault().ExaminerId); await _answerService.CheckAnswer(model); return(HttpResponse(200, "")); } catch (Exception e) { _logger.Log(LogType.Error, () => e.Message, e); return(HttpResponse(500, e.Message)); } }
public bool CheckAnswer(int taskId , string answer) { return answerService.CheckAnswer(taskId, answer, userService.GetUserId(User.Identity.Name)); }
public async Task <bool> CheckSingleAnswer(Guid questionId, Guid answerId) { return(await _answerService.CheckAnswer(answerId)); }