Files
2025-07-08 18:37:35 +02:00

52 lines
2.3 KiB
Plaintext

@using ChartJs
<div class="row">
@if (RawData == null || RawData.Count == 0)
{
<div class="col-12">
<div class="alert alert-secondary text-center h4"><span class="oi oi-graph"></span> No Chart Data</div>
</div>
}
else
{
<div class="col-2">
<div class="border" style="max-height: 14em; overflow:hidden; overflow-y: auto;">
<ul class="list-group list-group-sm small">
@foreach (var item in @ParetoData.OrderBy(x => x.label).ToList())
{
<li class="list-group-item p-1 d-flex justify-content-between align-items-center">
<span>
@if (ShowRem)
{
<button class="btn btn-sm btn-outline-dark" @onclick="() => RemoveMachine(item.label)"><i class="fa-solid fa-xmark"></i> @item.label</button>
}
else
{
@item.label
}
</span>
<span class="badge text-bg-primary rounded-pill">@item.value</span>
</li>
}
</ul>
</div>
</div>
<div class="col-10">
<div class="row">
<div class="col-2">
<PieChart Id="PieODL" AspRatio="1" LegendPos="bottom" Data="@DatiPareto" Labels="@LabelPareto" lineColor="@lineColors" backColor="@bgColors" Title="@pieTitle"></PieChart>
</div>
<div class="col-10">
@if (DynMode)
{
<MultiLine Id="PlotOdlEnergy" AspRatio="4" DataTSList="@TSDataMulti" Labels="@LabelPlot" lineColor="@lineColors" backColor="@bgColors" lTens="0" Titles="@lineTitles" Stepped="false"></MultiLine>
}
else
{
<Line Id="PlotOdlEnergy" AspRatio="4" DataTS="@DatiPlot" Labels="@LabelPlot" lineColor="@lineColor" backColor="@lineColor" lTens="0" Title="@lineTitles.FirstOrDefault()" Stepped="true"></Line>
}
</div>
</div>
</div>
}
</div>