public IQueryable<ReadonlyAnswer> LoadReadOnlyAnswers(int responseHeaderId, int questionId)
{
return (from response in this.Context.Responses
where response.ResponseHeaderId == responseHeaderId && response.QuestionId == questionId
select new ReadonlyAnswer
{
AnswerId = response.AnswerId ?? 0,
Text = response.AnswerText,
RelativeOrder = response.AnswerRelativeOrder ?? 0,
IsCorrect = response.AnswerIsCorrect ?? false,
SectionId = response.SectionId,
QuestionId = response.QuestionId,
ResponseHeaderId = response.ResponseHeaderId,
AnswerValue = response.UserResponse
})
.Distinct()
.OrderBy(response => response.RelativeOrder);
}