Exemplo n.º 1
0
        private void LoadForm(int id)
        {
            this.Entity = this.Logic.GetOne(id);
            this.anioTextBox.Text = this.Entity.AnioCalendario.ToString();
            this.cupoTextBox.Text = this.Entity.Cupo.ToString();
            this.especialidadDropDownList.SelectedValue = this.Entity.IDEspecialidad.ToString();
            this.loadCmbPlan(this.Entity.IDEspecialidad);
            this.planDropDownList.SelectedValue = this.Entity.IDPlan.ToString();
            this.loadCmbComision(this.Entity.IDPlan);
            this.comisionDropDownList.SelectedValue = this.Entity.IDComision.ToString();
            this.loadCmbMateria(this.Entity.IDPlan);
            this.materiaDropDownList.SelectedValue = this.Entity.IDMateria.ToString();

            UsuarioLogic ul = new UsuarioLogic();
            List<Usuario> docentes = ul.GetDocentesByCurso(id);
            this.cmbDocentes.ClearSelection();
            foreach (Usuario docente in docentes)
            {
                this.cmbDocentes.Items.FindByValue(docente.ID.ToString()).Selected = true;
            }
        }
Exemplo n.º 2
0
 public void Listar()
 {
     UsuarioLogic ul = new UsuarioLogic();
     this.dgvDocentes.AutoGenerateColumns = false;
     this.dgvDocentes.DataSource = ul.GetDocentesByCurso(this.cursoActual.ID);
 }