/// <summary> /// Изменинить состояние посещения для студента /// </summary> /// <param name="student"></param> public void ChangeStudentState(StudentAttendanceModel student) { AttendanceProvider.ChangeState( student.Student.Id, Schedule.Id, Date, student.State); }
private void VisitBox_CheckedChanged(object sender, EventArgs e) { CheckBox checkBox = sender as CheckBox; StudentAttendanceModel model = this.Tag as StudentAttendanceModel; model.State = checkBox.Checked ? Models.AttendanceLogState.visited : Models.AttendanceLogState.skiped; StateChanged?.Invoke(model, EventArgs.Empty); }
/// <summary> /// Изменинить состояние посещения для студента /// </summary> /// <param name="student"></param> public void ChangeStudentState(StudentAttendanceModel student) { Model.ChangeStudentState(student); }
public void SetStudentAttendance(StudentAttendanceModel model) { studentName.Text = $"{model.Student.LastName} {model.Student.FirstName} {model.Student.Patronymic}"; visitBox.Checked = model.State == Models.AttendanceLogState.visited; }