Vollständige Implementierung des EngineeringSync-Middleware-Tools: - Windows Service (Kestrel :5050) mit FileSystemWatcher + SignalR - WPF Tray-App mit PendingChanges- und Projektverwaltungs-Fenster - Setup-Wizard (8-Schritte-Installer) - SQLite/EF Core Datenschicht (WAL-Modus) - SHA-256-basiertes Debouncing (2s Fenster) - Backup-System mit konfigurierbarer Aufbewahrung Bugfixes & Verbesserungen: - BUG-1: AppDbContext OnConfiguring invertierte Bedingung behoben - BUG-2: Event-Handler-Leak in TrayApp (Fenster-Singleton-Pattern) - BUG-3: ProjectConfigChanged SignalR-Signal in allen CRUD-Endpoints - BUG-5: Rename-Sync löscht alte Datei im Simulations-Ordner - BUG-6: Doppeltes Dispose von SignalR verhindert - BUG-7: Registry-Deinstallation nur EngineeringSync-Eintrag entfernt - S1: Path-Traversal-Schutz via SafeCombine() im SyncManager - E1: FSW Buffer 64KB + automatischer Re-Scan bei Overflow - E2: Retry-Logik (3x) für gesperrte Dateien mit exponentiellem Backoff - E4: Channel.Writer.TryComplete() beim Shutdown - C2: HubMethodNames-Konstanten statt Magic Strings - E3: Pagination in Changes-API (page/pageSize Query-Parameter) - A1: Fire-and-Forget mit try/catch + Logging Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
139 lines
8.5 KiB
XML
139 lines
8.5 KiB
XML
<local:WizardPageBase x:Class="EngineeringSync.Setup.Views.Pages.FirstProjectPage"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:local="clr-namespace:EngineeringSync.Setup.Views.Pages"
|
|
Background="White">
|
|
<Grid Margin="40,32,40,24">
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="Auto"/>
|
|
<RowDefinition Height="Auto"/>
|
|
<RowDefinition Height="*"/>
|
|
</Grid.RowDefinitions>
|
|
|
|
<TextBlock Grid.Row="0" Text="Erstes Projekt konfigurieren"
|
|
Style="{StaticResource PageTitleStyle}"/>
|
|
<TextBlock Grid.Row="1" Style="{StaticResource PageSubtitleStyle}"
|
|
Text="Definieren Sie Ihr erstes überwachtes Projekt. Sie können später über die Tray-App beliebig viele weitere Projekte hinzufügen."/>
|
|
|
|
<ScrollViewer Grid.Row="2" VerticalScrollBarVisibility="Auto">
|
|
<StackPanel>
|
|
|
|
<!-- Projektname -->
|
|
<StackPanel Margin="0,0,0,16">
|
|
<TextBlock Text="PROJEKTNAME" Style="{StaticResource FieldLabelStyle}"/>
|
|
<TextBox Style="{StaticResource ModernTextBoxStyle}"
|
|
Text="{Binding ProjectName, UpdateSourceTrigger=PropertyChanged}"
|
|
Height="36"/>
|
|
</StackPanel>
|
|
|
|
<!-- Engineering-Pfad -->
|
|
<StackPanel Margin="0,0,0,16">
|
|
<TextBlock Style="{StaticResource FieldLabelStyle}">
|
|
<Run Text="ENGINEERING-QUELLPFAD "/>
|
|
<Run Text="(wird überwacht)" Foreground="#0078D4" FontWeight="Normal"/>
|
|
</TextBlock>
|
|
<DockPanel>
|
|
<Button DockPanel.Dock="Right" Style="{StaticResource IconButtonStyle}"
|
|
Margin="6,0,0,0" Click="BrowseEngineering_Click"
|
|
ToolTip="Engineering-Verzeichnis wählen">
|
|
<TextBlock Text="" FontFamily="Segoe MDL2 Assets"
|
|
FontSize="14" Foreground="#0078D4"/>
|
|
</Button>
|
|
<TextBox Style="{StaticResource ModernTextBoxStyle}"
|
|
Text="{Binding EngineeringPath, UpdateSourceTrigger=PropertyChanged}"
|
|
Height="36"/>
|
|
</DockPanel>
|
|
<TextBlock Text="Änderungen in diesem Verzeichnis werden protokolliert und dem Simulations-Ingenieur gemeldet."
|
|
FontFamily="Segoe UI" FontSize="11" Foreground="#5F5F5F" Margin="0,4,0,0"/>
|
|
</StackPanel>
|
|
|
|
<!-- Simulations-Pfad -->
|
|
<StackPanel Margin="0,0,0,16">
|
|
<TextBlock Style="{StaticResource FieldLabelStyle}">
|
|
<Run Text="SIMULATIONS-ZIELPFAD "/>
|
|
<Run Text="(Sync-Ziel)" Foreground="#107C10" FontWeight="Normal"/>
|
|
</TextBlock>
|
|
<DockPanel>
|
|
<Button DockPanel.Dock="Right" Style="{StaticResource IconButtonStyle}"
|
|
Margin="6,0,0,0" Click="BrowseSimulation_Click"
|
|
ToolTip="Simulations-Verzeichnis wählen">
|
|
<TextBlock Text="" FontFamily="Segoe MDL2 Assets"
|
|
FontSize="14" Foreground="#107C10"/>
|
|
</Button>
|
|
<TextBox Style="{StaticResource ModernTextBoxStyle}"
|
|
Text="{Binding SimulationPath, UpdateSourceTrigger=PropertyChanged}"
|
|
Height="36"/>
|
|
</DockPanel>
|
|
<TextBlock Text="Freigegebene Änderungen werden kontrolliert in dieses Verzeichnis kopiert (mit automatischem Backup)."
|
|
FontFamily="Segoe UI" FontSize="11" Foreground="#5F5F5F" Margin="0,4,0,0"/>
|
|
</StackPanel>
|
|
|
|
<!-- Dateiüberwachung -->
|
|
<StackPanel Margin="0,0,0,16">
|
|
<TextBlock Text="ÜBERWACHTE DATEIEN" Style="{StaticResource FieldLabelStyle}"/>
|
|
|
|
<!-- Option: Alle Dateien -->
|
|
<Border Background="#F0F8FF" CornerRadius="6" Padding="12,10" Margin="0,4,0,8">
|
|
<StackPanel Orientation="Horizontal">
|
|
<CheckBox x:Name="WatchAllCheck"
|
|
IsChecked="{Binding WatchAllFiles}"
|
|
VerticalAlignment="Center"
|
|
Margin="0,0,10,0"/>
|
|
<StackPanel>
|
|
<TextBlock Text="Alle Dateitypen überwachen"
|
|
FontFamily="Segoe UI" FontSize="13" FontWeight="SemiBold"
|
|
Foreground="#1B1B2F"/>
|
|
<TextBlock Text="Jede Dateiänderung im Ordner wird protokolliert (unabhängig von der Endung)."
|
|
FontFamily="Segoe UI" FontSize="11" Foreground="#5F5F5F"/>
|
|
</StackPanel>
|
|
</StackPanel>
|
|
</Border>
|
|
|
|
<!-- Spezifische Endungen (nur wenn nicht "Alle Dateien") -->
|
|
<StackPanel Visibility="{Binding WatchAllFiles,
|
|
Converter={StaticResource BoolToInvVisConverter}}">
|
|
<TextBlock Text="DATEIENDUNGEN (komma-getrennt)"
|
|
Style="{StaticResource FieldLabelStyle}" Margin="0,0,0,6"/>
|
|
|
|
<!-- Quick-Select Buttons -->
|
|
<WrapPanel Margin="0,0,0,8">
|
|
<Button Content=".jt" Tag=".jt" Click="AddExt_Click"
|
|
Style="{StaticResource SecondaryButtonStyle}"
|
|
Padding="8,4" Margin="0,0,6,6" Height="26" FontSize="11"/>
|
|
<Button Content=".cojt" Tag=".cojt" Click="AddExt_Click"
|
|
Style="{StaticResource SecondaryButtonStyle}"
|
|
Padding="8,4" Margin="0,0,6,6" Height="26" FontSize="11"/>
|
|
<Button Content=".xml" Tag=".xml" Click="AddExt_Click"
|
|
Style="{StaticResource SecondaryButtonStyle}"
|
|
Padding="8,4" Margin="0,0,6,6" Height="26" FontSize="11"/>
|
|
<Button Content=".stp" Tag=".stp" Click="AddExt_Click"
|
|
Style="{StaticResource SecondaryButtonStyle}"
|
|
Padding="8,4" Margin="0,0,6,6" Height="26" FontSize="11"/>
|
|
<Button Content=".step" Tag=".step" Click="AddExt_Click"
|
|
Style="{StaticResource SecondaryButtonStyle}"
|
|
Padding="8,4" Margin="0,0,6,6" Height="26" FontSize="11"/>
|
|
<Button Content=".igs" Tag=".igs" Click="AddExt_Click"
|
|
Style="{StaticResource SecondaryButtonStyle}"
|
|
Padding="8,4" Margin="0,0,6,6" Height="26" FontSize="11"/>
|
|
<Button Content=".iges" Tag=".iges" Click="AddExt_Click"
|
|
Style="{StaticResource SecondaryButtonStyle}"
|
|
Padding="8,4" Margin="0,0,6,6" Height="26" FontSize="11"/>
|
|
<Button Content=".prt" Tag=".prt" Click="AddExt_Click"
|
|
Style="{StaticResource SecondaryButtonStyle}"
|
|
Padding="8,4" Margin="0,0,6,6" Height="26" FontSize="11"/>
|
|
</WrapPanel>
|
|
|
|
<TextBox x:Name="ExtensionsBox"
|
|
Style="{StaticResource ModernTextBoxStyle}"
|
|
Text="{Binding FileExtensions, UpdateSourceTrigger=PropertyChanged}"
|
|
Height="36"/>
|
|
<TextBlock Text="Klicke auf einen Typ um ihn hinzuzufügen, oder tippe direkt."
|
|
FontFamily="Segoe UI" FontSize="11" Foreground="#5F5F5F" Margin="0,4,0,0"/>
|
|
</StackPanel>
|
|
</StackPanel>
|
|
|
|
</StackPanel>
|
|
</ScrollViewer>
|
|
</Grid>
|
|
</local:WizardPageBase>
|