public bool LoginUser(string login, string password, out string error) { if (WaiterClientModel.LogInUser(login, password)) { var result = OrderWindowViewModel.InitializeUser(out error); if (!result) { WaiterClientModel.LogOut(); } return(result); } else { error = "User login or password was wrong"; return(false); } }
public void LogOut() { WaiterClientModel.LogOut(); }