feat: sync guard - Blockieren alter Clients beim sync
This commit is contained in:
@@ -30,8 +30,7 @@
|
||||
<DrawerPage x:Name="RootDrawer"
|
||||
DrawerLength="220"
|
||||
DrawerBehavior="Auto"
|
||||
DrawerLayoutBehavior="CompactInline"
|
||||
Content="{Binding CurrentPage}">
|
||||
DrawerLayoutBehavior="CompactInline">
|
||||
|
||||
<DrawerPage.DataTemplates>
|
||||
<DataTemplate DataType="vm:DashboardViewModel">
|
||||
@@ -63,6 +62,26 @@
|
||||
</DataTemplate>
|
||||
</DrawerPage.DataTemplates>
|
||||
|
||||
<DrawerPage.Content>
|
||||
<DockPanel>
|
||||
<Border DockPanel.Dock="Top"
|
||||
IsVisible="{Binding SyncStatus.IsIncompatibleVersion}"
|
||||
Background="#B3261E" Padding="16,12">
|
||||
<StackPanel Orientation="Horizontal" Spacing="10">
|
||||
<TextBlock Text="⚠" FontSize="18" Foreground="White"
|
||||
VerticalAlignment="Center"/>
|
||||
<StackPanel>
|
||||
<TextBlock Text="Software-Update erforderlich"
|
||||
Foreground="White" FontWeight="SemiBold"/>
|
||||
<TextBlock Text="{x:Static vm:SyncStatusViewModel.IncompatibleVersionMessage}"
|
||||
Foreground="White" Opacity="0.92" TextWrapping="Wrap"/>
|
||||
</StackPanel>
|
||||
</StackPanel>
|
||||
</Border>
|
||||
<ContentControl Content="{Binding CurrentPage}"/>
|
||||
</DockPanel>
|
||||
</DrawerPage.Content>
|
||||
|
||||
<DrawerPage.Drawer>
|
||||
<DockPanel Classes.compact="{Binding !#RootDrawer.IsOpen}">
|
||||
<DockPanel.Styles>
|
||||
|
||||
@@ -4,14 +4,19 @@
|
||||
x:Class="LehrerApp.Desktop.Views.SyncStatusBar"
|
||||
x:DataType="vm:SyncStatusViewModel">
|
||||
<Grid ColumnDefinitions="*,Auto">
|
||||
<StackPanel Grid.Column="0">
|
||||
<StackPanel Grid.Column="0" IsVisible="{Binding !IsIncompatibleVersion}">
|
||||
<TextBlock Text="{Binding StatusText}" FontSize="12" Opacity="0.7"
|
||||
TextTrimming="CharacterEllipsis"/>
|
||||
<TextBlock Text="{Binding LastSyncText}" FontSize="10" Opacity="0.4"/>
|
||||
</StackPanel>
|
||||
<StackPanel Grid.Column="0" IsVisible="{Binding IsIncompatibleVersion}">
|
||||
<TextBlock Text="⚠ Update erforderlich" FontSize="12" FontWeight="SemiBold"
|
||||
Foreground="#D32F2F"/>
|
||||
<TextBlock Text="Sync angehalten" FontSize="10" Foreground="#D32F2F" Opacity="0.8"/>
|
||||
</StackPanel>
|
||||
<Button Grid.Column="1" Content="↻" FontSize="14"
|
||||
Command="{Binding SyncNowCommand}"
|
||||
IsVisible="{Binding IsServerConfigured}"
|
||||
IsVisible="{Binding CanAttemptSync}"
|
||||
Background="Transparent" Padding="6,4"
|
||||
ToolTip.Tip="Jetzt synchronisieren"/>
|
||||
</Grid>
|
||||
|
||||
Reference in New Issue
Block a user