From fd69a196d274c852762f8057f967087015800c91 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Fri, 21 Oct 2022 09:24:13 +0200 Subject: [PATCH 01/13] fix date snapshot --- MP.SPEC/Components/ListPARAMS.razor.cs | 29 ++++++++++++++++++++++++++ MP.SPEC/Components/ParamsFilter.razor | 2 +- MP.SPEC/MP.SPEC.csproj | 2 +- MP.SPEC/Resources/ChangeLog.html | 2 +- MP.SPEC/Resources/VersNum.txt | 2 +- MP.SPEC/Resources/manifest.xml | 2 +- 6 files changed, 34 insertions(+), 5 deletions(-) diff --git a/MP.SPEC/Components/ListPARAMS.razor.cs b/MP.SPEC/Components/ListPARAMS.razor.cs index 2ef8726a..31574c02 100644 --- a/MP.SPEC/Components/ListPARAMS.razor.cs +++ b/MP.SPEC/Components/ListPARAMS.razor.cs @@ -3,6 +3,7 @@ using Microsoft.JSInterop; using MP.Data.DatabaseModels; using MP.SPEC.Data; using System.Diagnostics; +using MP.Data; namespace MP.SPEC.Components { @@ -156,6 +157,7 @@ namespace MP.SPEC.Components protected async Task resetSel() { currRecord = null; + setDtMax(); await RecordSel.InvokeAsync(null); } @@ -163,6 +165,8 @@ namespace MP.SPEC.Components { currRecord = selRec; SelFilter.IdxMacchina = selRec.IdxMacchina; + SelDtMax = selRec.dtEvento; + //selDtMin = RoundDatetime(5).AddHours(-25); await reloadData(false); await RecordSel.InvokeAsync(selRec); } @@ -224,8 +228,33 @@ namespace MP.SPEC.Components private DateTime? SelDtMax { get => SelFilter.dtMax; + set => SelFilter.dtMax = value; + } + protected void setDtMax() + { + // copio il filtro + var currFilt = SelFilter; + // fermo update + currFilt.LiveUpdate = true; + currFilt.CurrPage = 0; + currFilt.lastUpdate = $"{DateTime.Now:yyyy/MM/dd HH:mm:ss}"; + currFilt.dtMax = RoundDatetime(5); + currFilt.dtMin = RoundDatetime(5).AddHours(-25); + SelFilter = currFilt; } + /// + /// Inizializzazione con periodo e arrotondamento + /// + /// + /// + public static DateTime RoundDatetime(int minRound) + { + TimeSpan DayElapsed = DateTime.Now.Subtract(DateTime.Today); + int minDay = (int)Math.Ceiling((double)(DayElapsed.TotalMinutes / minRound)) * minRound; + DateTime endRounded = DateTime.Today.AddMinutes(minDay); + return endRounded; + } private int totalCount { get => _totalCount; diff --git a/MP.SPEC/Components/ParamsFilter.razor b/MP.SPEC/Components/ParamsFilter.razor index 769761eb..ae01c039 100644 --- a/MP.SPEC/Components/ParamsFilter.razor +++ b/MP.SPEC/Components/ParamsFilter.razor @@ -38,7 +38,7 @@ - +
diff --git a/MP.SPEC/MP.SPEC.csproj b/MP.SPEC/MP.SPEC.csproj index 64c4f598..78cd04e0 100644 --- a/MP.SPEC/MP.SPEC.csproj +++ b/MP.SPEC/MP.SPEC.csproj @@ -5,7 +5,7 @@ enable enable MP.SPEC - 6.16.2210.2017 + 6.16.2210.2108 diff --git a/MP.SPEC/Resources/ChangeLog.html b/MP.SPEC/Resources/ChangeLog.html index 2728c632..d09628d3 100644 --- a/MP.SPEC/Resources/ChangeLog.html +++ b/MP.SPEC/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

Versione: 6.16.2210.2017

+

Versione: 6.16.2210.2108


Note di rilascio:
  • diff --git a/MP.SPEC/Resources/VersNum.txt b/MP.SPEC/Resources/VersNum.txt index 8564b4af..2c89aa63 100644 --- a/MP.SPEC/Resources/VersNum.txt +++ b/MP.SPEC/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2210.2017 +6.16.2210.2108 diff --git a/MP.SPEC/Resources/manifest.xml b/MP.SPEC/Resources/manifest.xml index 286026b9..d0f6c5a6 100644 --- a/MP.SPEC/Resources/manifest.xml +++ b/MP.SPEC/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2210.2017 + 6.16.2210.2108 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 From bb19bb02c42794d054c27aa1e6a1fce56891fe3d Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 21 Oct 2022 09:30:56 +0200 Subject: [PATCH 02/13] Fix rimozione message pipe MON da SPEC --- MP.Data/MessagePipe.cs | 2 +- MP.SPEC/Data/MpDataService.cs | 20 ++++++-------------- MP.SPEC/MP.SPEC.csproj | 2 +- MP.SPEC/NLog.config | 2 +- MP.SPEC/Resources/ChangeLog.html | 2 +- MP.SPEC/Resources/VersNum.txt | 2 +- MP.SPEC/Resources/manifest.xml | 2 +- MP.SPEC/appsettings.json | 4 ++-- 8 files changed, 14 insertions(+), 22 deletions(-) diff --git a/MP.Data/MessagePipe.cs b/MP.Data/MessagePipe.cs index 098cdc4e..a7503be2 100644 --- a/MP.Data/MessagePipe.cs +++ b/MP.Data/MessagePipe.cs @@ -90,7 +90,7 @@ namespace MP.Data //Subscribe to the channel named messages sub.Subscribe(_channel, (channel, message) => { - Log.Trace($"ch {channel} | {message}"); + Log.Trace($"req setup ch {channel} | {message}"); // messaggio PubSubEventArgs mea = new PubSubEventArgs(message); // se qualcuno ascolta sollevo evento nuovo valore... diff --git a/MP.SPEC/Data/MpDataService.cs b/MP.SPEC/Data/MpDataService.cs index 12805cc6..6297fedb 100644 --- a/MP.SPEC/Data/MpDataService.cs +++ b/MP.SPEC/Data/MpDataService.cs @@ -29,10 +29,6 @@ namespace MP.SPEC.Data _logger.LogInformation("Redis INIT"); - // setup canali pub/sub - dataPipe = new MessagePipe(redisConn, Constants.ACT_MSE_DATA_KEY); - blinkPipe = new MessagePipe(redisConn, Constants.ACT_BLINK_KEY); - // conf DB string connStr = _configuration.GetConnectionString("Mp.Data"); if (string.IsNullOrEmpty(connStr)) @@ -52,14 +48,11 @@ namespace MP.SPEC.Data public static MP.Data.Controllers.MpSpecController dbController { get; set; } = null!; - public MessagePipe blinkPipe { get; set; } = null!; - /// /// Dizionario dei tag configurati per IOB /// public Dictionary> currTagConf { get; set; } = new Dictionary>(); - public MessagePipe dataPipe { get; set; } = null!; #endregion Public Properties @@ -100,15 +93,14 @@ namespace MP.SPEC.Data { Stopwatch stopWatch = new Stopwatch(); stopWatch.Start(); + string source = "DB"; List? result = new List(); // cerco in redis... RedisValue rawData = await redisDb.StringGetAsync(redisTipoArt); if (!string.IsNullOrEmpty($"{rawData}")) { result = JsonConvert.DeserializeObject>($"{rawData}"); - stopWatch.Stop(); - TimeSpan ts = stopWatch.Elapsed; - Log.Debug($"AnagTipoArtLV Read from REDIS: {ts.TotalMilliseconds}ms"); + source = "REDIS"; } else { @@ -116,10 +108,10 @@ namespace MP.SPEC.Data // serializzo e salvo... rawData = JsonConvert.SerializeObject(result); await redisDb.StringSetAsync(redisTipoArt, rawData, getRandTOut(redisLongTimeCache)); - stopWatch.Stop(); - TimeSpan ts = stopWatch.Elapsed; - Log.Debug($"AnagTipoArtLV Read from DB: {ts.TotalMilliseconds}ms"); } + stopWatch.Stop(); + TimeSpan ts = stopWatch.Elapsed; + Log.Debug($"AnagTipoArtLV Read from {source}: {ts.TotalMilliseconds}ms"); if (result == null) { result = new List(); @@ -197,7 +189,7 @@ namespace MP.SPEC.Data result = await Task.FromResult(dbController.ArticoliGetSearch(numRecord, azienda, searchVal)); // serializzo e salvo... rawData = JsonConvert.SerializeObject(result); - redisDb.StringSet(currKey, rawData, getRandTOut(redisLongTimeCache/5)); + redisDb.StringSet(currKey, rawData, getRandTOut(redisLongTimeCache / 5)); } if (result == null) { diff --git a/MP.SPEC/MP.SPEC.csproj b/MP.SPEC/MP.SPEC.csproj index 64c4f598..27a3af44 100644 --- a/MP.SPEC/MP.SPEC.csproj +++ b/MP.SPEC/MP.SPEC.csproj @@ -5,7 +5,7 @@ enable enable MP.SPEC - 6.16.2210.2017 + 6.16.2210.2109 diff --git a/MP.SPEC/NLog.config b/MP.SPEC/NLog.config index 3e4185f4..b32ba10a 100644 --- a/MP.SPEC/NLog.config +++ b/MP.SPEC/NLog.config @@ -39,7 +39,7 @@ Write all events with minimal level of Debug (So Debug, Info, Warn, Error and Fatal, but not Trace) to "f" --> - + diff --git a/MP.SPEC/Resources/ChangeLog.html b/MP.SPEC/Resources/ChangeLog.html index 2728c632..889923ac 100644 --- a/MP.SPEC/Resources/ChangeLog.html +++ b/MP.SPEC/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

    Versione: 6.16.2210.2017

    +

    Versione: 6.16.2210.2109


    Note di rilascio:
    • diff --git a/MP.SPEC/Resources/VersNum.txt b/MP.SPEC/Resources/VersNum.txt index 8564b4af..51b08b69 100644 --- a/MP.SPEC/Resources/VersNum.txt +++ b/MP.SPEC/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2210.2017 +6.16.2210.2109 diff --git a/MP.SPEC/Resources/manifest.xml b/MP.SPEC/Resources/manifest.xml index 286026b9..81a51989 100644 --- a/MP.SPEC/Resources/manifest.xml +++ b/MP.SPEC/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2210.2017 + 6.16.2210.2109 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 diff --git a/MP.SPEC/appsettings.json b/MP.SPEC/appsettings.json index 098b7be2..b8e6b52e 100644 --- a/MP.SPEC/appsettings.json +++ b/MP.SPEC/appsettings.json @@ -14,8 +14,8 @@ }, "ServerConf": { "maxAge": "2000", - "cacheCheckArtUsato": 2, - "redisLongTimeCache": 15, + "cacheCheckArtUsato": "2", + "redisLongTimeCache": "15", "MpIoBaseUrl": "http://localhost:20967/" } } From 9f9f44f6044c44c824ce2470daaee85c5e2c8545 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 21 Oct 2022 10:20:08 +0200 Subject: [PATCH 03/13] Bozza display filtri attivi --- MP.SPEC/Components/DossiersFilter.razor | 4 ++-- MP.SPEC/Components/ListPARAMS.razor.cs | 3 +++ MP.SPEC/Components/ParamsFilter.razor | 24 +++++++++++++++++++++--- MP.SPEC/Components/ParamsFilter.razor.cs | 4 ++++ MP.SPEC/MP.SPEC.csproj | 2 +- MP.SPEC/Resources/ChangeLog.html | 2 +- MP.SPEC/Resources/VersNum.txt | 2 +- MP.SPEC/Resources/manifest.xml | 2 +- 8 files changed, 34 insertions(+), 9 deletions(-) diff --git a/MP.SPEC/Components/DossiersFilter.razor b/MP.SPEC/Components/DossiersFilter.razor index df7df4c3..145fc9dd 100644 --- a/MP.SPEC/Components/DossiersFilter.razor +++ b/MP.SPEC/Components/DossiersFilter.razor @@ -14,7 +14,7 @@
      -
      +
      diff --git a/MP.SPEC/Components/ListPARAMS.razor.cs b/MP.SPEC/Components/ListPARAMS.razor.cs index 31574c02..c1543575 100644 --- a/MP.SPEC/Components/ListPARAMS.razor.cs +++ b/MP.SPEC/Components/ListPARAMS.razor.cs @@ -166,9 +166,12 @@ namespace MP.SPEC.Components currRecord = selRec; SelFilter.IdxMacchina = selRec.IdxMacchina; SelDtMax = selRec.dtEvento; + // imposto pag 1 filtro + SelFilter.CurrPage = 1; //selDtMin = RoundDatetime(5).AddHours(-25); await reloadData(false); await RecordSel.InvokeAsync(selRec); + await PagerResetReq.InvokeAsync(true); } protected async Task UpdateData() diff --git a/MP.SPEC/Components/ParamsFilter.razor b/MP.SPEC/Components/ParamsFilter.razor index ae01c039..279ae55d 100644 --- a/MP.SPEC/Components/ParamsFilter.razor +++ b/MP.SPEC/Components/ParamsFilter.razor @@ -38,9 +38,27 @@
      - - - +
      + @if (filtActive) + { +
      + @**@ + @if (selMacchina != "*") + { + + } + @if (selFlux != "*") + { + + } +
      + } +
      + + + +
      +

      FILTRI

      diff --git a/MP.SPEC/Components/ParamsFilter.razor.cs b/MP.SPEC/Components/ParamsFilter.razor.cs index 219b6633..0aed527a 100644 --- a/MP.SPEC/Components/ParamsFilter.razor.cs +++ b/MP.SPEC/Components/ParamsFilter.razor.cs @@ -165,6 +165,10 @@ namespace MP.SPEC.Components NavManager.NavigateTo("DOSS", true); } + private bool filtActive + { + get => selMacchina != "*" || selFlux != "*"; + } protected override async Task OnInitializedAsync() { SelFilter = new SelectFluxParams(); diff --git a/MP.SPEC/MP.SPEC.csproj b/MP.SPEC/MP.SPEC.csproj index 27a3af44..b871039a 100644 --- a/MP.SPEC/MP.SPEC.csproj +++ b/MP.SPEC/MP.SPEC.csproj @@ -5,7 +5,7 @@ enable enable MP.SPEC - 6.16.2210.2109 + 6.16.2210.2110 diff --git a/MP.SPEC/Resources/ChangeLog.html b/MP.SPEC/Resources/ChangeLog.html index 889923ac..84ccf39f 100644 --- a/MP.SPEC/Resources/ChangeLog.html +++ b/MP.SPEC/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

      Versione: 6.16.2210.2109

      +

      Versione: 6.16.2210.2110


      Note di rilascio:
      • diff --git a/MP.SPEC/Resources/VersNum.txt b/MP.SPEC/Resources/VersNum.txt index 51b08b69..148d3a17 100644 --- a/MP.SPEC/Resources/VersNum.txt +++ b/MP.SPEC/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2210.2109 +6.16.2210.2110 diff --git a/MP.SPEC/Resources/manifest.xml b/MP.SPEC/Resources/manifest.xml index 81a51989..463051c6 100644 --- a/MP.SPEC/Resources/manifest.xml +++ b/MP.SPEC/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2210.2109 + 6.16.2210.2110 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 From 8b912101151ab937a6591b756752e1fb82b20f31 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 21 Oct 2022 10:42:08 +0200 Subject: [PATCH 04/13] fix copia script x cambio vers num --- MP.Land/MP.Land.csproj | 8 +++++++- MP.Land/Resources/ChangeLog.html | 2 +- MP.Land/Resources/VersNum.txt | 2 +- MP.Land/Resources/manifest.xml | 2 +- MP.Mon/MP.Mon.csproj | 3 +++ MP.SPEC/Components/ParamsFilter.razor | 1 - MP.Stats/MP.Stats.csproj | 5 ++++- MP.Stats/Resources/ChangeLog.html | 2 +- MP.Stats/Resources/VersNum.txt | 2 +- MP.Stats/Resources/manifest.xml | 2 +- 10 files changed, 20 insertions(+), 9 deletions(-) diff --git a/MP.Land/MP.Land.csproj b/MP.Land/MP.Land.csproj index 583536b7..46488966 100644 --- a/MP.Land/MP.Land.csproj +++ b/MP.Land/MP.Land.csproj @@ -3,7 +3,7 @@ net6.0 MP.Land - 6.16.2209.2118 + 6.16.2210.2110 @@ -60,6 +60,12 @@ + + + Always + + + diff --git a/MP.Land/Resources/ChangeLog.html b/MP.Land/Resources/ChangeLog.html index 85af7886..16b19149 100644 --- a/MP.Land/Resources/ChangeLog.html +++ b/MP.Land/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo gestione Programmi MAPO -

        Versione: 6.16.2209.2118

        +

        Versione: 6.16.2210.2110


        Note di rilascio:
          diff --git a/MP.Land/Resources/VersNum.txt b/MP.Land/Resources/VersNum.txt index ebf3f94a..148d3a17 100644 --- a/MP.Land/Resources/VersNum.txt +++ b/MP.Land/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2209.2118 +6.16.2210.2110 diff --git a/MP.Land/Resources/manifest.xml b/MP.Land/Resources/manifest.xml index 8037398c..06b6c830 100644 --- a/MP.Land/Resources/manifest.xml +++ b/MP.Land/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2209.2118 + 6.16.2210.2110 https://nexus.steamware.net/repository/SWS/MP-LAND/stable/LAST/MP.Land.zip https://nexus.steamware.net/repository/SWS/MP-LAND/stable/LAST/ChangeLog.html false diff --git a/MP.Mon/MP.Mon.csproj b/MP.Mon/MP.Mon.csproj index 0e94de4f..536bb21c 100644 --- a/MP.Mon/MP.Mon.csproj +++ b/MP.Mon/MP.Mon.csproj @@ -48,6 +48,9 @@ Always + + Always + diff --git a/MP.SPEC/Components/ParamsFilter.razor b/MP.SPEC/Components/ParamsFilter.razor index 279ae55d..729eff45 100644 --- a/MP.SPEC/Components/ParamsFilter.razor +++ b/MP.SPEC/Components/ParamsFilter.razor @@ -42,7 +42,6 @@ @if (filtActive) {
          - @**@ @if (selMacchina != "*") { diff --git a/MP.Stats/MP.Stats.csproj b/MP.Stats/MP.Stats.csproj index d7726462..8683fb68 100644 --- a/MP.Stats/MP.Stats.csproj +++ b/MP.Stats/MP.Stats.csproj @@ -4,7 +4,7 @@ net6.0 MP.Stats 826e877c-ba70-4253-84cb-d0b1cafd4440 - 6.16.2210.1708 + 6.16.2210.2110 @@ -203,6 +203,9 @@ PreserveNewest + + Always + Always diff --git a/MP.Stats/Resources/ChangeLog.html b/MP.Stats/Resources/ChangeLog.html index 476f07b6..c3a834ed 100644 --- a/MP.Stats/Resources/ChangeLog.html +++ b/MP.Stats/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo statistiche MAPO -

          Versione: 6.16.2210.1708

          +

          Versione: 6.16.2210.2110


          Note di rilascio:
            diff --git a/MP.Stats/Resources/VersNum.txt b/MP.Stats/Resources/VersNum.txt index ccf0292a..148d3a17 100644 --- a/MP.Stats/Resources/VersNum.txt +++ b/MP.Stats/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2210.1708 +6.16.2210.2110 diff --git a/MP.Stats/Resources/manifest.xml b/MP.Stats/Resources/manifest.xml index e4fe64f1..b9e7e7bc 100644 --- a/MP.Stats/Resources/manifest.xml +++ b/MP.Stats/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2210.1708 + 6.16.2210.2110 https://nexus.steamware.net/repository/SWS/MP-STATS/stable/LAST/MP.Stats.zip https://nexus.steamware.net/repository/SWS/MP-STATS/stable/LAST/ChangeLog.html false From eb115333382db6dbf94f1e651afeed209e081c05 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Fri, 21 Oct 2022 12:51:52 +0200 Subject: [PATCH 05/13] display filtri attivi fine --- MP.SPEC/Components/DossiersFilter.razor | 24 +++++++++++++++++--- MP.SPEC/Components/DossiersFilter.razor.cs | 13 ++++++++++- MP.SPEC/Components/ParamsFilter.razor | 26 ++++++++++------------ MP.SPEC/Components/ParamsFilter.razor.cs | 21 ++++++++++++----- MP.SPEC/MP.SPEC.csproj | 2 +- MP.SPEC/Pages/ODL.razor | 24 +++++++++++++++++--- MP.SPEC/Pages/ODL.razor.cs | 12 ++++++++++ MP.SPEC/Resources/ChangeLog.html | 2 +- MP.SPEC/Resources/VersNum.txt | 2 +- MP.SPEC/Resources/manifest.xml | 2 +- 10 files changed, 97 insertions(+), 31 deletions(-) diff --git a/MP.SPEC/Components/DossiersFilter.razor b/MP.SPEC/Components/DossiersFilter.razor index 145fc9dd..d8607670 100644 --- a/MP.SPEC/Components/DossiersFilter.razor +++ b/MP.SPEC/Components/DossiersFilter.razor @@ -1,7 +1,25 @@ 
            - - - +
            + @if (filtActive) + { +
            + @**@ + @if (selMacchina != "*") + { + + } + @if (selArticolo != "*") + { + + } +
            + } +
            + + + +
            +

            FILTRI

            diff --git a/MP.SPEC/Components/DossiersFilter.razor.cs b/MP.SPEC/Components/DossiersFilter.razor.cs index f5dd2bbe..98cdbe8f 100644 --- a/MP.SPEC/Components/DossiersFilter.razor.cs +++ b/MP.SPEC/Components/DossiersFilter.razor.cs @@ -38,7 +38,18 @@ namespace MP.SPEC.Components } } } - + private bool filtActive + { + get => selMacchina != "*" || selArticolo != "*"; + } + protected void resetMacchina() + { + selMacchina = "*"; + } + protected void resetArticolo() + { + selArticolo = "*"; + } protected DateTime selDtMax { get diff --git a/MP.SPEC/Components/ParamsFilter.razor b/MP.SPEC/Components/ParamsFilter.razor index 279ae55d..a6cfe239 100644 --- a/MP.SPEC/Components/ParamsFilter.razor +++ b/MP.SPEC/Components/ParamsFilter.razor @@ -3,13 +3,13 @@
            @if (!liveUpdate) { - } else { - @@ -41,19 +41,17 @@
            @if (filtActive) { -
            - @**@ - @if (selMacchina != "*") - { - - } - @if (selFlux != "*") - { - - } -
            + @**@ + @if (selMacchina != "*") + { + + } + @if (selFlux != "*") + { + + } } -
            +
            diff --git a/MP.SPEC/Components/ParamsFilter.razor.cs b/MP.SPEC/Components/ParamsFilter.razor.cs index 0aed527a..c29423a6 100644 --- a/MP.SPEC/Components/ParamsFilter.razor.cs +++ b/MP.SPEC/Components/ParamsFilter.razor.cs @@ -211,6 +211,14 @@ namespace MP.SPEC.Components aTimer.Enabled = true; aTimer.Start(); } + protected void resetMacchina() + { + selMacchina = "*"; + } + protected void resetFase() + { + selFlux = "*"; + } protected async Task takeSnapshot() { @@ -234,18 +242,19 @@ namespace MP.SPEC.Components selDtMax = null; } - protected async Task toggleUpdate() + protected async Task notLive() { - liveUpdate = !liveUpdate; + liveUpdate = false; await Task.Delay(1); if (!liveUpdate) { lastUpdate = $"{DateTime.Now:yyyy/MM/dd HH:mm:ss}"; } - else - { - selDtMax = null; - } + } + protected async Task live() + { + liveUpdate = true; + await Task.Delay(1); } #endregion Protected Methods diff --git a/MP.SPEC/MP.SPEC.csproj b/MP.SPEC/MP.SPEC.csproj index b871039a..ae517e0b 100644 --- a/MP.SPEC/MP.SPEC.csproj +++ b/MP.SPEC/MP.SPEC.csproj @@ -5,7 +5,7 @@ enable enable MP.SPEC - 6.16.2210.2110 + 6.16.2210.2112 diff --git a/MP.SPEC/Pages/ODL.razor b/MP.SPEC/Pages/ODL.razor index e1d49972..b31a35a4 100644 --- a/MP.SPEC/Pages/ODL.razor +++ b/MP.SPEC/Pages/ODL.razor @@ -20,9 +20,27 @@
            - - - +
            + @if (filtActive) + { +
            + @**@ + @if (selMacchina != "*") + { + + } + @if (selStato != "*") + { + + } +
            + } +
            + + + +
            +

            FILTRI

            diff --git a/MP.SPEC/Pages/ODL.razor.cs b/MP.SPEC/Pages/ODL.razor.cs index a29dcdd0..592e6c2a 100644 --- a/MP.SPEC/Pages/ODL.razor.cs +++ b/MP.SPEC/Pages/ODL.razor.cs @@ -71,7 +71,19 @@ namespace MP.SPEC.Pages #endregion Protected Properties #region Protected Methods + private bool filtActive + { + get => selMacchina != "*" || selStato != "*"; + } + protected void resetMacchina() + { + selMacchina = "*"; + } + protected void resetFase() + { + selStato = "*"; + } protected void ForceReload(int newNum) { numRecord = newNum; diff --git a/MP.SPEC/Resources/ChangeLog.html b/MP.SPEC/Resources/ChangeLog.html index 84ccf39f..41ed64e1 100644 --- a/MP.SPEC/Resources/ChangeLog.html +++ b/MP.SPEC/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

            Versione: 6.16.2210.2110

            +

            Versione: 6.16.2210.2112


            Note di rilascio:
            • diff --git a/MP.SPEC/Resources/VersNum.txt b/MP.SPEC/Resources/VersNum.txt index 148d3a17..611d3d51 100644 --- a/MP.SPEC/Resources/VersNum.txt +++ b/MP.SPEC/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2210.2110 +6.16.2210.2112 diff --git a/MP.SPEC/Resources/manifest.xml b/MP.SPEC/Resources/manifest.xml index 463051c6..a74c9b0c 100644 --- a/MP.SPEC/Resources/manifest.xml +++ b/MP.SPEC/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2210.2110 + 6.16.2210.2112 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 From 185e27f31d0cc15e84fa72ece977c4750739f97b Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Fri, 21 Oct 2022 14:14:12 +0200 Subject: [PATCH 06/13] fix bottone liveupdate --- MP.SPEC/Components/ListPARAMS.razor.cs | 2 +- MP.SPEC/Components/ParamsFilter.razor | 171 +++++++++++-------------- MP.SPEC/Pages/PARAMS.razor.cs | 4 +- 3 files changed, 80 insertions(+), 97 deletions(-) diff --git a/MP.SPEC/Components/ListPARAMS.razor.cs b/MP.SPEC/Components/ListPARAMS.razor.cs index c1543575..c00ddcbe 100644 --- a/MP.SPEC/Components/ListPARAMS.razor.cs +++ b/MP.SPEC/Components/ListPARAMS.razor.cs @@ -238,7 +238,7 @@ namespace MP.SPEC.Components // copio il filtro var currFilt = SelFilter; // fermo update - currFilt.LiveUpdate = true; + //currFilt.LiveUpdate = true; currFilt.CurrPage = 0; currFilt.lastUpdate = $"{DateTime.Now:yyyy/MM/dd HH:mm:ss}"; currFilt.dtMax = RoundDatetime(5); diff --git a/MP.SPEC/Components/ParamsFilter.razor b/MP.SPEC/Components/ParamsFilter.razor index ee176a05..ddd653a1 100644 --- a/MP.SPEC/Components/ParamsFilter.razor +++ b/MP.SPEC/Components/ParamsFilter.razor @@ -41,7 +41,6 @@
              @if (filtActive) { -<<<<<<< HEAD @**@ @if (selMacchina != "*") { @@ -51,24 +50,7 @@ { } -======= -
              - @if (selMacchina != "*") - { - - } - @if (selFlux != "*") - { - - } -
              ->>>>>>> 8b912101151ab937a6591b756752e1fb82b20f31 - } - @if (selFlux != "*") - { - - } -
              + }
            -
            -
            -

            FILTRI

            - +
            +
            +
            +

            FILTRI

            + +
            +
            +
            +
            -
            -
            - -
            -
            - - + + @if (ListMacchine != null) + { + foreach (var item in ListMacchine) { - foreach (var item in ListMacchine) - { - - } + } - -
            -
            - -
            -
            - - +
            +
            + +
            +
            + + -
            -
            - -
            -
            - - -
            -
            - -
            -
            - - -
            -
            - -
            -
            - - -
            -
            - -
            -
            - - -
            + } + +
            +
            + +
            +
            + + +
            +
            + +
            +
            + + +
            +
            + +
            +
            + + +
            +
            + +
            +
            + +
            +
            diff --git a/MP.SPEC/Pages/PARAMS.razor.cs b/MP.SPEC/Pages/PARAMS.razor.cs index a04de781..2428b24d 100644 --- a/MP.SPEC/Pages/PARAMS.razor.cs +++ b/MP.SPEC/Pages/PARAMS.razor.cs @@ -30,7 +30,7 @@ namespace MP.SPEC.Pages currPage = newNum; DateTime adesso = DateTime.Now.AddSeconds(1); var updFilter = currFilter; - updFilter.LiveUpdate = (currPage == 1); + //updFilter.LiveUpdate = (currPage == 1); updFilter.lastUpdate = updFilter.LiveUpdate ? "-" : $"{adesso:yyyy/MM/dd HH:mm:ss}"; // salvo filtro currFilter = updFilter; @@ -127,7 +127,7 @@ namespace MP.SPEC.Pages } else { - newParams.LiveUpdate = (currPage == 1); + //newParams.LiveUpdate = (currPage == 1); } await Task.Delay(1); await InvokeAsync(() => StateHasChanged()); From b07c610edd3e121b2f909839f91602beed0db797 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Fri, 21 Oct 2022 15:40:26 +0200 Subject: [PATCH 07/13] fix pagina params --- MP.SPEC/Components/ParamsFilter.razor | 1 - MP.SPEC/MP.SPEC.csproj | 2 +- MP.SPEC/Resources/ChangeLog.html | 2 +- MP.SPEC/Resources/VersNum.txt | 2 +- MP.SPEC/Resources/manifest.xml | 2 +- 5 files changed, 4 insertions(+), 5 deletions(-) diff --git a/MP.SPEC/Components/ParamsFilter.razor b/MP.SPEC/Components/ParamsFilter.razor index ddd653a1..60bfd4ab 100644 --- a/MP.SPEC/Components/ParamsFilter.razor +++ b/MP.SPEC/Components/ParamsFilter.razor @@ -141,5 +141,4 @@
            -
            diff --git a/MP.SPEC/MP.SPEC.csproj b/MP.SPEC/MP.SPEC.csproj index ae517e0b..544da043 100644 --- a/MP.SPEC/MP.SPEC.csproj +++ b/MP.SPEC/MP.SPEC.csproj @@ -5,7 +5,7 @@ enable enable MP.SPEC - 6.16.2210.2112 + 6.16.2210.2115 diff --git a/MP.SPEC/Resources/ChangeLog.html b/MP.SPEC/Resources/ChangeLog.html index 41ed64e1..77837625 100644 --- a/MP.SPEC/Resources/ChangeLog.html +++ b/MP.SPEC/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

            Versione: 6.16.2210.2112

            +

            Versione: 6.16.2210.2115


            Note di rilascio:
            • diff --git a/MP.SPEC/Resources/VersNum.txt b/MP.SPEC/Resources/VersNum.txt index 611d3d51..aa73f981 100644 --- a/MP.SPEC/Resources/VersNum.txt +++ b/MP.SPEC/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2210.2112 +6.16.2210.2115 diff --git a/MP.SPEC/Resources/manifest.xml b/MP.SPEC/Resources/manifest.xml index a74c9b0c..9448f3cd 100644 --- a/MP.SPEC/Resources/manifest.xml +++ b/MP.SPEC/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2210.2112 + 6.16.2210.2115 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 From ea930b308d4b9d37691dff71252ce5d7e296a88f Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Wed, 26 Oct 2022 17:25:09 +0200 Subject: [PATCH 08/13] fix richiesti pagina PODL --- MP.SPEC/Components/ListPODL.razor | 6 +++--- MP.SPEC/MP.SPEC.csproj | 2 +- MP.SPEC/Pages/PODL.razor | 26 +++++++++++++++++--------- MP.SPEC/Pages/PODL.razor.cs | 15 +++++++++++++++ MP.SPEC/Resources/ChangeLog.html | 2 +- MP.SPEC/Resources/VersNum.txt | 2 +- MP.SPEC/Resources/manifest.xml | 2 +- 7 files changed, 39 insertions(+), 16 deletions(-) diff --git a/MP.SPEC/Components/ListPODL.razor b/MP.SPEC/Components/ListPODL.razor index 85641a6c..4bcc0552 100644 --- a/MP.SPEC/Components/ListPODL.razor +++ b/MP.SPEC/Components/ListPODL.razor @@ -37,13 +37,13 @@ else @if (canStartOdl(record.IdxMacchina)) { - } else - { - } diff --git a/MP.SPEC/MP.SPEC.csproj b/MP.SPEC/MP.SPEC.csproj index 544da043..f0534463 100644 --- a/MP.SPEC/MP.SPEC.csproj +++ b/MP.SPEC/MP.SPEC.csproj @@ -5,7 +5,7 @@ enable enable MP.SPEC - 6.16.2210.2115 + 6.16.2210.2617 diff --git a/MP.SPEC/Pages/PODL.razor b/MP.SPEC/Pages/PODL.razor index edd74ebb..929bc105 100644 --- a/MP.SPEC/Pages/PODL.razor +++ b/MP.SPEC/Pages/PODL.razor @@ -12,7 +12,7 @@
              @if (addEnabled) { - + }
            @@ -21,19 +21,20 @@
            @* *@ diff --git a/MP.SPEC/Pages/PODL.razor.cs b/MP.SPEC/Pages/PODL.razor.cs index 56c65581..351d2ed0 100644 --- a/MP.SPEC/Pages/PODL.razor.cs +++ b/MP.SPEC/Pages/PODL.razor.cs @@ -203,6 +203,21 @@ namespace MP.SPEC.Pages } } + private bool selectFirst(string idxMacchina) + { + string firstMacchina=""; + bool ans = false; + if (ListMacchine != null) + { + firstMacchina = ListMacchine.Select(x => x.IdxMacchina).FirstOrDefault(); + } + if (firstMacchina == idxMacchina) + { + ans = true; + } + return ans; + } + private string btnNewText { get => currArticolo == "" ? "Sel Articolo" : "Nuovo PODL"; diff --git a/MP.SPEC/Resources/ChangeLog.html b/MP.SPEC/Resources/ChangeLog.html index 77837625..c9794f03 100644 --- a/MP.SPEC/Resources/ChangeLog.html +++ b/MP.SPEC/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

            Versione: 6.16.2210.2115

            +

            Versione: 6.16.2210.2617


            Note di rilascio:
            • diff --git a/MP.SPEC/Resources/VersNum.txt b/MP.SPEC/Resources/VersNum.txt index aa73f981..8baef796 100644 --- a/MP.SPEC/Resources/VersNum.txt +++ b/MP.SPEC/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2210.2115 +6.16.2210.2617 diff --git a/MP.SPEC/Resources/manifest.xml b/MP.SPEC/Resources/manifest.xml index 9448f3cd..867aae92 100644 --- a/MP.SPEC/Resources/manifest.xml +++ b/MP.SPEC/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2210.2115 + 6.16.2210.2617 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 From 39cf45869cc9da8648c3ffd016821b2b33c76f57 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Wed, 26 Oct 2022 17:27:45 +0200 Subject: [PATCH 09/13] fix order --- MP.Data/Controllers/MpSpecController.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MP.Data/Controllers/MpSpecController.cs b/MP.Data/Controllers/MpSpecController.cs index 5c169377..7438fee2 100644 --- a/MP.Data/Controllers/MpSpecController.cs +++ b/MP.Data/Controllers/MpSpecController.cs @@ -555,7 +555,7 @@ namespace MP.Data.Controllers .AsNoTracking() .Include(m => m.MachineNav) .Include(a => a.ArticoloNav) - .OrderBy(x => x.InsertDate) + .OrderByDescending(x => x.InsertDate) .ToList(); } return dbResult; From 40b16d2e83249f05e0ed2e55e7d86376e2a36368 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 3 Nov 2022 11:28:15 +0100 Subject: [PATCH 10/13] spostato bottone flush cache in top --- MP.SPEC/Components/CmpTop.razor | 25 +++++++++++++++++++++++-- MP.SPEC/MP.SPEC.csproj | 2 +- MP.SPEC/Resources/ChangeLog.html | 2 +- MP.SPEC/Resources/VersNum.txt | 2 +- MP.SPEC/Resources/manifest.xml | 2 +- MP.SPEC/Shared/NavMenu.razor | 1 + 6 files changed, 28 insertions(+), 6 deletions(-) diff --git a/MP.SPEC/Components/CmpTop.razor b/MP.SPEC/Components/CmpTop.razor index 8061e546..79c66797 100644 --- a/MP.SPEC/Components/CmpTop.razor +++ b/MP.SPEC/Components/CmpTop.razor @@ -10,7 +10,10 @@
              @userName
              -
              +
              + +
              + @*
              @TipoSearch
              @@ -18,7 +21,7 @@ { } -
              +
              *@
            @code { @@ -62,4 +65,22 @@ userName = "N.A."; } } + + public async Task flushCache() + { + await Task.Delay(1); + await MDService.FlushRedisCache(); + await JSRuntime.InvokeAsync("location.reload"); + // rimando a home + //NavManager.NavigateTo("", true); + } + + [Inject] + private NavigationManager NavManager { get; set; } = null!; + + [Inject] + protected MpDataService MDService { get; set; } = null!; + + [Inject] + protected IJSRuntime JSRuntime { get; set; } = null!; } diff --git a/MP.SPEC/MP.SPEC.csproj b/MP.SPEC/MP.SPEC.csproj index f0534463..fc722818 100644 --- a/MP.SPEC/MP.SPEC.csproj +++ b/MP.SPEC/MP.SPEC.csproj @@ -5,7 +5,7 @@ enable enable MP.SPEC - 6.16.2210.2617 + 6.16.2211.310 diff --git a/MP.SPEC/Resources/ChangeLog.html b/MP.SPEC/Resources/ChangeLog.html index c9794f03..5c889378 100644 --- a/MP.SPEC/Resources/ChangeLog.html +++ b/MP.SPEC/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

            Versione: 6.16.2210.2617

            +

            Versione: 6.16.2211.310


            Note di rilascio:
            • diff --git a/MP.SPEC/Resources/VersNum.txt b/MP.SPEC/Resources/VersNum.txt index 8baef796..6656208b 100644 --- a/MP.SPEC/Resources/VersNum.txt +++ b/MP.SPEC/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2210.2617 +6.16.2211.310 diff --git a/MP.SPEC/Resources/manifest.xml b/MP.SPEC/Resources/manifest.xml index 867aae92..e1da50ab 100644 --- a/MP.SPEC/Resources/manifest.xml +++ b/MP.SPEC/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2210.2617 + 6.16.2211.310 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 diff --git a/MP.SPEC/Shared/NavMenu.razor b/MP.SPEC/Shared/NavMenu.razor index a21d13ba..f0496859 100644 --- a/MP.SPEC/Shared/NavMenu.razor +++ b/MP.SPEC/Shared/NavMenu.razor @@ -38,6 +38,7 @@ { foreach (var item in ElencoLink) { +