diff --git a/MP-TAB-SERV/Components/CmpFooter.razor b/MP-TAB-SERV/Components/CmpFooter.razor index bb526379..f9c7b5a6 100644 --- a/MP-TAB-SERV/Components/CmpFooter.razor +++ b/MP-TAB-SERV/Components/CmpFooter.razor @@ -1,6 +1,6 @@ 
-
- MP-TAB2 @(DateTime.Today.Year) | v.@version +
+ MP-TAB2 @(DateTime.Today.Year) v.@version
@if (typeScadLogin > 0) diff --git a/MP-TAB-SERV/Components/OdlMan.razor b/MP-TAB-SERV/Components/OdlMan.razor index b3ce4602..37d69700 100644 --- a/MP-TAB-SERV/Components/OdlMan.razor +++ b/MP-TAB-SERV/Components/OdlMan.razor @@ -225,17 +225,18 @@
- + + -
+
-
diff --git a/MP-TAB-SERV/Components/OdlMan.razor.cs b/MP-TAB-SERV/Components/OdlMan.razor.cs index 4cfa3ace..b39e23e5 100644 --- a/MP-TAB-SERV/Components/OdlMan.razor.cs +++ b/MP-TAB-SERV/Components/OdlMan.razor.cs @@ -86,6 +86,7 @@ namespace MP_TAB_SERV.Components protected IJSRuntime JSRuntime { get; set; } = null!; protected List ListODL { get; set; } = new List(); + protected List ListODLAll { get; set; } = new List(); [Inject] protected MailService MailServ { get; set; } = null!; @@ -107,6 +108,23 @@ namespace MP_TAB_SERV.Components get => IdxOdl > 0; } + protected string SearchPodl + { + get => searchPodl; + set + { + if (searchPodl != value) + { + searchPodl = value; + var pUpd = Task.Run(async () => + { + await ReloadData(true); + }); + pUpd.Wait(); + } + } + } + protected bool ShowAll { get => showAll; @@ -130,6 +148,25 @@ namespace MP_TAB_SERV.Components [Inject] protected TabDataService TabDServ { get; set; } = null!; + /// + /// Verifica se la tavola SIA in fase di attrezzaggio, ovvero SE: + /// - sia un impianto MULTI (= con + tavole) + /// - sia già attrezzata + /// + protected bool tavHasOdl + { + get + { + bool answ = false; + // se è multi controllo + if (isMulti) + { + answ = !emptyOdlMacc; + } + return answ; + } + } + #endregion Protected Properties #region Protected Methods @@ -165,24 +202,6 @@ namespace MP_TAB_SERV.Components await ReloadXDL(false); } } - /// - /// Verifica se la tavola SIA in fase di attrezzaggio, ovvero SE: - /// - sia un impianto MULTI (= con + tavole) - /// - sia già attrezzata - /// - protected bool tavHasOdl - { - get - { - bool answ = false; - // se è multi controllo - if (isMulti) - { - answ = !emptyOdlMacc; - } - return answ; - } - } /// /// Aggiorno... @@ -439,7 +458,6 @@ namespace MP_TAB_SERV.Components } await advStep(currStep++); - // riporto stringa lblOut = sb.ToString().Replace("---", "
"); // update buttons... @@ -656,7 +674,6 @@ namespace MP_TAB_SERV.Components lblOut = "Selezionare un ORDINE valido!"; } - // refresh finale var tmpTCR = tcRichAttr; checkBtnStatus(); @@ -716,19 +733,6 @@ namespace MP_TAB_SERV.Components checkAll(); } -#if false - protected override async Task OnParametersSetAsync() - { - // verifica stato inAttr - if (!string.IsNullOrEmpty(IdxMaccSel) && IdxMaccSelLast != IdxMaccSel) - { - await CheckAttr(); - await ReloadData(false); - IdxMaccSelLast = IdxMaccSel; - } - } -#endif - protected async Task ProdEnd() { if (!await JSRuntime.InvokeAsync("confirm", $"Confermi fine produzione?")) @@ -868,6 +872,11 @@ namespace MP_TAB_SERV.Components tcRichAttr = newTCRich; } + protected void SearchPodlReset() + { + SearchPodl = ""; + } + protected async Task SendFixEndSetup() { if (!await JSRuntime.InvokeAsync("confirm", $"Confermi invio FIX chiusura attrezzaggio ad impianto?")) @@ -986,7 +995,7 @@ namespace MP_TAB_SERV.Components private string IdxMaccSel = ""; #if false - private string IdxMaccSelLast = ""; + private string IdxMaccSelLast = ""; #endif private int idxPOdlSel = 0; @@ -1019,6 +1028,7 @@ namespace MP_TAB_SERV.Components private int PzPallet = 1; + private string searchPodl = ""; private bool showAll = false; private bool showChkCloseOdlVal = false; @@ -1044,7 +1054,7 @@ namespace MP_TAB_SERV.Components private string cssDetailOdl { - get => IdxPOdlSel > 0 ? "bg-primary text-light" : "bg-warning"; + get => IdxPOdlSel > 0 ? "bg-info text-light" : "bg-warning"; } private ODLExpModel currOdl { get; set; } = new ODLExpModel(); @@ -1193,7 +1203,7 @@ namespace MP_TAB_SERV.Components // ora verifico SE E SOLO SE è ANCORA in attrezzaggio #if false if (inAttr) - { + { #endif // ora verifico SE ALTRA TAVOLA ha ODL... if (dtChiusura.AddMinutes(gPeriodReopenOdlTav) > adesso) @@ -1201,7 +1211,7 @@ namespace MP_TAB_SERV.Components answ = showReopenOdlTav; } #if false - } + } #endif } } @@ -1233,11 +1243,11 @@ namespace MP_TAB_SERV.Components #if false // ora verifico SE E SOLO SE è ANCORA in attrezzaggio if (inAttr) - { + { #endif answ = showSplitOdlOnTav; #if false - } + } #endif } } @@ -1627,7 +1637,15 @@ namespace MP_TAB_SERV.Components } if (!string.IsNullOrEmpty(IdxMaccSel)) { - ListODL = await TabDServ.VSOdlGetUnused(IdxMaccParent, ShowAll, numDayOdl); + ListODLAll = await TabDServ.VSOdlGetUnused(IdxMaccParent, ShowAll, numDayOdl); + if (string.IsNullOrEmpty(SearchPodl)) + { + ListODL = ListODLAll; + } + else + { + ListODL = ListODLAll.Where(x => x.label.Contains(SearchPodl, StringComparison.InvariantCultureIgnoreCase) || x.value == 0).ToList(); + } Log.Trace($"found {ListODL.Count} rec"); if (forceReload) { diff --git a/MP-TAB-SERV/Components/ProdConfirm.razor b/MP-TAB-SERV/Components/ProdConfirm.razor index ee24ec5a..f342fc33 100644 --- a/MP-TAB-SERV/Components/ProdConfirm.razor +++ b/MP-TAB-SERV/Components/ProdConfirm.razor @@ -98,8 +98,8 @@ Dati Globali ODL
-
-
+
+
[A] NUOVI Pz.Prod
@@ -109,14 +109,14 @@ } else { - @numPzProdotti2Rec + @numPzProdotti2Rec }
-
-
+
+
Pz Prodotti TOT [A+B+C]
@@ -126,14 +126,14 @@ } else { - @numPzProdotti + @numPzProdotti }
-
-
+
+
[B] Scarti VERS.
@@ -143,14 +143,14 @@ } else { - @numPzScaConf + @numPzScaConf }
-
-
+
+
[C] Pz Buoni VERS.
@@ -160,7 +160,7 @@ } else { - @numPzBuoniConf + @numPzBuoniConf }
diff --git a/MP-TAB-SERV/Components/SlideMenu.razor b/MP-TAB-SERV/Components/SlideMenu.razor index 356d9208..2cadef9a 100644 --- a/MP-TAB-SERV/Components/SlideMenu.razor +++ b/MP-TAB-SERV/Components/SlideMenu.razor @@ -37,12 +37,13 @@
-
- +
+
-
+
MAPO MES +
v.@version
TAB Controller - MES Suite diff --git a/MP-TAB-SERV/Components/SlideMenu.razor.cs b/MP-TAB-SERV/Components/SlideMenu.razor.cs index 0e102d29..860e420b 100644 --- a/MP-TAB-SERV/Components/SlideMenu.razor.cs +++ b/MP-TAB-SERV/Components/SlideMenu.razor.cs @@ -15,11 +15,12 @@ namespace MP_TAB_SERV.Components #region Protected Properties - [Inject] - protected NavigationManager navManager { get; set; } = null!; [Inject] protected MessageService MsgServ { get; set; } = null!; + [Inject] + protected NavigationManager navManager { get; set; } = null!; + #endregion Protected Properties #region Protected Methods @@ -29,6 +30,12 @@ namespace MP_TAB_SERV.Components return navManager.Uri.Contains(currUri) ? "bg-dark text-light" : ""; } + protected override void OnInitialized() + { + var rawVers = typeof(Program).Assembly.GetName().Version; + version = rawVers != null ? rawVers : new Version("0.0.0.0"); + } + protected async Task SetPage(string tgtUrl) { await Task.Delay(1); @@ -41,5 +48,11 @@ namespace MP_TAB_SERV.Components } #endregion Protected Methods + + #region Private Fields + + private Version version = null!; + + #endregion Private Fields } } \ No newline at end of file