Files
lux/Lux.UI/Components/Compo/GenValMan.razor
T
2025-09-18 12:52:47 +02:00

66 lines
2.4 KiB
Plaintext

@if (isLoading || ListRecords == null)
{
<LoadingData></LoadingData>
}
else if (totalCount == 0)
{
<div class="alert alert-info text-center display-4">Nessun record trovato</div>
}
else
{
if (editRecord != null)
{
@* <ItemEdit CurrRecord="editRecord" ListItemGroup="ListItemGroup" EC_Updated="DoSave" EC_Close="DoCancel"></ItemEdit> *@
}
<table class="table table-sm table-striped">
<thead>
<tr>
<th>
<button class="btn btn-sm btn-primary" title="Reset selezione" @onclick="DoReset"><i class="fa-solid fa-arrow-rotate-right"></i></button>
</th>
<th>ID</th>
<th>Gruppo</th>
<th>Ordin</th>
<th>Valore</th>
<th></th>
</tr>
</thead>
<tbody>
@foreach (var item in ListRecords)
{
<tr>
<td class="text-start text-nowrap">
<button class="btn btn-sm btn-primary" @onclick="() => DoSelect(item)"><i class="fa-solid fa-magnifying-glass"></i></button>
<button class="btn btn-sm btn-info" @onclick="() => DoEdit(item)"><i class="fa-solid fa-pencil"></i></button>
<button class="btn btn-sm btn-success" @onclick="() => DoClone(item)"><i class="fa-solid fa-clone"></i></button>
</td>
<td>@item.GenValID</td>
<td>
@if (item.GenClassNav != null)
{
@item.GenClassNav.Description
}
else
{
@item.ClassCod
}
</td>
<td>@item.Ordinal</td>
<td>@item.ValString</td>
<td>
<button class="btn btn-sm btn-danger" @onclick="() => DoDelete(item)"><i class="fa-solid fa-trash-can"></i></button>
</td>
</tr>
}
</tbody>
<tfoot>
<tr>
<td colspan="15">
<EgwCoreLib.Razor.DataPager currPage="@currPage" PageSize="@numRecord" totalCount="@totalCount" numPageChanged="SavePage" numRecordChanged="SaveNumRec"></EgwCoreLib.Razor.DataPager>
</td>
</tr>
</tfoot>
</table>
}