diff --git a/WpfApp1/WpfApp1/Coach.cs b/WpfApp1/WpfApp1/Coach.cs
index ff57716..9bd5d83 100644
--- a/WpfApp1/WpfApp1/Coach.cs
+++ b/WpfApp1/WpfApp1/Coach.cs
@@ -12,6 +12,15 @@ namespace WpfApp1
public string Name { get; set; }
public string Patronymic { get; set; }
public string Speciality { get; set; }
+ public string ShortFIO
+ {
+ get
+ {
+ string n = !string.IsNullOrEmpty(Name) ? $"{Name[0]}." : "";
+ string p = !string.IsNullOrEmpty(Patronymic) ? $"{Patronymic[0]}." : "";
+ return $"{Surname} {n}{p}";
+ }
+ }
public Coach() { }
}
}
diff --git a/WpfApp1/WpfApp1/RecordWindow.xaml b/WpfApp1/WpfApp1/RecordWindow.xaml
index 5dba752..be648ad 100644
--- a/WpfApp1/WpfApp1/RecordWindow.xaml
+++ b/WpfApp1/WpfApp1/RecordWindow.xaml
@@ -12,10 +12,18 @@
-
+
+
+
+
+
+
+
+
+
-
+
diff --git a/WpfApp1/WpfApp1/RecordWindow.xaml.cs b/WpfApp1/WpfApp1/RecordWindow.xaml.cs
index 35c3dbd..3f25d66 100644
--- a/WpfApp1/WpfApp1/RecordWindow.xaml.cs
+++ b/WpfApp1/WpfApp1/RecordWindow.xaml.cs
@@ -23,7 +23,7 @@ namespace WpfApp1
{
private Client _currentClient;
private List _allCoaches = new List();
- private const string CoachesFilePath = "Data/coaches.json";
+ private const string CoachesFilePath = "C:\\Users\\student1\\source\\repos\\UP01TASK2\\WpfApp1\\WpfApp1\\Data\\coaches.json";
private void LoadCoachesData()
{
@@ -34,9 +34,8 @@ namespace WpfApp1
_allCoaches = JsonSerializer.Deserialize>(json, options) ?? new List();
- // Заполняем ComboBox специальностей
cbSpeciality.ItemsSource = _allCoaches
- .Select(c => c.Speciality)
+ .Select(c => c.Speciality )
.Distinct()
.ToList();
}