Ejemplo n.º 1
0
 private void Click_Login(object sender, RoutedEventArgs e)
 {
     if (userRestClient.Login(usernameTextbox.Text, passwordTextbox.Password.ToString()))
     {
         mainVM.CurrentControl = new Chat(mainVM, userRestClient);
         mainVM.HideButtons();
     }
     else
     {
         errorLabel.Content = "Credentials are invalid!";
     }
 }
Ejemplo n.º 2
0
        private void Click_Login(object sender, RoutedEventArgs e)
        {
            UserRestClient userRestClient = new UserRestClient(-1);

            //usernameTextbox.Text
            //passwordTextbox.Password.ToString()
            if (userRestClient.Login("admin", "admin"))
            {
                mainVM.CurrentControl = new Editor(userRestClient.CurrentUser);
            }
            else
            {
                errorLabel.Content = "Credentials are invalid!";
            }
        }