Settings: collapse advanced sections + dedicated About + default DB name

- DB default name: "proserve" → "proserveapi" (matches the ASTERION install
  script that provisions XAMPP on client machines).
- Settings dialog reorganized:
   1. License de mise à jour     [expanded] ← business-critical
   2. Langue                     [expanded] ← user preference
   3. ▸ PARAMÈTRES AVANCÉS       [collapsed by default]
        contains Server, Installation, Cache, Database, Logs
   4. À PROPOS                   [expanded] ← version + copyright
- The Expander hides plumbing the casual user shouldn't touch (server URL,
  install root, MySQL config, cache directory) but keeps it one click away
  for power users / support diagnostics.
- About card kept always-visible because version info is what support asks
  for first when troubleshooting.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-05-03 08:36:57 +02:00
parent 1473e5185c
commit f86895553a
3 changed files with 55 additions and 14 deletions

View File

@@ -142,6 +142,18 @@
</StackPanel> </StackPanel>
</Border> </Border>
<!--
Sections "techniques" : Server / Installation / Cache / Database / Logs
repliées par défaut sous un Expander pour ne pas noyer les sections
importantes (License, Langue, About) qui restent dépliées en haut/bas.
-->
<Expander Header="{x:Static loc:Strings.SettingsAdvanced}"
Foreground="{StaticResource Brush.Text.Secondary}"
FontSize="11" FontWeight="Bold"
Background="Transparent" BorderThickness="0"
Margin="0,0,0,16" IsExpanded="False">
<StackPanel Margin="0,12,0,0">
<!-- Serveur --> <!-- Serveur -->
<Border Background="{StaticResource Brush.Bg.Card}" <Border Background="{StaticResource Brush.Bg.Card}"
BorderBrush="{StaticResource Brush.Border}" BorderThickness="1" BorderBrush="{StaticResource Brush.Border}" BorderThickness="1"
@@ -357,7 +369,7 @@
</StackPanel> </StackPanel>
</Border> </Border>
<!-- Logs / About --> <!-- Logs (path + open button) -->
<Border Background="{StaticResource Brush.Bg.Card}" <Border Background="{StaticResource Brush.Bg.Card}"
BorderBrush="{StaticResource Brush.Border}" BorderThickness="1" BorderBrush="{StaticResource Brush.Border}" BorderThickness="1"
CornerRadius="6" Padding="20" Margin="0,0,0,16"> CornerRadius="6" Padding="20" Margin="0,0,0,16">
@@ -366,17 +378,7 @@
FontSize="11" FontWeight="Bold" FontSize="11" FontWeight="Bold"
Foreground="{StaticResource Brush.Text.Secondary}" Foreground="{StaticResource Brush.Text.Secondary}"
Margin="0,0,0,8" /> Margin="0,0,0,8" />
<TextBlock FontSize="13" <Grid>
Foreground="{StaticResource Brush.Text.Primary}">
<Run Text="{x:Static loc:Strings.SettingsLauncherVersion}" />
<Run Text=" " />
<Run Text="{Binding LauncherVersion, Mode=OneWay}" FontWeight="SemiBold" />
</TextBlock>
<TextBlock Text="{x:Static loc:Strings.Copyright}"
FontSize="12"
Foreground="{StaticResource Brush.Text.Secondary}"
Margin="0,4,0,0" />
<Grid Margin="0,8,0,0">
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="*" /> <ColumnDefinition Width="*" />
<ColumnDefinition Width="Auto" /> <ColumnDefinition Width="Auto" />
@@ -399,6 +401,35 @@
</StackPanel> </StackPanel>
</Border> </Border>
</StackPanel>
</Expander>
<!--
Section "À propos" : version + copyright. Toujours visible (pas dans
l'Expander Avancé) car c'est une info utile au support / pour
rapporter un bug. Mince et discrète, pas de bouton.
-->
<Border Background="{StaticResource Brush.Bg.Card}"
BorderBrush="{StaticResource Brush.Border}" BorderThickness="1"
CornerRadius="6" Padding="20" Margin="0,0,0,16">
<StackPanel>
<TextBlock Text="{x:Static loc:Strings.SettingsAbout}"
FontSize="11" FontWeight="Bold"
Foreground="{StaticResource Brush.Text.Secondary}"
Margin="0,0,0,8" />
<TextBlock FontSize="13"
Foreground="{StaticResource Brush.Text.Primary}">
<Run Text="{x:Static loc:Strings.SettingsLauncherVersion}" />
<Run Text=" " />
<Run Text="{Binding LauncherVersion, Mode=OneWay}" FontWeight="SemiBold" />
</TextBlock>
<TextBlock Text="{x:Static loc:Strings.Copyright}"
FontSize="12"
Foreground="{StaticResource Brush.Text.Secondary}"
Margin="0,4,0,0" />
</StackPanel>
</Border>
</StackPanel> </StackPanel>
</ScrollViewer> </ScrollViewer>

View File

@@ -152,6 +152,14 @@ public static class Strings
"تطبيق الترقيات تلقائياً عند تثبيت نسخة جديدة" "تطبيق الترقيات تلقائياً عند تثبيت نسخة جديدة"
); );
public static string SettingsDbReplay => T("🔁 Rejouer les migrations", "🔁 Replay migrations", "🔁 重新执行迁移", "🔁 เรียกใช้การโยกย้ายอีกครั้ง", "🔁 إعادة تشغيل الترقيات"); public static string SettingsDbReplay => T("🔁 Rejouer les migrations", "🔁 Replay migrations", "🔁 重新执行迁移", "🔁 เรียกใช้การโยกย้ายอีกครั้ง", "🔁 إعادة تشغيل الترقيات");
public static string SettingsAdvanced => T(
"▸ PARAMÈTRES AVANCÉS (serveur, installation, base de données, logs)",
"▸ ADVANCED SETTINGS (server, installation, database, logs)",
"▸ 高级设置(服务器、安装、数据库、日志)",
"▸ ตั้งค่าขั้นสูง (เซิร์ฟเวอร์ การติดตั้ง ฐานข้อมูล บันทึก)",
"▸ الإعدادات المتقدمة (الخادم، التثبيت، قاعدة البيانات، السجلات)"
);
public static string SettingsAbout => T("À PROPOS", "ABOUT", "关于", "เกี่ยวกับ", "حول");
public static string SettingsDbHint => T( public static string SettingsDbHint => T(
"Le launcher applique automatiquement les scripts SQL bundled dans _migrations/ de chaque ZIP PROSERVE. Mot de passe stocké chiffré DPAPI.", "Le launcher applique automatiquement les scripts SQL bundled dans _migrations/ de chaque ZIP PROSERVE. Mot de passe stocké chiffré DPAPI.",
"The launcher automatically applies SQL scripts bundled in each PROSERVE ZIP's _migrations/ folder. Password stored DPAPI-encrypted.", "The launcher automatically applies SQL scripts bundled in each PROSERVE ZIP's _migrations/ folder. Password stored DPAPI-encrypted.",

View File

@@ -57,9 +57,11 @@ public sealed class DatabaseConfig
/// <summary> /// <summary>
/// Nom de la base de données qui contient les tables de PROSERVE. /// Nom de la base de données qui contient les tables de PROSERVE.
/// Default "proserve" — change si ton install crée la DB sous un autre nom. /// Default "proserveapi" — c'est le nom utilisé par le script d'install ASTERION
/// qui provisionne XAMPP sur les machines clients. À surcharger seulement si la DB
/// a été créée sous un autre nom.
/// </summary> /// </summary>
public string Database { get; set; } = "proserve"; public string Database { get; set; } = "proserveapi";
/// <summary> /// <summary>
/// Si true, le launcher applique automatiquement les migrations SQL bundled /// Si true, le launcher applique automatiquement les migrations SQL bundled