using Avalonia.Controls; using Avalonia.Interactivity; using Avalonia.Markup.Xaml; using Demka_Snova_1.Hardik.Conect.Dao; namespace Demka_Snova_1.OknaFunciy; public partial class AddSotrudnikWindow : Window { public SotrudnikDao NewSotrudnik { get; set; } public AddSotrudnikWindow() { InitializeComponent(); } private void InitializeComponent() { AvaloniaXamlLoader.Load(this); } private void SaveSotrudnik(object sender, RoutedEventArgs e) { NewSotrudnik = new SotrudnikDao { Fio = this.FindControl("FIO").Text, Pozition = this.FindControl("Pozition").Text, Login = this.FindControl("Login").Text, Pass = this.FindControl("Pass").Text, TipeEnt = "User" }; Close(); } private void Cancel(object sender, RoutedEventArgs e) { Close(); } }