Ejemplo n.º 1
0
        private void Button_Click_1(object sender, RoutedEventArgs e)
        {
            Window win2 = new View_Workers(service);

            win2.Show();
            Close();
        }
Ejemplo n.º 2
0
 private void Button_Click(object sender, RoutedEventArgs e)
 {
     if (service.checklogin(txtUser.Text, pswd.Text))
     {
         MessageBox.Show("משתמש קיים");
     }
     else
     {
         DB_connector.AddNewWorker(txtUser.Text, pswd.Text);
         MessageBox.Show("Success!");
         Window w2 = new View_Workers(service);
         w2.Show();
         this.Close();
     }
 }
Ejemplo n.º 3
0
 private void Delete_Click(object sender, RoutedEventArgs e)
 {
     if (VM.SelectedWorker is null)
     {
         MessageBox.Show("Choose A Worker");
     }
     else
     {
         DB_connector.DeleteWorker(VM.SelectedWorker.worker_id);
         //remember to delete all shifts also
         Window w2 = new View_Workers(service);
         w2.Show();
         this.Close();
     }
 }