예제 #1
0
        private void btnLogin_Click(object sender, EventArgs e)
        {
            string email    = tbxUsername.Text;
            string password = tbxPassword.Text;

            if (conn.Login(email, password))
            {
                Managment   mg = new Managment(email);
                AbsenceForm af = new AbsenceForm();
                af.Show();
                mg.Show();
            }
            else
            {
                MessageBox.Show("Invalid data!");
            }
        }
예제 #2
0
 public ScheduleControl(Schedule formObject, Managment mng)
 {
     this.schedule = formObject;
     this.mng      = mng;
     InitializeComponent();
     lblShiftsDepartment.Text = "Department: " + formObject.DepartmentStr;
     if (formObject.DepartmentD == Department.SALES)
     {
         cmbxChooseFloor.Visible = true;
         lblChooseFloor.Visible  = true;
     }
     else
     {
         cmbxChooseFloor.Visible = false;
         lblChooseFloor.Visible  = false;
     }
     InitializeSchedulerOptionsMenu();
 }