From 914631eaed075d7f4c79651ce3c9e1461b93cccf Mon Sep 17 00:00:00 2001
From: Natlinux81 <97396587+Natlinux81@users.noreply.github.com>
Date: Thu, 11 Aug 2022 22:28:51 +0200
Subject: [PATCH] edited SelectedTournamenStore
---
Apollon.WPF/Models/Tournament.cs | 8 +++--
.../ApollonOverviewDetailsViewModel.cs | 3 +-
.../Components/ApollonOverviewDetails.xaml | 30 ++++++++++++++++---
3 files changed, 33 insertions(+), 8 deletions(-)
diff --git a/Apollon.WPF/Models/Tournament.cs b/Apollon.WPF/Models/Tournament.cs
index ad6e739..500c594 100644
--- a/Apollon.WPF/Models/Tournament.cs
+++ b/Apollon.WPF/Models/Tournament.cs
@@ -8,19 +8,21 @@ namespace Apollon.WPF.Models
{
public class Tournament
{
- public Tournament(string organisation, string tournamentname, string category, DateTime datetime, string location)
+ public Tournament(string organisation, string tournamentname, string category, DateTime startdate, DateTime enddate, string location)
{
Organisation = organisation;
Tournamentname = tournamentname;
Category = category;
- Datetime = datetime;
+ Startdate = startdate;
+ Enddate = enddate;
Location = location;
}
public string Organisation { get; }
public string Tournamentname { get; }
public string Category { get; }
- public DateTime Datetime { get; }
+ public DateTime Startdate { get; }
+ public DateTime Enddate { get; }
public string Location { get; }
}
}
diff --git a/Apollon.WPF/ViewModels/ApollonOverviewDetailsViewModel.cs b/Apollon.WPF/ViewModels/ApollonOverviewDetailsViewModel.cs
index 9c7d663..df24240 100644
--- a/Apollon.WPF/ViewModels/ApollonOverviewDetailsViewModel.cs
+++ b/Apollon.WPF/ViewModels/ApollonOverviewDetailsViewModel.cs
@@ -18,7 +18,8 @@ namespace Apollon.WPF.ViewModels
public string Organisation => _selectedTournament?.Organisation ?? "keine Organisation";
public string Tournamentname => _selectedTournament?.Tournamentname ?? "kein Name";
public string Category => _selectedTournament?.Category ?? "keine Kategorie";
- //public DateTime Datetime => _selectedTournament
+ public DateTime Startdate => _selectedTournament?.Startdate ?? DateTime.MinValue;
+ public DateTime Enddate => _selectedTournament?.Enddate ?? DateTime.MinValue;
public string Location => _selectedTournament?.Location ?? "kein Ort";
public ApollonOverviewDetailsViewModel(SelectedTournamentStore selectedTournamentStore)
diff --git a/Apollon.WPF/Views/Components/ApollonOverviewDetails.xaml b/Apollon.WPF/Views/Components/ApollonOverviewDetails.xaml
index 8c8e151..7a90790 100644
--- a/Apollon.WPF/Views/Components/ApollonOverviewDetails.xaml
+++ b/Apollon.WPF/Views/Components/ApollonOverviewDetails.xaml
@@ -18,21 +18,43 @@
FontWeight="Bold"
FontSize="14"
Foreground="#0000a0"
- Margin="40"/>
-
+
+ Margin="10"/>
+
+
+
+
+
+
+ Margin="10"/>