Пример #1
0
        public CategoriesAction()
        {
            EAD.ExamAssessmentEntities db           = new EAD.ExamAssessmentEntities();
            List <EAD.Categories>      dbCategories = db.Categories.ToList();

            SubTopicAction = new SubTopicAction();
        }
Пример #2
0
        /// <summary>
        /// Given an id of an exam template it returns
        /// an exam template EAD variable.
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        public ExamTemplate getExam(string id)
        {
            db = new EAD.ExamAssessmentEntities();
            List <EAD.ExamTemplate> ExamTemplate = db.ExamTemplate.Where(s => s.ExamTemplateID == id).ToList();
            ExamTemplate            exam         = new ExamTemplate();

            exam.PKID                  = ExamTemplate.First().PKID;
            exam.CreatedDate           = ExamTemplate.First().CreatedDate;
            exam.ExamTemplateName      = ExamTemplate.First().ExamTemplateName;
            exam.ExamTemplateID        = ExamTemplate.FirstOrDefault().ExamTemplateID;
            exam.ExamType.PKID         = ExamTemplate.FirstOrDefault().ExamType.PKID;
            exam.ExamType.ExamTypeName = ExamTemplate.FirstOrDefault().ExamType.ExamTypeName;
            return(exam);
        }
Пример #3
0
 public SubTopicAction()
 {
     EAD.ExamAssessmentEntities db          = new EAD.ExamAssessmentEntities();
     List <EAD.Subtopic>        dbSubtopics = db.Subtopic.ToList();
 }
Пример #4
0
 public QuestionAction()
 {
     db         = new EAD.ExamAssessmentEntities();
     dbquestion = db.Question.ToList();
 }
Пример #5
0
 public ExamAction()
 {
     EAD.ExamAssessmentEntities db = new EAD.ExamAssessmentEntities();
 }
Пример #6
0
 public AnswerAction()
 {
     EAD.ExamAssessmentEntities       db       = new EAD.ExamAssessmentEntities();
     List <ExamAssessmentDaal.Answer> dbanswer = db.Answer.ToList();
 }