NeoVac only reports per-mille shares of the property; the own costs in CHF come from the property manager's statement. The new page stores both in water-heating.json (per mandator) and calculates the CHF parts: water base and consumption costs by their per-mille share, consumption split by m³ into warm and cold water, and the warm water part of the heating costs (the rest is room heating). Charts for water (m³), heat (MWh) and the stacked costs; the dialog has a guide image showing where each value is on the bills. The Wasser page stays for bills with the CHF values entered directly. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
89 lines
4.8 KiB
Text
89 lines
4.8 KiB
Text
@implements IDialogContentComponent<Schaad.Accounting.Models.WaterHeatingBill>
|
||
@rendermode InteractiveServer
|
||
|
||
<FluentDialogHeader ShowDismiss="true">
|
||
<FluentStack VerticalAlignment="VerticalAlignment.Center">
|
||
<FluentIcon Value="@(new Icons.Regular.Size24.WindowApps())" />
|
||
<FluentLabel Typo="Typography.PaneHeader">
|
||
@Dialog.Instance.Parameters.Title
|
||
</FluentLabel>
|
||
</FluentStack>
|
||
</FluentDialogHeader>
|
||
|
||
<FluentDialogBody>
|
||
<EditForm EditContext="@editContext">
|
||
<DataAnnotationsValidator />
|
||
<FluentStack Orientation="Orientation.Horizontal">
|
||
<FluentDatePicker @bind-Value="@periodFrom" Label="Von" Style="width: 170px;" />
|
||
<FluentDatePicker @bind-Value="@periodTo" Label="Bis" Style="width: 170px;" />
|
||
</FluentStack>
|
||
|
||
<div style="@SectionStyle">NeoVac – Ablesequittung (Verbrauch verrechnet)</div>
|
||
<FluentStack Orientation="Orientation.Horizontal">
|
||
<FluentNumberField @bind-Value="@Content.WarmWaterM3" @bind-Value:after="Content.CalculateCosts" Label="Warmwasser (m³)" Style="width: 170px;" />
|
||
<FluentNumberField @bind-Value="@Content.ColdWaterM3" @bind-Value:after="Content.CalculateCosts" Label="Kaltwasser (m³)" Style="width: 170px;" />
|
||
</FluentStack>
|
||
<FluentStack Orientation="Orientation.Horizontal">
|
||
<FluentNumberField @bind-Value="@Content.HeatingMwh" Label="Wärme (MWh)" Style="width: 170px;" />
|
||
</FluentStack>
|
||
|
||
<div style="@SectionStyle">NeoVac – Anteil (‰)</div>
|
||
<FluentStack Orientation="Orientation.Horizontal">
|
||
<FluentNumberField @bind-Value="@Content.WaterBasePermille" @bind-Value:after="Content.CalculateCosts" Label="Wasser Grund (‰)" Style="width: 170px;" />
|
||
<FluentNumberField @bind-Value="@Content.WaterConsumptionPermille" @bind-Value:after="Content.CalculateCosts" Label="Wasser Verbrauch (‰)" Style="width: 170px;" />
|
||
</FluentStack>
|
||
<FluentStack Orientation="Orientation.Horizontal">
|
||
<FluentNumberField @bind-Value="@Content.HeatingPermille" @bind-Value:after="Content.CalculateCosts" Label="Heizung total (‰)" Style="width: 170px;" />
|
||
<FluentNumberField @bind-Value="@Content.WarmWaterHeatingPermille" @bind-Value:after="Content.CalculateCosts" Label="Heizung WW (‰)" Style="width: 170px;" />
|
||
</FluentStack>
|
||
|
||
<div style="@SectionStyle">Verwaltung – Ihr Anteil (CHF)</div>
|
||
<FluentStack Orientation="Orientation.Horizontal">
|
||
<FluentNumberField @bind-Value="@Content.WaterCostsChf" @bind-Value:after="Content.CalculateCosts" Label="Wasserkosten (CHF)" Style="width: 170px;" />
|
||
<FluentNumberField @bind-Value="@Content.HeatingCostsChf" @bind-Value:after="Content.CalculateCosts" Label="Heizkosten (CHF)" Style="width: 170px;" />
|
||
</FluentStack>
|
||
<div>
|
||
<FluentValidationSummary />
|
||
</div>
|
||
</EditForm>
|
||
|
||
<div style="margin-top: 12px; font-size: 13px; color: #52514e;">
|
||
Wasser: Grundkosten <strong>@Chf(Content.BaseCostsChf)</strong>
|
||
· Warmwasser <strong>@Chf(Content.WarmWaterChf)</strong>
|
||
· Kaltwasser <strong>@Chf(Content.ColdWaterChf)</strong>
|
||
</div>
|
||
<div style="margin-top: 4px; font-size: 13px; color: #52514e;">
|
||
Heizung: Warmwasser <strong>@Chf(Content.WarmWaterHeatingChf)</strong>
|
||
· Räume <strong>@Chf(Content.RoomHeatingChf)</strong>
|
||
</div>
|
||
<div style="margin-top: 4px; font-size: 13px; color: #52514e;">
|
||
Total <strong>@M3(Content.TotalM3)</strong> · <strong>@Mwh(Content.HeatingMwh)</strong> · <strong>@Chf(Content.TotalChf)</strong>
|
||
</div>
|
||
|
||
<FluentButton Appearance="Appearance.Lightweight" Style="margin-top: 12px; padding: 0; font-size: 13px;" OnClick="ShowGuideAsync">
|
||
Woher kommen die Werte? (NeoVac-Abrechnung)
|
||
</FluentButton>
|
||
</FluentDialogBody>
|
||
|
||
<FluentDialogFooter>
|
||
<FluentButton Appearance="Appearance.Neutral"
|
||
OnClick="@CancelAsync">
|
||
Abbrechen
|
||
</FluentButton>
|
||
<FluentButton Appearance="Appearance.Accent"
|
||
Disabled="@(periodFrom is null || periodTo is null)"
|
||
OnClick="@SaveAsync">
|
||
Speichern
|
||
</FluentButton>
|
||
</FluentDialogFooter>
|
||
|
||
@code {
|
||
private const string SectionStyle = "margin-top: 14px; font-size: 11px; font-weight: bold; color: #898781; text-transform: uppercase;";
|
||
|
||
// Shown in its own dialog (see ShowGuideAsync) instead of expanding inline: this dialog has a
|
||
// fixed Height, and FluentDialogBody doesn't resize to fit growing content.
|
||
private RenderFragment GuideImage =>
|
||
@<img src="/images/water-heating-bill-guide.svg"
|
||
alt="Beispiel-Abrechnung mit Markierungen, welcher Wert in welches Feld gehört"
|
||
style="width: 100%; height: auto; display: block;" />;
|
||
}
|