Exemplo n.º 1
0
        public NewGroupForm(NewGroupFormController controller)
        {
            InitializeComponent();
            _controller = controller;

            GetSpecialties();
            codeSpecialtyComboBox.Text   = _controller.CodeSpecialty.ToString();
            _controller.PropertyChanged += _controller_PropertyChanged;
        }
Exemplo n.º 2
0
        private void newGroupButton_Click(object sender, EventArgs e)
        {
            var newGroupController = new NewGroupFormController(_controller.CodeSpecilty);
            var newGroupForm       = new NewGroupForm(newGroupController);

            if (newGroupForm.ShowDialog() == DialogResult.OK)
            {
                IGroup newGroup = newGroupController.Group;
                _controller.AddGroup(newGroup);
            }
            ShowGroups();
        }