From 16278b6ae02175cf231e13419b8ead19b3cf1f9f Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Tue, 11 Oct 2022 13:03:56 +0200 Subject: [PATCH] pescaggio e clonazione flusso scelto --- MP.Data/DTO/DossierFluxLogDTO.cs | 2 + MP.SPEC/Components/ListDossiers.razor | 12 +++- MP.SPEC/Components/ListDossiers.razor.cs | 18 ++++++ MP.SPEC/MP.SPEC.csproj | 2 +- MP.SPEC/Pages/DOSS.razor | 74 ++++++++++++++++++++---- MP.SPEC/Pages/DOSS.razor.cs | 22 ++++++- MP.SPEC/Pages/PODL.razor | 2 +- MP.SPEC/Pages/_Layout.cshtml | 22 +++---- MP.SPEC/Resources/ChangeLog.html | 2 +- MP.SPEC/Resources/VersNum.txt | 2 +- MP.SPEC/Resources/manifest.xml | 2 +- 11 files changed, 129 insertions(+), 31 deletions(-) diff --git a/MP.Data/DTO/DossierFluxLogDTO.cs b/MP.Data/DTO/DossierFluxLogDTO.cs index 67cecb73..c7f389cd 100644 --- a/MP.Data/DTO/DossierFluxLogDTO.cs +++ b/MP.Data/DTO/DossierFluxLogDTO.cs @@ -14,5 +14,7 @@ namespace MP.Data.DTO public class DossierFluxLogDTO { public List ODL { get; set; } = new List(); + + public List OdlClone { get; set; } = new List(); } } diff --git a/MP.SPEC/Components/ListDossiers.razor b/MP.SPEC/Components/ListDossiers.razor index 3fe9e652..57d1918a 100644 --- a/MP.SPEC/Components/ListDossiers.razor +++ b/MP.SPEC/Components/ListDossiers.razor @@ -53,10 +53,11 @@ else @record.IdxODL @* - @record.DataType - *@ + @record.DataType + *@ - + + } @@ -74,6 +75,7 @@ else + @@ -84,6 +86,7 @@ else @foreach (var record in listaFlux) { + @@ -98,6 +101,7 @@ else } +
Macchina Data Data Type
@record.IdxMacchina
@@ -110,3 +114,5 @@ else + + diff --git a/MP.SPEC/Components/ListDossiers.razor.cs b/MP.SPEC/Components/ListDossiers.razor.cs index fdb5c4e4..d9cae22c 100644 --- a/MP.SPEC/Components/ListDossiers.razor.cs +++ b/MP.SPEC/Components/ListDossiers.razor.cs @@ -1,6 +1,7 @@ using Microsoft.AspNetCore.Components; using Microsoft.JSInterop; using MP.Data.DatabaseModels; +using MP.Data.DTO; using MP.SPEC.Data; namespace MP.SPEC.Components @@ -11,6 +12,8 @@ namespace MP.SPEC.Components [Parameter] public EventCallback RecordSel { get; set; } + [Parameter] + public EventCallback RecordSelFlux { get; set; } [Parameter] public SelectDossierParams SelFilter { get; set; } = null!; @@ -69,6 +72,19 @@ namespace MP.SPEC.Components await reloadData(true); await Task.Delay(1); } + protected async Task cloneRecord(FluxLog selRec) + { + // creo record duplicato... + FluxLog newRec = new FluxLog() + { + IdxMacchina = selRec.IdxMacchina, + dtEvento = selRec.dtEvento, + CodFlux = $"DUPLICATED - {selRec.CodFlux}", + Valore = selRec.Valore + }; + currRecordFlux = selRec; + await RecordSelFlux.InvokeAsync(newRec); + } protected override async Task OnInitializedAsync() { @@ -117,6 +133,8 @@ namespace MP.SPEC.Components private List? ListRecords; + private FluxLog? currRecordFlux; + private List? ListStati; private List? SearchRecords; diff --git a/MP.SPEC/MP.SPEC.csproj b/MP.SPEC/MP.SPEC.csproj index 1b081b1f..4849ba4e 100644 --- a/MP.SPEC/MP.SPEC.csproj +++ b/MP.SPEC/MP.SPEC.csproj @@ -5,7 +5,7 @@ enable enable MP.SPEC - 6.16.2210.1017 + 6.16.2210.1112 diff --git a/MP.SPEC/Pages/DOSS.razor b/MP.SPEC/Pages/DOSS.razor index 9c17c17b..5e83e819 100644 --- a/MP.SPEC/Pages/DOSS.razor +++ b/MP.SPEC/Pages/DOSS.razor @@ -14,25 +14,79 @@ } else { - + }
- @if (isLoading) + @if (currRecord != null) { - - } - else - { - +
+
+
+
Modifica Parametro
+
+
+
+
+ MACCHINA + +
+
+
+
+ DATA + +
+
+
+
+ DATA TYPE + +
+
+
+
+ VALORE + +
+
+
+
+
+
+
+
+
+
+ +
+
+
+
+ +
+
+
+
+
+
+
}
- + @if (isLoading) + { + + } + else + { + + } + + diff --git a/MP.SPEC/Pages/DOSS.razor.cs b/MP.SPEC/Pages/DOSS.razor.cs index 65c77aa6..2960b0b1 100644 --- a/MP.SPEC/Pages/DOSS.razor.cs +++ b/MP.SPEC/Pages/DOSS.razor.cs @@ -1,4 +1,5 @@ using Microsoft.AspNetCore.Components; +using MP.Data.DatabaseModels; using MP.SPEC.Components; using MP.SPEC.Data; @@ -31,7 +32,20 @@ namespace MP.SPEC.Pages currPage = newNum; StateHasChanged(); } - + private FluxLog? _currRecord = null; + private FluxLog? currRecord + { + get => _currRecord; + set + { + _currRecord = value; + } + } + protected async Task cancel() + { + currRecord = null; + await Task.Delay(1); + } protected override async Task OnInitializedAsync() { isLoading = true; @@ -47,7 +61,11 @@ namespace MP.SPEC.Pages await Task.Delay(1); isFiltering = false; } - + protected async Task selRecordFlux(FluxLog selRec) + { + currRecord = selRec; + await Task.Delay(1); + } protected void updateTotal(int newTotCount) { totalCount = newTotCount; diff --git a/MP.SPEC/Pages/PODL.razor b/MP.SPEC/Pages/PODL.razor index a890faa2..884921cd 100644 --- a/MP.SPEC/Pages/PODL.razor +++ b/MP.SPEC/Pages/PODL.razor @@ -148,7 +148,7 @@
Attivabile
-
+
diff --git a/MP.SPEC/Pages/_Layout.cshtml b/MP.SPEC/Pages/_Layout.cshtml index 4b0f428f..e1d1070d 100644 --- a/MP.SPEC/Pages/_Layout.cshtml +++ b/MP.SPEC/Pages/_Layout.cshtml @@ -44,19 +44,19 @@ retryIntervalMilliseconds: 2000 } }).then(() => { - Object.defineProperty(Blazor.defaultReconnectionHandler, '_reconnectionDisplay', { - get() { - return this.__reconnectionDisplay; - }, - set(value) { - this.__reconnectionDisplay = { - show: () => value.show(), - update: (d) => value.update(d), - rejected: (d) => document.location.reload() - } + Object.defineProperty(Blazor.defaultReconnectionHandler, '_reconnectionDisplay', { + get() { + return this.__reconnectionDisplay; + }, + set(value) { + this.__reconnectionDisplay = { + show: () => value.show(), + update: (d) => value.update(d), + rejected: (d) => document.location.reload() } - }); + } }); + }); diff --git a/MP.SPEC/Resources/ChangeLog.html b/MP.SPEC/Resources/ChangeLog.html index 8e7e3686..98e38e02 100644 --- a/MP.SPEC/Resources/ChangeLog.html +++ b/MP.SPEC/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

Versione: 6.16.2210.1017

+

Versione: 6.16.2210.1112


Note di rilascio:
  • diff --git a/MP.SPEC/Resources/VersNum.txt b/MP.SPEC/Resources/VersNum.txt index 83cba27c..c649beb4 100644 --- a/MP.SPEC/Resources/VersNum.txt +++ b/MP.SPEC/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2210.1017 +6.16.2210.1112 diff --git a/MP.SPEC/Resources/manifest.xml b/MP.SPEC/Resources/manifest.xml index a5e4fb84..ae05905c 100644 --- a/MP.SPEC/Resources/manifest.xml +++ b/MP.SPEC/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2210.1017 + 6.16.2210.1112 https://nexus.steamware.net/repository/SWS/MP-SPEC/stable/LAST/MP.SPEC.zip https://nexus.steamware.net/repository/SWS/MP-SPEC/stable/LAST/ChangeLog.html false