public AutoAddExaminationPaperViewModel(IWindowManager windowManager) { _windowManager = windowManager; SubjectItems.AddRange(_quetionBankBusiness.GetAllSubject().Select((subject) => new PUComboBoxItemModel { Value = subject.Id, Header = subject.SubjectName }).ToList()); SubjectValue = Convert.ToInt32(SubjectItems.FirstOrDefault().Value); }
public AddExaminationPaperViewModel(IWindowManager windowManager) { _windowManager = windowManager; AddQuestionBackToPaper = new AddQuestionBackToPaper(this); DeleteQuestionBackToPaper = new DeleteQuestionBackToPaper(this); SubjectItems.AddRange(_quetionBankBusiness.GetAllSubject().Select((subject) => new PUComboBoxItemModel { Value = subject.Id, Header = subject.SubjectName }).ToList()); SubjectValue = Convert.ToInt32(SubjectItems.FirstOrDefault().Value); TotalPage = _quetionBankBusiness.GetExaminationQuestionTotalPage(SearchText, QuestionTypesValue, TestPaper.SubjectId); CurrentPage = 1; }