diff --git a/src/IBKRTrader.App/Shell/CoreViews.cs b/src/IBKRTrader.App/Shell/CoreViews.cs index 049ecbf..ef9ad9e 100644 --- a/src/IBKRTrader.App/Shell/CoreViews.cs +++ b/src/IBKRTrader.App/Shell/CoreViews.cs @@ -32,6 +32,13 @@ public static class CoreViews CreateView = () => new WorkersWindow(host, sp.GetRequiredService()) }); + host.RegisterView(new ModuleView + { + Id = "core.positions", Title = "Positionen", Group = "Core", Order = 15, + CreateView = () => new PositionsWindow( + host, sp.GetRequiredService()) + }); + host.RegisterView(new ModuleView { Id = "core.logs", Title = "Logs", Group = "Core", Order = 20, diff --git a/src/IBKRTrader.App/ViewModels/Rows.cs b/src/IBKRTrader.App/ViewModels/Rows.cs index 5035c9f..c141da2 100644 --- a/src/IBKRTrader.App/ViewModels/Rows.cs +++ b/src/IBKRTrader.App/ViewModels/Rows.cs @@ -22,6 +22,19 @@ public sealed record LogRow(string Text, IBrush Color); /// Eine offene Position im Modul-Fenster. public sealed record PositionRow(string Symbol, int Quantity, decimal AvgPrice, decimal Notional); +/// +/// Eine Zeile der Positionsverwaltung (#485). Zahlen kommen als fertiger Text: Die Formatierung +/// gehoert an eine Stelle, und „Broker“ muss zwischen „null Stück“ und „keine Auskunft“ +/// unterscheiden koennen - ein Zahlentyp kann das nicht. +/// +public sealed record ManagedPositionRow( + string Book, string Origin, string Instrument, string Quantity, string AvgPrice, + string Bound, string Broker, string Restrictions); + +/// Bestand, den der Broker fuehrt und den kein Buch beansprucht. +public sealed record UnknownPositionRow( + string Symbol, string SecType, string Currency, string Quantity, string AvgCost, string Note); + /// Eine Zeile der Supervisor-Berichtsliste. Tokens als fertiger Text (Prompt / Completion). public sealed record SupervisorReportRow( DateTime CreatedAt, string Profile, string Model, string Question, int ToolCallCount, string Tokens); diff --git a/src/IBKRTrader.App/Views/PositionsWindow.axaml b/src/IBKRTrader.App/Views/PositionsWindow.axaml new file mode 100644 index 0000000..2282859 --- /dev/null +++ b/src/IBKRTrader.App/Views/PositionsWindow.axaml @@ -0,0 +1,78 @@ + + + + + + + +