Example #1
0
        public static void showForm(CourseHall hall)
        {
            CourseHallEditForm form = new CourseHallEditForm();

            form.hall = hall;
            Model.Course course = hall.courseRef;
            form.editPanel.nameBox.text   = course.name;
            form.editPanel.idBox.text     = course.id;
            form.editPanel.remarkBox.text = course.remark;
            form.editPanel.attWeight.setSelectedIntValue(course.getRecord(Record.RType.attendance).weight);
            form.editPanel.lateWeight.setSelectedIntValue(course.getRecord(Record.RType.late).weight);
            form.editPanel.sickWeight.setSelectedIntValue(course.getRecord(Record.RType.sickLeave).weight);
            form.editPanel.busWeight.setSelectedIntValue(course.getRecord(Record.RType.businessLeave).weight);
            form.editPanel.absWeight.setSelectedIntValue(course.getRecord(Record.RType.absenteeism).weight);
            form.editPanel.resize(null, null);
            form.ShowDialog();
        }
Example #2
0
 private void bar_settingBtn_Click(object sender, EventArgs e)
 {
     CourseHallEditForm.showForm(this);
 }