ChronoFlow/ChronoFlow.View/Admin/AdminMainView.axaml

60 lines
2.9 KiB
XML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<UserControl xmlns="https://github.com/avaloniaui"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:model="clr-namespace:ChronoFlow.Model;assembly=ChronoFlow.Model"
x:Class="ChronoFlow.View.Admin.AdminMainView">
<SplitView x:Name="AdminPane" DisplayMode="CompactInline" IsPaneOpen="True" CompactPaneLength="37" OpenPaneLength="200">
<!-- Linke Sidebar (SplitView-Pane) -->
<SplitView.Pane>
<StackPanel>
<!-- Burger-Button -->
<Button Content="☰" Click="TogglePane_Click"/>
<!-- Navigation Buttons -->
<Button Content="🏠 Dashboard" Click="Dashboard_Click"/>
<Button Content="📋 Alle Projekte anzeigen" Click="AlleProjekte_Click"/>
<Button Content="👥 Mitarbeiter-Liste" Click="MitarbeiterListe_Click"/>
<Button Content="✅ Abgeschlossene Projekte" Click="AbgeschlosseneProjekte_Click" />
<Button Content="⚙ Einstellungen" Click="Einstellungen_Click"/>
</StackPanel>
</SplitView.Pane>
<!-- Hauptinhalt -->
<SplitView.Content>
<StackPanel Margin="20" Spacing="15">
<!-- Überschrift -->
<TextBlock Text="Admin-Dashboard" FontSize="24" FontWeight="Bold" HorizontalAlignment="Center"/>
<!-- Aktions-Buttons (oben) -->
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center" Spacing="10">
<Button Content=" Mitarbeiter hinzufügen" Width="200" Height="50" Click="MitarbeiterHinzufuegen_Click"/>
<Button Content=" Projekt erstellen" Width="200" Height="50" Click="ProjektErstellen_Click"/>
</StackPanel>
<!-- Anzeige der letzten Projekte -->
<TextBlock Text="Zuletzt hinzugefügte Projekte" FontSize="18" FontWeight="SemiBold" Margin="0,20,0,10"/>
<ItemsControl x:Name="LetzteProjekteListe">
<ItemsControl.ItemTemplate>
<DataTemplate DataType="{x:Type model:Zeiteintrag}">
<Border BorderBrush="Gray" BorderThickness="1" Padding="10" Margin="0,5">
<StackPanel>
<TextBlock Text="{Binding Projekt}" FontWeight="Bold"/>
<TextBlock Text="{Binding Mitarbeiter}"/>
<TextBlock Text="{Binding Startzeit, StringFormat='Start: {0:G}'}"/>
<TextBlock Text="{Binding Endzeit, StringFormat='Ende: {0:G}'}"/>
</StackPanel>
</Border>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
</StackPanel>
</SplitView.Content>
</SplitView>
</UserControl>