MainWindowViewModel.cs 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. using Auth.Models;
  2. using Avalonia.Styling;
  3. using ReactiveUI;
  4. using System.Security.Cryptography.X509Certificates;
  5. namespace Auth.ViewModels
  6. {
  7. public class MainWindowViewModel : ViewModelBase
  8. {
  9. string _login = "";
  10. string _password = "";
  11. public string Login
  12. {
  13. get
  14. {
  15. return _login;
  16. }
  17. set
  18. {
  19. this.RaiseAndSetIfChanged(ref _login, value);
  20. }
  21. }
  22. public string Password
  23. {
  24. get
  25. {
  26. return _password;
  27. }
  28. set
  29. {
  30. this.RaiseAndSetIfChanged(ref _password, value);
  31. }
  32. }
  33. public void Knopka()
  34. {
  35. data data = new data();
  36. if (_login == data.login && _password == data.password)
  37. {
  38. }
  39. else
  40. {
  41. }
  42. }
  43. }
  44. }