1e5fda085d
- modifica default data conf (non roaming) - eliminate notifiche multiple - update msg doppia esecuzione
93 lines
2.4 KiB
Plaintext
93 lines
2.4 KiB
Plaintext
@using EgwControlCenter.Core
|
|
@using EgwControlCenter.Core.Models
|
|
@inject AppControlService ACService
|
|
|
|
<table class="table table-striped table-sm text-start shadow border">
|
|
<thead>
|
|
<tr class="bg-dark bg-gradient text-light">
|
|
<th>Application</th>
|
|
<th>Installed</th>
|
|
<th>Available</th>
|
|
<th class="text-end">Note</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@if (ListRecords == null || ListRecords.Count == 0)
|
|
{
|
|
<tr>
|
|
<td colspan="5">
|
|
<div class="alert alert-warning">Nessun aggiornamento disponibile!</div>
|
|
</td>
|
|
</tr>
|
|
}
|
|
else
|
|
{
|
|
@foreach (var item in ListRecords)
|
|
{
|
|
<tr>
|
|
<td>
|
|
@item.CodApp
|
|
@if (item.HasUpdate)
|
|
{
|
|
<i class="fa-solid fa-bell text-success mx-2"></i>
|
|
}
|
|
</td>
|
|
<td>
|
|
@item.VersNumCurr
|
|
@if (item.VersNumCurr=="0.0.0.0")
|
|
{
|
|
<i class="fa-solid fa-triangle-exclamation text-warning mx-2"></i>
|
|
}
|
|
</td>
|
|
<td>@item.VersNumLast</td>
|
|
<td>@item.RelTagsLast</td>
|
|
</tr>
|
|
}
|
|
}
|
|
</tbody>
|
|
</table>
|
|
|
|
@code {
|
|
|
|
|
|
[Parameter]
|
|
public bool OnlyUpdate { get; set; } = false;
|
|
|
|
[Parameter]
|
|
public EventCallback<bool> EC_GotoSetup { get; set; }
|
|
|
|
private List<VersStatusDTO>? ListRecords { get; set; } = null;
|
|
|
|
private List<VersStatusDTO> CurrRecords
|
|
{
|
|
get => ACService.ListAppStatus;
|
|
// set => ACService.ListAppStatus = value;
|
|
}
|
|
|
|
protected override void OnParametersSet()
|
|
{
|
|
// fix parametro visualizzazione solo update
|
|
ForceReload();
|
|
}
|
|
|
|
protected override void OnInitialized()
|
|
{
|
|
ACService.EA_StatusUpdated += ACService_EA_StatusUpdated;
|
|
}
|
|
private void ACService_EA_StatusUpdated()
|
|
{
|
|
// fermo il timer e lo riavvio...
|
|
ForceReload();
|
|
}
|
|
|
|
private void ForceReload()
|
|
{
|
|
// ListRecords = null;
|
|
ListRecords = CurrRecords
|
|
.Where(x => x.HasUpdate || !OnlyUpdate)
|
|
.ToList();
|
|
StateHasChanged();
|
|
}
|
|
|
|
}
|