- Modificata modale con parti
- Modificata modale con scelta grezzi - Modificata modale per bilanciamento
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<Nullable>enable</Nullable>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Version>1.1.2607.0308</Version>
|
||||
<Version>1.1.2607.0310</Version>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
||||
@@ -546,12 +546,11 @@ else if (WorkLoadRecord != null)
|
||||
{
|
||||
if (CurrEditMode == EditMode.WorkLoadDetailTime)
|
||||
{
|
||||
@*<TimeEstim DetailRecord="WorkLoadRecord" OrderRowRecord="SelRecord" AllProdGroup="ListProdAssign" EC_ReRunReq="ReRunJob" EC_ClosePopup="ClosePopup" EC_RunBalance="ReqBalance" EC_DirectAssign="DirectAssign" EC_ResetAssign="ResetAssign"></TimeEstim>*@
|
||||
<TimeEstim MergeOrderRow=@currMergeOrderRow EC_ReRunReq="ReRunJob" EC_ClosePopup="ClosePopup" EC_RunBalance="ReqBalance" EC_DirectAssign="DirectAssign" EC_ResetAssign="ResetAssign"></TimeEstim>
|
||||
}
|
||||
else if (CurrEditMode == EditMode.WorkLoadDetailTag)
|
||||
{
|
||||
<PartStatus DetailRecord="@WorkLoadRecord" EC_ReRunReq="ReRunJob" EC_ClosePopup="ClosePopup"></PartStatus>
|
||||
<PartStatus MergeOrderRow=@currMergeOrderRow EC_ReRunReq="ReRunJob" EC_ClosePopup="ClosePopup"></PartStatus>
|
||||
}
|
||||
@* else if (CurrEditMode == EditMode.DetailOkVin)
|
||||
{
|
||||
|
||||
@@ -7,18 +7,19 @@
|
||||
<span class="input-group-text" id="inputGroup-sizing-default">mm</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-5">
|
||||
@if (BalanceReq.MachineBalance != null && BalanceReq.MachineBalance.Count == 1)
|
||||
@if (BalanceReq.MachineBalance != null && BalanceReq.MachineBalance.Count == 1)
|
||||
{
|
||||
@foreach (var item in BalanceReq.MachineBalance)
|
||||
{
|
||||
<div class="row">
|
||||
@foreach (var item in BalanceReq.MachineBalance)
|
||||
{
|
||||
<SingleRequest CurrReq="@(new SingleRequest.PercRequest(item.Key, item.Value))" Mode=@Mode EC_Updated="UpdatePerc"></SingleRequest>
|
||||
}
|
||||
</div>
|
||||
<SingleRequest CurrReq="@(new SingleRequest.PercRequest(item.Key, item.Value))" Mode=@Mode EC_Updated="UpdatePerc"></SingleRequest>
|
||||
}
|
||||
</div>
|
||||
<div class="col-2">
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="col-5">
|
||||
</div>
|
||||
}
|
||||
<div class="col-2 text-end">
|
||||
@if (Mode == TimeEstim.SetMode.Balance)
|
||||
{
|
||||
@if (checkSend)
|
||||
@@ -46,14 +47,10 @@
|
||||
@if (BalanceReq.MachineBalance != null && BalanceReq.MachineBalance.Count > 1)
|
||||
{
|
||||
<div class="row mb-2">
|
||||
<div class="col-12">
|
||||
<div class="row">
|
||||
@foreach (var item in BalanceReq.MachineBalance)
|
||||
{
|
||||
<SingleRequest CurrReq="@(new SingleRequest.PercRequest(item.Key, item.Value))" Mode=@Mode EC_Updated="UpdatePerc"></SingleRequest>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
@foreach (var item in BalanceReq.MachineBalance)
|
||||
{
|
||||
<SingleRequest CurrReq="@(new SingleRequest.PercRequest(item.Key, item.Value))" Mode=@Mode EC_Updated="UpdatePerc"></SingleRequest>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
@@ -5,7 +5,7 @@
|
||||
<div class="row w-100">
|
||||
<div class="col-4 fs-3">
|
||||
Dettaglio Workload
|
||||
@if (DetailRecord.Workable)
|
||||
@if (DetailRecord != null && DetailRecord.Workable)
|
||||
{
|
||||
<i class="fa-solid fa-thumbs-up text-success"></i>
|
||||
}
|
||||
@@ -15,19 +15,102 @@
|
||||
}
|
||||
</div>
|
||||
<div class="col-4 text-center border border-2 rounded">
|
||||
<div class="fw-bold">Impianti considerati</div>
|
||||
<small class="small">@DetailRecord.ListMachinesJoin</small>
|
||||
<div>
|
||||
<b>Impianti considerati:</b>
|
||||
<small class="small">@(DetailRecord?.ListMachinesJoin ?? "")</small>
|
||||
</div>
|
||||
<div>
|
||||
<b>Riga ordine:</b>
|
||||
<small class="small">@MergeOrderRow.Original.OrderRowCode</small>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-4 text-end fs-4">
|
||||
<button class="btn btn-lg btn-primary" @onclick="() => ReRunJob()"><i class="fa-solid fa-share-from-square" title="Riesecuzione Estimate"></i> Re-Run</button>
|
||||
<button class="btn btn-primary" @onclick="() => ReRunJob()"><i class="fa-solid fa-share-from-square" title="Riesecuzione Estimate"></i> Re-Run</button>
|
||||
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close" @onclick="() => ClosePopup()">
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="accordion" id="accordionPanelsStayOpenExample">
|
||||
@if (DetailRecord.NumKo > 0)
|
||||
<div class="row mt-2 mx-0">
|
||||
@if (DetailRecord != null && DetailRecord.NumKo > 0)
|
||||
{
|
||||
<div class="card px-0 mb-2">
|
||||
<div class="card-header">
|
||||
<div class="px-0 align-items-center" style="cursor: pointer;" @onclick="() => ToggleGroup(TypeGroup.Unwork)">
|
||||
<div>
|
||||
Non producibili: <span class="fw-bold px-1">@MergeOrderRow.WorkLoad?.NumKo</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@if (showUnwork)
|
||||
{
|
||||
<div class="card-body">
|
||||
<div class="row gx-2">
|
||||
@foreach (var item in DetailRecord.ListUnWorkable)
|
||||
{
|
||||
<div class="col-2">
|
||||
<div class="alert alert-danger p-1 mb-2 text-center align-content-center">@item</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
@if (DetailRecord != null && DetailRecord.NumOkVin > 0)
|
||||
{
|
||||
<div class="card px-0 mb-2">
|
||||
<div class="card-header">
|
||||
<div class="d-flex px-0 align-items-center" style="cursor: pointer;" @onclick="() => ToggleGroup(TypeGroup.Vincolate)">
|
||||
<div>
|
||||
Vincolati: <span class="fw-bold px-1">@MergeOrderRow.WorkLoad?.NumOkVin</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@if (showVinc)
|
||||
{
|
||||
<div class="card-body">
|
||||
<div class="row gx-2">
|
||||
@foreach (var item in DetailRecord.ListVincolated)
|
||||
{
|
||||
<div class="col-2">
|
||||
<div class="alert alert-info p-1 mb-2 text-center align-content-center">@item</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
@if (DetailRecord != null && DetailRecord.NumOk > 0)
|
||||
{
|
||||
<div class="card px-0 mb-2">
|
||||
<div class="card-header">
|
||||
<div class="d-flex px-0 align-items-center" style="cursor: pointer;" @onclick="() => ToggleGroup(TypeGroup.Work)">
|
||||
<div>
|
||||
Producibili: <span class="fw-bold px-1">@MergeOrderRow.WorkLoad?.NumOk</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@if (showWork)
|
||||
{
|
||||
<div class="card-body">
|
||||
<div class="row gx-2">
|
||||
@foreach (var item in DetailRecord.ListWorkable)
|
||||
{
|
||||
<div class="col-2">
|
||||
<div class="alert alert-success p-1 mb-2 text-center align-content-center">@item</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
@* <div class="accordion" id="accordionPanelsStayOpenExample">
|
||||
@if (DetailRecord != null && DetailRecord.NumKo > 0)
|
||||
{
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header">
|
||||
@@ -51,7 +134,7 @@
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
@if (DetailRecord.NumOkVin > 0)
|
||||
@if (DetailRecord != null && DetailRecord.NumOkVin > 0)
|
||||
{
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header">
|
||||
@@ -75,7 +158,7 @@
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
@if (DetailRecord.NumOk > 0)
|
||||
@if (DetailRecord != null && DetailRecord.NumOk > 0)
|
||||
{
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header">
|
||||
@@ -99,7 +182,7 @@
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div> *@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
using static Lux.UI.Components.Compo.Order.OrderRowMan;
|
||||
|
||||
namespace Lux.UI.Components.Compo.WorkLoad
|
||||
{
|
||||
public partial class PartStatus
|
||||
@@ -5,7 +7,7 @@ namespace Lux.UI.Components.Compo.WorkLoad
|
||||
#region Public Properties
|
||||
|
||||
[Parameter]
|
||||
public WorkLoadDetailDTO DetailRecord { get; set; } = null!;
|
||||
public MergedOrderRow MergeOrderRow { get; set; } = null!;
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<bool> EC_ClosePopup { get; set; }
|
||||
@@ -17,6 +19,14 @@ namespace Lux.UI.Components.Compo.WorkLoad
|
||||
|
||||
#region Protected Methods
|
||||
|
||||
protected override void OnParametersSet()
|
||||
{
|
||||
if(MergeOrderRow.WorkLoad != null)
|
||||
{
|
||||
DetailRecord = MergeOrderRow.WorkLoad;
|
||||
}
|
||||
}
|
||||
|
||||
protected Task ClosePopup()
|
||||
{
|
||||
return EC_ClosePopup.InvokeAsync(true);
|
||||
@@ -27,6 +37,35 @@ namespace Lux.UI.Components.Compo.WorkLoad
|
||||
return EC_ReRunReq.InvokeAsync(true);
|
||||
}
|
||||
|
||||
private WorkLoadDetailDTO? DetailRecord = null;
|
||||
private bool showUnwork = false;
|
||||
private bool showVinc = false;
|
||||
private bool showWork = false;
|
||||
|
||||
private enum TypeGroup
|
||||
{
|
||||
Unwork,
|
||||
Vincolate,
|
||||
Work
|
||||
}
|
||||
|
||||
private void ToggleGroup(TypeGroup mode)
|
||||
{
|
||||
switch(mode)
|
||||
{
|
||||
case TypeGroup.Unwork:
|
||||
showUnwork = !showUnwork;
|
||||
break;
|
||||
case TypeGroup.Vincolate:
|
||||
showVinc = !showVinc;
|
||||
break;
|
||||
case TypeGroup.Work:
|
||||
showWork = !showWork;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#endregion Protected Methods
|
||||
}
|
||||
}
|
||||
@@ -1,27 +1,25 @@
|
||||
<div class="modal" tabindex="-1" style="display:block; background-color: rgba(10,10,10,.6);" role="dialog">
|
||||
<div class="modal-dialog modal-xl">
|
||||
<div class="modal-dialog modal-lg">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<div class="d-flex justify-content-between w-100">
|
||||
<div class="d-flex justify-content-between align-items-center w-100">
|
||||
<div class="px-0 d-flex">
|
||||
<div class="px-0 fs-5">
|
||||
<div class="px-0 fs-5">
|
||||
<h3>Selezione Materiali</h3>
|
||||
</div>
|
||||
<div class="px-0 fs-5">
|
||||
<div class="px-0">
|
||||
@if (canSend)
|
||||
{
|
||||
<button class="btn btn-lg btn-success mx-2 fs-3 py-0" @onclick="DoSendCalc" title="Invia Richiesta">Invia <i class="fa-solid fa-upload"></i></button>
|
||||
<button class="btn btn-success mx-2 fs-5 py-0" @onclick="DoSendCalc" title="Invia Richiesta">Invia <i class="fa-solid fa-upload"></i></button>
|
||||
}
|
||||
else
|
||||
{
|
||||
<button class="btn btn-lg btn-secondary disabled mx-2 fs-3 py-0" title="Invia Richiesta">Invia <i class="fa-solid fa-upload"></i></button>
|
||||
<button class="btn btn-secondary disabled fs-5 mx-2 py-0" title="Invia Richiesta">Invia <i class="fa-solid fa-upload"></i></button>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div class="px-0">
|
||||
<div class="input-group">
|
||||
<button class="btn btn-lg fs-3 py-0" @onclick="DoClose"><i class="fa-solid fa-xmark" title="Close Preview"></i></button>
|
||||
</div>
|
||||
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close" @onclick="DoClose"></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -41,12 +39,11 @@
|
||||
<table class="table table-sm table-striped mb-0">
|
||||
<thead>
|
||||
<tr>
|
||||
@* <th class="text-nowrap"></th> *@
|
||||
<th class="text-nowrap">Item</th>
|
||||
<th class="text-nowrap">Qty</th>
|
||||
<th class="text-nowrap text-end" style="width: 40%;">
|
||||
<th class="text-nowrap col-4">Item</th>
|
||||
<th class="text-nowrap col-2">Varianti</th>
|
||||
<th class="text-nowrap text-end col-6">
|
||||
Grezzi
|
||||
<button class="btn btn-sm btn-success" @onclick="() => DoAddStdSetAll()" title="Aggiungi set standard a tutti"><i class="fa-solid fa-plus"></i> All</button>
|
||||
<button class="btn btn-sm btn-success ms-2" @onclick="() => DoAddStdSetAll()" title="Aggiungi set standard a tutti"><i class="fa-solid fa-plus"></i> All</button>
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
@@ -54,20 +51,18 @@
|
||||
@foreach (var item in ListRecords)
|
||||
{
|
||||
<tr class="@checkSel(item.Key)">
|
||||
@* <td><button class="btn btn-sm btn-info" @onclick="() => DoSelect(item)"><i class="fa-solid fa-magnifying-glass"></i></button></td> *@
|
||||
<td class="">@item.Key</td>
|
||||
<td class="">
|
||||
@item.Value.Count
|
||||
<button class="btn btn-sm btn-success" @onclick="() => DoAddStdSet(item)" title="Aggiungi set standard"><i class="fa-solid fa-plus"></i></button>
|
||||
@item.Value.Count <button class="btn btn-sm btn-success ms-4" @onclick="() => DoAddStdSet(item)" title="Aggiungi set standard"><i class="fa-solid fa-plus"></i></button>
|
||||
</td>
|
||||
<td class="small">
|
||||
@foreach (var rawMat in item.Value)
|
||||
{
|
||||
<div class="input-group input-group-sm" >
|
||||
<span class="input-group-text">Num</span>
|
||||
<input class="form-control" placeholder="Indicare Quantità" aria-label="Qty" type="number" @bind="@rawMat.Qty">
|
||||
<input class="form-control text-end" placeholder="Indicare Quantità" type="number" @bind="@rawMat.Qty">
|
||||
<span class="input-group-text">Size</span>
|
||||
<input class="form-control" placeholder="Dimensioni" aria-label="Dimensioni" type="number" @bind="@rawMat.Lenght">
|
||||
<input class="form-control text-end" placeholder="Dimensioni" type="number" @bind="@rawMat.Lenght">
|
||||
<button class="btn btn-danger" @onclick="() => DoRemoveSize(item.Key, rawMat)"><i class="fa-solid fa-trash"></i></button>
|
||||
</div>
|
||||
}
|
||||
|
||||
@@ -23,25 +23,61 @@ namespace Lux.UI.Components.Compo.WorkLoad
|
||||
|
||||
#endregion Public Properties
|
||||
|
||||
#region Protected Fields
|
||||
|
||||
protected List<ItemGroupModel> ListItemGroup = new List<ItemGroupModel>();
|
||||
protected Dictionary<string, List<ItemRawDTO>>? ListRecords = null;
|
||||
|
||||
#endregion Protected Fields
|
||||
|
||||
#region Protected Properties
|
||||
|
||||
protected ItemSel.FiltSelect CurrFilt { get; set; } = new ItemSel.FiltSelect();
|
||||
|
||||
#endregion Protected Properties
|
||||
|
||||
#region Protected Methods
|
||||
|
||||
protected override void OnParametersSet()
|
||||
{
|
||||
isLoading = true;
|
||||
UpdateTable();
|
||||
}
|
||||
|
||||
#endregion Protected Methods
|
||||
|
||||
#region Private Fields
|
||||
|
||||
private KeyValuePair<string, List<ItemRawDTO>>? CurrBomItem = null;
|
||||
private Dictionary<string, List<ItemRawDTO>>? ListRecords = null;
|
||||
|
||||
private int currPage = 1;
|
||||
private bool isLoading = false;
|
||||
private int numRecord = 10;
|
||||
private int totalCount = 0;
|
||||
|
||||
#endregion Private Fields
|
||||
|
||||
#region Private Properties
|
||||
private ItemSel.FiltSelect CurrFilt { get; set; } = new ItemSel.FiltSelect();
|
||||
|
||||
private string mainColCss => CurrBomItem == null ? "col-12" : "col-6";
|
||||
private bool canSend
|
||||
{
|
||||
get => ItemAvailDict.Any(x => x.Value.Any(y => y.Qty > 0));
|
||||
}
|
||||
|
||||
#endregion Private Properties
|
||||
|
||||
#region Private Methods
|
||||
|
||||
private string checkSel(string curKey)
|
||||
{
|
||||
string answ = CurrBomItem != null && CurrBomItem.Value.Key == curKey ? "table-info" : "";
|
||||
return answ;
|
||||
}
|
||||
|
||||
private async Task DoClose(MouseEventArgs args)
|
||||
{
|
||||
await EC_ReqClose.InvokeAsync(true);
|
||||
}
|
||||
|
||||
private async Task DoSendCalc(MouseEventArgs args)
|
||||
{
|
||||
await EC_ReqCalcProd.InvokeAsync(ItemAvailDict);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Selezione record x inserimento tipo RawMat da impiegare
|
||||
/// </summary>
|
||||
/// <param name="selRec"></param>
|
||||
/// <param name="selEntry"></param>
|
||||
private void DoSelect(KeyValuePair<string, List<ItemRawDTO>> selEntry)
|
||||
{
|
||||
CurrFilt = new ItemSel.FiltSelect()
|
||||
@@ -118,27 +154,21 @@ namespace Lux.UI.Components.Compo.WorkLoad
|
||||
CurrBomItem = null;
|
||||
}
|
||||
|
||||
protected override void OnParametersSet()
|
||||
{
|
||||
isLoading = true;
|
||||
UpdateTable();
|
||||
}
|
||||
|
||||
protected void SaveNumRec(int newNum)
|
||||
private void SaveNumRec(int newNum)
|
||||
{
|
||||
isLoading = true;
|
||||
numRecord = newNum;
|
||||
UpdateTable();
|
||||
}
|
||||
|
||||
protected void SavePage(int newNum)
|
||||
private void SavePage(int newNum)
|
||||
{
|
||||
isLoading = true;
|
||||
currPage = newNum;
|
||||
UpdateTable();
|
||||
}
|
||||
|
||||
protected void UpdateTable()
|
||||
private void UpdateTable()
|
||||
{
|
||||
totalCount = ItemAvailDict.Count;
|
||||
ListRecords = ItemAvailDict
|
||||
@@ -157,50 +187,6 @@ namespace Lux.UI.Components.Compo.WorkLoad
|
||||
isLoading = false;
|
||||
}
|
||||
|
||||
#endregion Protected Methods
|
||||
|
||||
private string checkSel(string curKey)
|
||||
{
|
||||
string answ = CurrBomItem != null && CurrBomItem.Value.Key == curKey ? "table-info" : "";
|
||||
return answ;
|
||||
}
|
||||
|
||||
#region Private Fields
|
||||
|
||||
#if false
|
||||
private BomItemDTO? CurrBomItem = null;
|
||||
#endif
|
||||
private KeyValuePair<string, List<ItemRawDTO>>? CurrBomItem = null;
|
||||
private int currPage = 1;
|
||||
private bool isLoading = false;
|
||||
private int numRecord = 10;
|
||||
private int totalCount = 0;
|
||||
|
||||
protected bool canSend
|
||||
{
|
||||
get => ItemAvailDict.Any(x => x.Value.Any(y => y.Qty > 0));
|
||||
}
|
||||
|
||||
#endregion Private Fields
|
||||
|
||||
#region Private Properties
|
||||
|
||||
private string mainColCss => CurrBomItem == null ? "col-12" : "col-6";
|
||||
|
||||
#endregion Private Properties
|
||||
|
||||
#region Private Methods
|
||||
|
||||
private async Task DoClose(MouseEventArgs args)
|
||||
{
|
||||
await EC_ReqClose.InvokeAsync(true);
|
||||
}
|
||||
private async Task DoSendCalc(MouseEventArgs args)
|
||||
{
|
||||
await EC_ReqCalcProd.InvokeAsync(ItemAvailDict);
|
||||
}
|
||||
|
||||
|
||||
#endregion Private Methods
|
||||
}
|
||||
}
|
||||
@@ -1,25 +1,47 @@
|
||||
<div class="col input-group">
|
||||
<span class="input-group-text">@CurrReq.Key</span>
|
||||
<input type="number" readonly class="form-control" value="@FormattedValue" />
|
||||
@* <InputPercent CssClass="form-control" Value="@((decimal)CurrReq.Value)" ValueChanged="SetPerc"></InputPercent> *@
|
||||
@if (Mode == TimeEstim.SetMode.Balance)
|
||||
{
|
||||
<button class="btn btn-sm btn-outline-success" @onclick="() => SetPerc(0)">0%</button>
|
||||
<button class="btn btn-sm btn-outline-success" @onclick="() => SetPerc((decimal)0.5)">50%</button>
|
||||
<button class="btn btn-sm btn-outline-success" @onclick="() => SetPerc(1)">100%</button>
|
||||
}
|
||||
<div class="@DimCss">
|
||||
<div class="input-group">
|
||||
<span class="input-group-text">@CurrReq.Key</span>
|
||||
@if (enableModValue)
|
||||
{
|
||||
<input type="number" class="form-control text-end" @bind="@SetValue"/>
|
||||
}
|
||||
else
|
||||
{
|
||||
<input type="number" readonly class="form-control text-end bg-body-secondary" value="@FormattedValue" />
|
||||
}
|
||||
@* <InputPercent CssClass="form-control" Value="@((decimal)CurrReq.Value)" ValueChanged="SetPerc"></InputPercent> *@
|
||||
@if (Mode == TimeEstim.SetMode.Balance)
|
||||
{
|
||||
<button class="btn btn-sm btn-outline-success" @onclick="() => SetPerc(0)">0%</button>
|
||||
<button class="btn btn-sm btn-outline-success" @onclick="() => SetPerc((decimal)0.5)">50%</button>
|
||||
<button class="btn btn-sm btn-outline-success" @onclick="() => SetPerc(1)">100%</button>
|
||||
<button class="btn btn-sm btn-outline-success" @onclick="() => EnableMod()">Set</button>
|
||||
}
|
||||
else
|
||||
{
|
||||
<span class="input-group-text">%</span>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@code {
|
||||
|
||||
public record PercRequest(string Key, double Value);
|
||||
|
||||
[Parameter]
|
||||
public PercRequest CurrReq { get; set; } = null!;
|
||||
|
||||
[Parameter]
|
||||
public TimeEstim.SetMode Mode { get; set; } = TimeEstim.SetMode.None;
|
||||
|
||||
/// <summary>
|
||||
/// Event for update
|
||||
/// </summary>
|
||||
[Parameter]
|
||||
public EventCallback<PercRequest> EC_Updated { get; set; }
|
||||
|
||||
public record PercRequest(string Key, double Value);
|
||||
|
||||
private bool enableModValue = false;
|
||||
|
||||
private string FormattedValue{
|
||||
get
|
||||
{
|
||||
@@ -28,11 +50,20 @@
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Event for update
|
||||
/// </summary>
|
||||
[Parameter]
|
||||
public EventCallback<PercRequest> EC_Updated { get; set; }
|
||||
private string DimCss => Mode == TimeEstim.SetMode.Balance ? "col-5" : "col-3";
|
||||
|
||||
private double SetValue
|
||||
{
|
||||
get
|
||||
{
|
||||
return CurrReq.Value * 100;
|
||||
}
|
||||
set
|
||||
{
|
||||
CurrReq = CurrReq with { Value = (double)value /100 };
|
||||
_ = EC_Updated.InvokeAsync(CurrReq);
|
||||
}
|
||||
}
|
||||
|
||||
private async Task SetPerc(decimal reqValue)
|
||||
{
|
||||
@@ -40,4 +71,9 @@
|
||||
await EC_Updated.InvokeAsync(CurrReq);
|
||||
}
|
||||
|
||||
private void EnableMod()
|
||||
{
|
||||
enableModValue = !enableModValue;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -143,7 +143,7 @@
|
||||
<th class="col-1">
|
||||
<button class="btn btn-sm btn-success" @onclick="() => ToggleAssignMode(GroupOkList, SetMode.None)"><i class="fa-solid fa-rotate-right"></i></button>
|
||||
</th>
|
||||
<th class="col-4">
|
||||
<th class="col-6">
|
||||
Impianti
|
||||
</th>
|
||||
<th class="col-2 text-end">
|
||||
|
||||
@@ -203,7 +203,7 @@ namespace Lux.UI.Components.Pages
|
||||
/// <summary>
|
||||
/// Richiede calcolo del prod
|
||||
/// </summary>
|
||||
/// <param name="odlRec"></param>
|
||||
/// <param name="itemAvaiDict"></param>
|
||||
/// <returns></returns>
|
||||
private async Task DoCalculateProd(Dictionary<string, List<ItemRawDTO>> itemAvaiDict)
|
||||
{
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
<Nullable>enable</Nullable>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<UserSecretsId>aspnet-Lux.UI-a758c101-a2f4-4e38-977d-1c4887dbbd50</UserSecretsId>
|
||||
<Version>1.1.2607.0308</Version>
|
||||
<Version>1.1.2607.0310</Version>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<body>
|
||||
<i>LUX - Web Windows MES</i>
|
||||
<h4>Versione: 1.1.2607.0308</h4>
|
||||
<h4>Versione: 1.1.2607.0310</h4>
|
||||
<br /> Note di rilascio:
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
@@ -1 +1 @@
|
||||
1.1.2607.0308
|
||||
1.1.2607.0310
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<item>
|
||||
<version>1.1.2607.0308</version>
|
||||
<version>1.1.2607.0310</version>
|
||||
<url>http://nexus.steamware.net/repository/SWS/GPW/stable/GPW.UI.zip</url>
|
||||
<changelog>http://nexus.steamware.net/repository/SWS/GPW/stable/ChangeLog.html</changelog>
|
||||
<mandatory>false</mandatory>
|
||||
|
||||
Reference in New Issue
Block a user