From d5b425324bdff63d68df5d7312d4420e6adbb638 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Tue, 28 Nov 2023 15:38:54 +0100 Subject: [PATCH] aggiunto alert per notifica tentativo errato scarti --- MP-TAB-SERV/Components/ScrapEditor.razor | 6 ++++++ MP-TAB-SERV/Components/ScrapEditor.razor.cs | 23 +++++++++++++++------ MP-TAB-SERV/MP-TAB-SERV.csproj | 2 +- MP-TAB-SERV/Resources/ChangeLog.html | 2 +- MP-TAB-SERV/Resources/VersNum.txt | 2 +- MP-TAB-SERV/Resources/manifest.xml | 2 +- MP.Data/Controllers/MpTabController.cs | 2 +- 7 files changed, 28 insertions(+), 11 deletions(-) diff --git a/MP-TAB-SERV/Components/ScrapEditor.razor b/MP-TAB-SERV/Components/ScrapEditor.razor index 14b63d93..c3cbe104 100644 --- a/MP-TAB-SERV/Components/ScrapEditor.razor +++ b/MP-TAB-SERV/Components/ScrapEditor.razor @@ -10,6 +10,12 @@ + @if(errMsg != "") + { +
+ @errMsg +
+ } @if (ShowDetail) {
diff --git a/MP-TAB-SERV/Components/ScrapEditor.razor.cs b/MP-TAB-SERV/Components/ScrapEditor.razor.cs index 14d2d7e7..037e187b 100644 --- a/MP-TAB-SERV/Components/ScrapEditor.razor.cs +++ b/MP-TAB-SERV/Components/ScrapEditor.razor.cs @@ -81,14 +81,25 @@ namespace MP_TAB_SERV.Components Note = UserComment }; // inserisco - await TabServ.RegScartiInsert(newRec); - - // reset - DoReset(); - //ToggleCtrl(); - await E_Updated.InvokeAsync(true); + var done = await TabServ.RegScartiInsert(newRec); + if (done) + { + // reset + DoReset(); + errMsg = ""; + //ToggleCtrl(); + await E_Updated.InvokeAsync(true); + StateHasChanged(); + } + else + { + errMsg = "ODL non attivo o data/ora errato"; + } + ShowDetail = false; } + protected string errMsg { get; set; } = ""; + protected override async Task OnInitializedAsync() { await ReloadData(); diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index ed61e0ca..4bf929a3 100644 --- a/MP-TAB-SERV/MP-TAB-SERV.csproj +++ b/MP-TAB-SERV/MP-TAB-SERV.csproj @@ -3,7 +3,7 @@ net6.0 enable - 6.16.2311.2814 + 6.16.2311.2815 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index e747a31a..cc208fb6 100644 --- a/MP-TAB-SERV/Resources/ChangeLog.html +++ b/MP-TAB-SERV/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

Versione: 6.16.2311.2814

+

Versione: 6.16.2311.2815


Note di rilascio: