public AddOrEditClassForm(DBManager dbManag)
{
InitializeComponent();
mDBManager = dbManag;
this.Text = FormTitles.ClassForm.Add;
mFormState = FormState.AddingNew;
RadListDataItem dropDownItem = new RadListDataItem("1");
dropDownItem.Value = 1;
dropDownItem.Selected = true;
gradeDropdownlist.Items.Add(dropDownItem);
for (int i = 2; i <= 12; ++i)
{
dropDownItem = new RadListDataItem(i.ToString());
dropDownItem.Value = i;
gradeDropdownlist.Items.Add(dropDownItem);
}
importTeachersFromTheDatabase();
changingHeadteacherReadyButton.Visible = false;
teachersDropdownlist.Visible = false;
changeHeadTeacherButton.Visible = false;
changingHeadteacherReadyButton.Visible = true;
teachersDropdownlist.Visible = true;
colorPanel.BackColor = RandomColor.GetRandomColor();
gradeDropdownlist.DropDownStyle = RadDropDownStyle.DropDownList;
teachersDropdownlist.DropDownStyle = RadDropDownStyle.DropDownList;
}