Beispiel #1
0
        public IList <Question> GetRelatedQuestions(Guid questionOptionGuid)
        {
            var list = Enumerable.Empty <Question>().ToList();

            using (var examRepo = new ExamRepository())
            {
                var questions = examRepo.GetSubQuestions(questionOptionGuid, true);
                list = Mapper.Map <List <Question> >(questions);
            }

            return(list);
        }
Beispiel #2
0
        public List <Question> GetSubQuestions(Guid questionOptionId)
        {
            using (var examRepo = new ExamRepository())
            {
                var questions = examRepo.GetSubQuestions(questionOptionId, true);

                var quesiontList = Mapper.Map <List <Question> >(questions);

                quesiontList.ForEach(x => x.IsChildQuestion = true);

                return(quesiontList);
            }
        }