Exemple #1
0
 private void TFDListView_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
 {
     var discId = ((List<DisciplineView>)TFDListView.DataSource)[e.RowIndex].DisciplineId;
     var tefd = _repo.TeacherForDisciplines.GetFirstFiltredTeacherForDiscipline(tfd => tfd.Discipline.DisciplineId == discId);
     if (tefd != null)
     {
         var addLessonForm = new AddLesson(_repo, tefd.TeacherForDisciplineId);
         addLessonForm.Show();
     }
     else
     {
         var addLessonForm = new AddLesson(_repo);
         addLessonForm.Show();
     }
 }
Exemple #2
0
 private void Button1Click(object sender, EventArgs e)
 {
     var addLessonForm = new AddLesson(Repo);
     addLessonForm.Show();
 }