From 6751d4f8430be411a51710ec66a51a71fc044e01 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 12 Apr 2024 10:28:02 +0200 Subject: [PATCH 1/3] Fix taskresult: - da keyless a NotMapped x evitare oggetti sul db --- MP.Data/DatabaseModels/TaskResultModel.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MP.Data/DatabaseModels/TaskResultModel.cs b/MP.Data/DatabaseModels/TaskResultModel.cs index 881fe60d..28a4941d 100644 --- a/MP.Data/DatabaseModels/TaskResultModel.cs +++ b/MP.Data/DatabaseModels/TaskResultModel.cs @@ -11,7 +11,7 @@ using static MP.Data.Objects.Enums; // namespace MP.Data.DatabaseModels { - [Keyless] + [NotMapped] public partial class TaskResultModel { #region Public Properties From f5640359317c13b5a5b1b89132916874997dda4b Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 12 Apr 2024 10:55:03 +0200 Subject: [PATCH 2/3] TAB3: - update refresh articolo --- MP-TAB3/Components/MachSel.razor.cs | 6 ++++- MP-TAB3/Components/OdlMan.razor.cs | 39 ++++++++++++++++------------- MP-TAB3/MP-TAB3.csproj | 2 +- MP-TAB3/Resources/ChangeLog.html | 2 +- MP-TAB3/Resources/VersNum.txt | 2 +- MP-TAB3/Resources/manifest.xml | 2 +- 6 files changed, 31 insertions(+), 22 deletions(-) diff --git a/MP-TAB3/Components/MachSel.razor.cs b/MP-TAB3/Components/MachSel.razor.cs index 55576af5..77659a86 100644 --- a/MP-TAB3/Components/MachSel.razor.cs +++ b/MP-TAB3/Components/MachSel.razor.cs @@ -65,7 +65,11 @@ namespace MP_TAB3.Components protected override async Task OnParametersSetAsync() { // inizilamente riporto machcina corrente da MSE - if (RecMSE != null) + if (RecMSE == null) + { + IdxMaccSel = ""; + } + else { if (string.IsNullOrEmpty(idxMaccSel)) { diff --git a/MP-TAB3/Components/OdlMan.razor.cs b/MP-TAB3/Components/OdlMan.razor.cs index ff77bd88..d1409920 100644 --- a/MP-TAB3/Components/OdlMan.razor.cs +++ b/MP-TAB3/Components/OdlMan.razor.cs @@ -305,7 +305,8 @@ namespace MP_TAB3.Components } catch { } - + RecMSE = null; + await InvokeAsync(StateHasChanged); // refresh finale checkAll(); await RefreshData(); @@ -695,6 +696,7 @@ namespace MP_TAB3.Components await TabDServ.FlushOdlCache(); IdxPOdlSel = 0; RecMSE = null; + await InvokeAsync(StateHasChanged); await RefreshData(); await CheckAttr(); inAttr = true; @@ -860,6 +862,7 @@ namespace MP_TAB3.Components // faccio refresh e riporto IdxPOdlSel = 0; RecMSE = null; + await InvokeAsync(StateHasChanged); currOdl = new ODLExpModel(); inAttr = false; IdxPOdlSel = 0; @@ -870,7 +873,6 @@ namespace MP_TAB3.Components await advStep(currStep++); isProcessing = false; await InvokeAsync(StateHasChanged); - //NavMan.NavigateTo(NavMan.Uri, true); } protected async Task refreshAfterFixOdl(bool has2Refr) @@ -1287,25 +1289,28 @@ namespace MP_TAB3.Components // verifico se NON HA ODL... if (emptyOdlMacc) { - // verifico SE siamo nel gracePeriod... chiuso da meno di 1h - DateTime adesso = DateTime.Now; - DateTime dtChiusura = DateTime.Now.AddHours(-1); - try + if (!emptyOdlAltraMacc) { - var lastOdl = TabDServ.OdlLastByMacc(IdxMaccSel, true); - if (lastOdl != null) + // verifico SE siamo nel gracePeriod... chiuso da meno di 1h + DateTime adesso = DateTime.Now; + DateTime dtChiusura = DateTime.Now.AddHours(-1); + try { - dtChiusura = lastOdl.DataFine ?? DateTime.Now.AddHours(-1); + var lastOdl = TabDServ.OdlLastByMacc(IdxMaccSel, true); + if (lastOdl != null) + { + dtChiusura = lastOdl.DataFine ?? DateTime.Now.AddHours(-1); + } } - } - catch - { } + catch + { } - // ora verifico SE E SOLO SE è ANCORA in attrezzaggio ora verifico SE ALTRA - // TAVOLA ha ODL... - if (dtChiusura.AddMinutes(gPeriodReopenOdlTav) > adesso) - { - answ = showReopenOdlTav; + // ora verifico SE E SOLO SE è ANCORA in attrezzaggio ora verifico SE ALTRA + // TAVOLA ha ODL... + if (dtChiusura.AddMinutes(gPeriodReopenOdlTav) > adesso) + { + answ = showReopenOdlTav; + } } } } diff --git a/MP-TAB3/MP-TAB3.csproj b/MP-TAB3/MP-TAB3.csproj index dbb1a7ac..a6e7a1e2 100644 --- a/MP-TAB3/MP-TAB3.csproj +++ b/MP-TAB3/MP-TAB3.csproj @@ -3,7 +3,7 @@ net6.0 enable - 6.16.2404.1117 + 6.16.2404.1210 enable MP_TAB3 diff --git a/MP-TAB3/Resources/ChangeLog.html b/MP-TAB3/Resources/ChangeLog.html index de71c3dc..565e3325 100644 --- a/MP-TAB3/Resources/ChangeLog.html +++ b/MP-TAB3/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

Versione: 6.16.2404.1117

+

Versione: 6.16.2404.1210


Note di rilascio: