Ejemplo n.º 1
0
 public QuestionBankManagerViewModel(IWindowManager windowManager)
 {
     _windowManager = windowManager;
     SubjectItems.AddRange(_quetionBankBusiness.GetAllSubject().Select((subject) => new PUComboBoxItemModel {
         Value = subject.Id, Header = subject.SubjectName
     }).ToList());
     QuestionTypesItems.AddRange(_quetionBankBusiness.GetAllQuestionType().Select((subject) => new PUComboBoxItemModel {
         Value = subject.Id, Header = subject.QuestionTypeName
     }).ToList());
     KnowledgePointItems.AddRange(_quetionBankBusiness.GetAllKnowledgePoint().Select((subject) => new PUComboBoxItemModel {
         Value = subject.Id, Header = subject.KnowledgePointName
     }).ToList());
     TotalPage   = _quetionBankBusiness.GetExaminationQuestionTotalPage(SearchText, SeachQuestionTypeItem, SeachSubjectItem);
     CurrentPage = 1;
 }
Ejemplo n.º 2
0
 public AddQuestionBankViewModel(IWindowManager windowManager)
 {
     _windowManager = windowManager;
     questionTypes  = _quetionBankBusiness.GetAllQuestionType();
     SubjectItems.AddRange(_quetionBankBusiness.GetAllSubject().Select((subject) => new PUComboBoxItemModel {
         Value = subject.Id, Header = subject.SubjectName
     }).ToList());
     QuestionTypesItems.AddRange(questionTypes.Select((subject) => new PUComboBoxItemModel {
         Value = subject.Id, Header = subject.QuestionTypeName
     }).ToList());
     KnowledgePointItems.AddRange(_quetionBankBusiness.GetAllKnowledgePoint().Select((subject) => new PUComboBoxItemModel {
         Value = subject.Id, Header = subject.KnowledgePointName
     }).ToList());
     GradeDifficulty = 2;
 }