Exemple #1
0
        public ExamEnrollmentForm(int examId)
        {
            InitializeComponent();
            _getAllStudentsQueryHandler = DependencyResolver.Instance.Resolve <IGetAllStudentsQueryHandler>();
            _getExamByIdQueryHandler    = DependencyResolver.Instance.Resolve <IGetExamByIdQueryHandler>();
            var exam = _getExamByIdQueryHandler.Handle(examId);

            MapExamToControls(exam);
            FillStudentsList(exam);
        }
Exemple #2
0
        public StudentListForm()
        {
            InitializeComponent();

            _getAllStudentsQueryHandler  = DependencyResolver.Instance.Resolve <IGetAllStudentsQueryHandler>();
            _deleteStudentCommandHandler = DependencyResolver.Instance.Resolve <IDeleteStudentCommandHandler>();

            cbxSortOrder.DataSource = new List <StudentComparersComboBoxItem>
            {
                new StudentComparersComboBoxItem("Name", new ByNameComparer()),
                new StudentComparersComboBoxItem("Entry Date", new ByEntryDateComparer())
            };

            RefreshStudentList();
        }