From 340fc785f58e67ed6f904a4383571f2ba6469a63 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Tue, 27 Feb 2024 19:13:26 +0100 Subject: [PATCH 01/20] Fix veto reload note/tempo7pzPallet in attrezzaggio --- MP-TAB3/Components/OdlMan.razor | 4 +-- MP-TAB3/Components/OdlMan.razor.cs | 40 ++++++++++++++++++------------ 2 files changed, 26 insertions(+), 18 deletions(-) diff --git a/MP-TAB3/Components/OdlMan.razor b/MP-TAB3/Components/OdlMan.razor index b5d405de..6e1f0f70 100644 --- a/MP-TAB3/Components/OdlMan.razor +++ b/MP-TAB3/Components/OdlMan.razor @@ -82,9 +82,9 @@ } -
+ @*
Check articolo in revisione -
+
*@ @if (cancelSetupEnabled && RecMSE != null && RecMSE.PezziConf == 0) {
diff --git a/MP-TAB3/Components/OdlMan.razor.cs b/MP-TAB3/Components/OdlMan.razor.cs index 8090d76a..fcb4cf15 100644 --- a/MP-TAB3/Components/OdlMan.razor.cs +++ b/MP-TAB3/Components/OdlMan.razor.cs @@ -1543,21 +1543,25 @@ namespace MP_TAB3.Components } } await updateIdxOdl(); - // imposto tcRichAttr in base allo stato... - if (odlOk) + // aggiorno questi dati SOLO SE non sono in attrezzaggio + if (!inAttr) { - // prendo TCRich da PODL... - if (IdxPOdlSel > 0) + // imposto tcRichAttr in base allo stato... + if (odlOk) { - tcRichAttr = currPodl.Tcassegnato; - noteAttr = currPodl.Note; - PzPallet = currPodl.PzPallet; - } - else - { - tcRichAttr = currOdl.TCRichAttr; - noteAttr = currOdl.Note; - PzPallet = currOdl.PzPallet; + // prendo TCRich da PODL... + if (IdxPOdlSel > 0) + { + tcRichAttr = currPodl.Tcassegnato; + noteAttr = currPodl.Note; + PzPallet = currPodl.PzPallet; + } + else + { + tcRichAttr = currOdl.TCRichAttr; + noteAttr = currOdl.Note; + PzPallet = currOdl.PzPallet; + } } } } @@ -1570,13 +1574,17 @@ namespace MP_TAB3.Components if (IdxPOdlSel > 0) { await ReloadXDL(false); + // solo se NON sno in attrezzaggio // controllo se sia cambiato PODL if (IdxPOdlSel != lastIdxPOdl) { lastIdxPOdl = IdxPOdlSel; - tcRichAttr = currPodl.Tcassegnato; - noteAttr = currPodl.Note; - PzPallet = currPodl.PzPallet; + if (!inAttr) + { + tcRichAttr = currPodl.Tcassegnato; + noteAttr = currPodl.Note; + PzPallet = currPodl.PzPallet; + } } } } From 58b9ffcea82b756a5ae9ee1fa9c22ad8a53e3581 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Tue, 27 Feb 2024 19:13:39 +0100 Subject: [PATCH 02/20] fix reload home btn top --- MP-TAB3/Components/CmpTop.razor.cs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/MP-TAB3/Components/CmpTop.razor.cs b/MP-TAB3/Components/CmpTop.razor.cs index f5f6ae6a..fd000fd7 100644 --- a/MP-TAB3/Components/CmpTop.razor.cs +++ b/MP-TAB3/Components/CmpTop.razor.cs @@ -132,9 +132,8 @@ namespace MP_TAB3.Components await Task.Delay(1); if (!NavMan.Uri.Contains("reg-new-device")) { - await MsgServ.IdxMaccSet(""); - NavMan.NavigateTo("status-map"); + NavMan.NavigateTo("status-map", true); } } From d0b624f74bb0ff286b3d47f7c06304c726ec0cb8 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Tue, 27 Feb 2024 19:13:50 +0100 Subject: [PATCH 03/20] add log x gestione IobInfo --- MP.Data/Services/TabDataService.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/MP.Data/Services/TabDataService.cs b/MP.Data/Services/TabDataService.cs index 407dd880..a81f1952 100644 --- a/MP.Data/Services/TabDataService.cs +++ b/MP.Data/Services/TabDataService.cs @@ -900,6 +900,8 @@ namespace MP.Data.Services else { Log.Error($"Errore: non trovato valore valido in REDIS | key: {currKey}"); + Log.Info($"REDIS | conf: {redisConn.Configuration}"); + Log.Info($" --> Valore trovato:{Environment.NewLine}{rawData}"); } if (result == null) { From e8052ed5a2bafee1340cbc737ee6375606ccbf24 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Tue, 27 Feb 2024 19:14:19 +0100 Subject: [PATCH 04/20] Cambio comportamento insert fermate x mostrare esito insert --- MP-TAB3/Pages/ProdStop.razor | 11 ++++- MP-TAB3/Pages/ProdStop.razor.cs | 73 +++++++++++++++------------------ 2 files changed, 42 insertions(+), 42 deletions(-) diff --git a/MP-TAB3/Pages/ProdStop.razor b/MP-TAB3/Pages/ProdStop.razor index e7f1d040..38a97c95 100644 --- a/MP-TAB3/Pages/ProdStop.razor +++ b/MP-TAB3/Pages/ProdStop.razor @@ -16,13 +16,20 @@ else
@if (!string.IsNullOrEmpty(lblOut)) { -
- @lblOut +
+ @titleOut +
+ @lblOut +
+
} + else + { @foreach (var item in events2show) { } + }
} diff --git a/MP-TAB3/Pages/ProdStop.razor.cs b/MP-TAB3/Pages/ProdStop.razor.cs index bf96c3ab..570e791c 100644 --- a/MP-TAB3/Pages/ProdStop.razor.cs +++ b/MP-TAB3/Pages/ProdStop.razor.cs @@ -1,4 +1,5 @@ using global::Microsoft.AspNetCore.Components; +using Microsoft.AspNetCore.Components.Routing; using MP.Data; using MP.Data.DatabaseModels; using MP.Data.Services; @@ -9,16 +10,13 @@ namespace MP_TAB3.Pages { public partial class ProdStop { - #region Public Methods - - #endregion Public Methods - #region Protected Fields protected int dltMinRealtime = 1; protected bool isProcessing = false; + protected string lblOut = ""; protected int minAnticipoRicalcolo = 1; protected bool rdm_ChkOnly = false; @@ -33,12 +31,10 @@ namespace MP_TAB3.Pages protected string alertCss { get; set; } = "alert-danger"; - protected DateTime DtRif { get; set; } = DateTime.Now; protected List events2show { get; set; } = new List(); - /// /// Determina se insert sia Realtime o batch con DataOra (in base a diff tra DataOra /// selezionata e realtime, se superiore ad X minuti NON � realtime) @@ -56,8 +52,6 @@ namespace MP_TAB3.Pages } } - protected string lblOut { get; set; } = ""; - [Inject] protected StatusData MDataService { get; set; } = null!; @@ -186,12 +180,13 @@ namespace MP_TAB3.Pages TabDServ.MacchinaSetInsEnab(IdxMacc, true); } // mostro esito - alertCss = "alert-succes"; - lblOut = $"Registrata dichiarazione fermata [{rigaEvento.Nome}] alle {DateTime.Now:HH:mm:ss}"; + alertCss = "alert-primary"; + titleOut = rigaEvento.Nome; + lblOut = $"Registrata dichiarazione fermata alle {DateTime.Now:HH:mm:ss}"; } else { - alertCss = "alert-danger"; + alertCss = "alert-warning"; lblOut = $"Codice evento non valido! {IdxEv}"; } } @@ -215,6 +210,11 @@ namespace MP_TAB3.Pages } } + protected void ForceReloadPage() + { + NavMan.NavigateTo(NavMan.Uri, true); + } + protected override async Task OnInitializedAsync() { await base.OnInitializedAsync(); @@ -227,34 +227,6 @@ namespace MP_TAB3.Pages await ReloadData(); } - - - protected void SetDate(DateTime newDate) - { - DtRif = newDate; - } - - #endregion Protected Methods - - #region Private Fields - - private static Logger Log = LogManager.GetCurrentClassLogger(); - - #endregion Private Fields - - #region Private Properties - - private int MatrOpr - { - get => MsgServ.MatrOpr; - } - - #endregion Private Properties - - #region Private Methods - - - protected override async Task ReloadData() { if (string.IsNullOrEmpty(IdxMacc)) @@ -277,6 +249,27 @@ namespace MP_TAB3.Pages } } - #endregion Private Methods + protected void SetDate(DateTime newDate) + { + DtRif = newDate; + } + + #endregion Protected Methods + + #region Private Fields + + private static Logger Log = LogManager.GetCurrentClassLogger(); + private string titleOut = ""; + + #endregion Private Fields + + #region Private Properties + + private int MatrOpr + { + get => MsgServ.MatrOpr; + } + + #endregion Private Properties } } \ No newline at end of file From 2afc9acf2ce0f4e3252379be91251c5fab8ba2c6 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Tue, 27 Feb 2024 19:14:31 +0100 Subject: [PATCH 05/20] test insert tempo x sel datetime mobile --- MP-TAB3/Components/MachineBlock.razor | 24 ++++++++++++------------ MP-TAB3/Components/SelTempoMSMC.razor | 2 +- MP-TAB3/MP-TAB3.csproj | 2 +- MP-TAB3/Pages/BasePage.razor.cs | 7 ++++++- MP-TAB3/Resources/ChangeLog.html | 2 +- MP-TAB3/Resources/VersNum.txt | 2 +- MP-TAB3/Resources/manifest.xml | 2 +- 7 files changed, 23 insertions(+), 18 deletions(-) diff --git a/MP-TAB3/Components/MachineBlock.razor b/MP-TAB3/Components/MachineBlock.razor index 826fb913..d94728f9 100644 --- a/MP-TAB3/Components/MachineBlock.razor +++ b/MP-TAB3/Components/MachineBlock.razor @@ -4,15 +4,15 @@
- - - - + + + + - + - +
@@ -27,15 +27,15 @@ else
No data
- - - - + + + + - + - +
diff --git a/MP-TAB3/Components/SelTempoMSMC.razor b/MP-TAB3/Components/SelTempoMSMC.razor index 76a84cea..acb1ab40 100644 --- a/MP-TAB3/Components/SelTempoMSMC.razor +++ b/MP-TAB3/Components/SelTempoMSMC.razor @@ -18,7 +18,7 @@ {
@labelTempoIN - +
} diff --git a/MP-TAB3/MP-TAB3.csproj b/MP-TAB3/MP-TAB3.csproj index 29b8c461..c53ea674 100644 --- a/MP-TAB3/MP-TAB3.csproj +++ b/MP-TAB3/MP-TAB3.csproj @@ -3,7 +3,7 @@ net6.0 enable - 6.16.2402.2716 + 6.16.2402.2719 enable MP_TAB3 diff --git a/MP-TAB3/Pages/BasePage.razor.cs b/MP-TAB3/Pages/BasePage.razor.cs index 2657a516..a00cde6f 100644 --- a/MP-TAB3/Pages/BasePage.razor.cs +++ b/MP-TAB3/Pages/BasePage.razor.cs @@ -56,11 +56,16 @@ namespace MP_TAB3.Pages protected override async Task OnInitializedAsync() { await base.OnInitializedAsync(); - await ReloadData(); TDFeeder.dataPipe.EA_NewMessage += DataPipe_EA_NewMessage; TDFeeder.blinkPipe.EA_NewMessage += BlinkPipe_EA_NewMessage; } + protected override async Task OnParametersSetAsync() + { + await ReloadData(); + //return base.OnParametersSetAsync(); + } + /// /// Metodo refresh con controllo salvataggio in LocalStorage ogni 5 sec /// diff --git a/MP-TAB3/Resources/ChangeLog.html b/MP-TAB3/Resources/ChangeLog.html index e0d153f6..1a23d7dc 100644 --- a/MP-TAB3/Resources/ChangeLog.html +++ b/MP-TAB3/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

Versione: 6.16.2402.2716

+

Versione: 6.16.2402.2719


Note di rilascio: