feat: page-based navigation shell + Tests page wizard

Replace the monolithic MainWindow with a SelectedPage-driven shell
(Dashboard / Pump / Bench / Tests / Results / Settings). The Tests
page gets the Plan -> Preconditions -> Running -> Done wizard from
ui-structure.md \u00a74, backed by a 7-item precondition gate and
shared sub-views (PhaseCardView / TestSectionView / GraphicIndicatorView)
extracted from the now-deleted monolithic TestPanelView.

New VMs / views:
- Tests wizard: TestPreconditions, PhaseCard, GraphicIndicator,
  TestSection, TestPlan, TestRunning, TestDone
- Dashboard panels: DashboardConnection, DashboardReadings,
  DashboardAlarms, InterlockBanner, ResultHistory
- Pump / bench panels: PumpIdentificationPanel, PumpLiveData,
  UnlockPanel, BenchDriveControl, BenchReadings, RelayBank,
  TemperatureControl, DtcList, AuthGate
- Dialogs: generic ConfirmDialog, UserManageDialog, UserPromptDialog

Supporting changes:
- IsOilPumpOn exposed on MainViewModel for precondition evaluation
- RequiresAuth added to TestDefinition (XML round-trip)
- BipStatusDefinition + CompletedTestRun models
- ~35 new Test.* localization keys (en + es)
- Settings moved from modal dialog to full page
- Pause / Retry / Skip stubs in TestRunningView; full spec in
  docs/gap-test-running-controls.md for follow-up implementation
- docs/ui-structure.md captures the wizard design

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-04-18 13:11:34 +02:00
parent 37d099cdbd
commit 0280a2fad1
110 changed files with 8008 additions and 1115 deletions

View File

@@ -0,0 +1,40 @@
using CommunityToolkit.Mvvm.ComponentModel;
using HC_APTBS.Models;
using HC_APTBS.Services;
namespace HC_APTBS.ViewModels
{
/// <summary>
/// ViewModel for a curated bank of auxiliary relay toggles on the Bench page.
/// Excludes relays driven by dedicated controls
/// (oil pump, direction, heater / cooler, counter).
/// </summary>
public sealed partial class RelayBankViewModel : ObservableObject
{
private readonly IBenchService _bench;
/// <summary>Solenoid power / pump keep-alive relay.</summary>
[ObservableProperty] private bool _isElectronicOn;
/// <summary>Panel flasher relay (status lamp blink).</summary>
[ObservableProperty] private bool _isFlasherOn;
/// <summary>4-pulse-per-revolution output signal relay.</summary>
[ObservableProperty] private bool _isPulse4SignalOn;
/// <param name="benchService">Bench service used to drive the relays.</param>
public RelayBankViewModel(IBenchService benchService)
{
_bench = benchService;
}
partial void OnIsElectronicOnChanged(bool value)
=> _bench.SetRelay(RelayNames.Electronic, value);
partial void OnIsFlasherOnChanged(bool value)
=> _bench.SetRelay(RelayNames.Flasher, value);
partial void OnIsPulse4SignalOnChanged(bool value)
=> _bench.SetRelay(RelayNames.Pulse4Signal, value);
}
}