Files
lux/Lux.UI/Components/Compo/Item/SellingItemMan.razor
T
Samuele Locatelli 7e65c8a406 Varie code cleanup
2026-06-10 16:57:13 +02:00

100 lines
4.3 KiB
Plaintext

@inherits BaseComp
@if (isLoading || ListRecords == null)
{
<LoadingData></LoadingData>
}
else if (totalCount == 0)
{
<div class="alert alert-info text-center display-4">@Traduci("noRecord")</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="@Traduci("reset")" @onclick="DoReset"><i class="fa-solid fa-arrow-rotate-right"></i></button>
</th>
<th class="text-center">@Traduci("ambiente")</th>
<th>@Traduci("anteprima")</th>
<th>@Traduci("articoli_sorgente")</th>
<th class="text-end">@Traduci("articoli_jobId")</th>
<th>@Traduci("articoli_servizio")</th>
<th>@Traduci("codice")</th>
<th>@Traduci("articoli_itemCode")</th>
<th>@Traduci("articoli_supplCode")</th>
<th>@Traduci("descrizione")</th>
<th class="text-end">@Traduci("articoli_costo")</th>
<th class="text-end">@Traduci("margine")</th>
<th class="text-end">@Traduci("unitaMisura")</th>
<th></th>
</tr>
</thead>
<tbody>
@foreach (var item in ListRecords)
{
<tr class="@checkSel(item)">
<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 @doCloneCss(item)" @onclick="() => DoClone(item)"><i class="fa-solid fa-clone"></i></button> *@
</td>
<td class=" text-center">
<div class="condensed">@item.Envir</div>
<div class="small">(@item.SellingItemID)</div>
</td>
<td>
@* <img class="img-fluid p-1" src="@(imgUrl(item.ImgType, item.ImgUID, $"{item.Envir}"))" width="64" /> *@
<img class="img-fluid p-1" src="@imgSrc(item.ImgUrl)" width="64" />
</td>
<td>
@item.SourceType
<div class="small text-secondary">@item.ImgType</div>
</td>
<td class="text-end text-nowrap">
@item.JobID
</td>
<td>@item.IsService</td>
<td>@item.ItemCode</td>
<td>@item.ExtItemCode</td>
<td>@item.SupplCode</td>
<td>@item.Description</td>
<td class="text-end text-nowrap">
@item.Cost.ToString("C3")
</td>
<td class="text-end">@item.Margin.ToString("P1")</td>
<td class="text-end">@item.UM</td>
<td>
@if (false)
{
<button class="btn btn-sm btn-danger" @onclick="() => DoDelete(item)"><i class="fa-solid fa-trash-can"></i></button>
}
else
{
<button class="btn btn-sm btn-secondary disabled"><i class="fa-solid fa-trash-can"></i></button>
}
</td>
</tr>
}
</tbody>
@if (totalCount >= numRecord)
{
<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>
}
<BootstrapModal @ref=Modal Title=@mTitle Message=@mMessage Mode="mMode" UserOptions=@modalOpt></BootstrapModal>