From f74e3980eb1b28080b732accfb33b941b4bda831 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 10 Nov 2023 17:30:19 +0100 Subject: [PATCH 001/100] Inizio test modifica sel macchine 2 tav --- MP-TAB-SERV/Components/MachineBlock.razor.cs | 24 ++-- MP-TAB-SERV/Components/OdlMan.razor.cs | 4 + MP-TAB-SERV/MP-TAB-SERV.csproj | 2 +- MP-TAB-SERV/Pages/ODL.razor | 2 +- MP-TAB-SERV/Pages/ODL.razor.cs | 47 ++++--- MP-TAB-SERV/Resources/ChangeLog.html | 2 +- MP-TAB-SERV/Resources/VersNum.txt | 2 +- MP-TAB-SERV/Resources/manifest.xml | 2 +- MP.Data/Constants.cs | 1 + MP.Data/Controllers/MpTabController.cs | 141 +++++++++++-------- MP.Data/Services/TabDataService.cs | 59 ++++++-- 11 files changed, 188 insertions(+), 98 deletions(-) diff --git a/MP-TAB-SERV/Components/MachineBlock.razor.cs b/MP-TAB-SERV/Components/MachineBlock.razor.cs index 08617025..a9723242 100644 --- a/MP-TAB-SERV/Components/MachineBlock.razor.cs +++ b/MP-TAB-SERV/Components/MachineBlock.razor.cs @@ -4,7 +4,6 @@ using Microsoft.JSInterop; using MP.Data.DatabaseModels; using MP.Data.Services; using NLog; -using static Org.BouncyCastle.Math.EC.ECCurve; namespace MP_TAB_SERV.Components { @@ -17,6 +16,11 @@ namespace MP_TAB_SERV.Components [Parameter] public bool FullMode { get; set; } = true; + [Parameter] + public int Height { get; set; } = 0; + + [Parameter] + public string IdxMacchSub { get; set; } = ""; [Parameter] public int keepAliveMin { get; set; } = 5; @@ -30,9 +34,6 @@ namespace MP_TAB_SERV.Components [Parameter] public int Width { get; set; } = 0; - [Parameter] - public int Height { get; set; } = 0; - #endregion Public Properties #region Public Methods @@ -96,6 +97,9 @@ namespace MP_TAB_SERV.Components #region Protected Properties + [Inject] + protected IConfiguration config { get; set; } = null!; + protected ProdAdvDispl.ProdCounter CurrCount { get @@ -123,14 +127,13 @@ namespace MP_TAB_SERV.Components [Inject] protected NavigationManager NavMan { get; set; } = null!; + [Inject] + protected TabDataService TabDServ { get; set; } = null!; + #endregion Protected Properties #region Protected Methods - - [Inject] - protected IConfiguration config { get; set; } = null!; - protected override async Task OnAfterRenderAsync(bool firstRender) {//await Task.Delay(500); if (firstRender) @@ -161,6 +164,11 @@ namespace MP_TAB_SERV.Components protected override void OnParametersSet() { isLoading = RecMSE == null; + //// controllo SE avessi idxMacchSub --> rileggo! + //if (!string.IsNullOrEmpty(IdxMacchSub) && RecMSE != null) + //{ + // RecMSE = TabDServ.MseGetSub(RecMSE.IdxMacchina, IdxMacchSub, true); + //} setGaugeVals(); } diff --git a/MP-TAB-SERV/Components/OdlMan.razor.cs b/MP-TAB-SERV/Components/OdlMan.razor.cs index 62ccc4c5..20cff024 100644 --- a/MP-TAB-SERV/Components/OdlMan.razor.cs +++ b/MP-TAB-SERV/Components/OdlMan.razor.cs @@ -755,6 +755,9 @@ namespace MP_TAB_SERV.Components } } + [Parameter] + public EventCallback E_MachSel { get; set; } + protected async Task SendWarnTcChangeReq(int idxOdl, decimal tcAss, decimal tcRich) { // carico altri parametri email... @@ -792,6 +795,7 @@ namespace MP_TAB_SERV.Components IdxMaccSel = selIdxMacc; await DoUpdate(); isProcessing = false; + await E_MachSel.InvokeAsync(selIdxMacc); await Task.Delay(10); } diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index c93c3d22..a7bdcc19 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.1016 + 6.16.2311.1017 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Pages/ODL.razor b/MP-TAB-SERV/Pages/ODL.razor index 8fdeb1fa..8f141d37 100644 --- a/MP-TAB-SERV/Pages/ODL.razor +++ b/MP-TAB-SERV/Pages/ODL.razor @@ -8,5 +8,5 @@ else { - + } diff --git a/MP-TAB-SERV/Pages/ODL.razor.cs b/MP-TAB-SERV/Pages/ODL.razor.cs index 6e382c7d..016371db 100644 --- a/MP-TAB-SERV/Pages/ODL.razor.cs +++ b/MP-TAB-SERV/Pages/ODL.razor.cs @@ -23,25 +23,6 @@ namespace MP_TAB_SERV.Pages await ReloadData(); } - #endregion Protected Methods - - #region Private Methods - - private async Task ReloadData() - { - if (string.IsNullOrEmpty(IdxMacc)) - { - IdxMacc = await MsgServ.IdxMaccGet(); - // recupero MSE macchina.... - if (!string.IsNullOrEmpty(IdxMacc)) - { - CurrMSE = await MsgServ.GetMachineMse(IdxMacc); - } - } - } - - - protected async Task RefreshData(List newList) { var ListMSE = newList; @@ -69,6 +50,34 @@ namespace MP_TAB_SERV.Pages } } + protected async Task SetMacc(string selIdxMacc) + { + CurrMSE = null; + await Task.Delay(1); + IdxMacc = selIdxMacc; + await MsgServ.IdxMaccSet(selIdxMacc); + // recupero MSE macchina.... + CurrMSE = await MsgServ.GetMachineMse(IdxMacc); + await InvokeAsync(StateHasChanged); + } + + #endregion Protected Methods + + #region Private Methods + + private async Task ReloadData() + { + if (string.IsNullOrEmpty(IdxMacc)) + { + IdxMacc = await MsgServ.IdxMaccGet(); + // recupero MSE macchina.... + if (!string.IsNullOrEmpty(IdxMacc)) + { + CurrMSE = await MsgServ.GetMachineMse(IdxMacc); + } + } + } + #endregion Private Methods } } \ No newline at end of file diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 8d44feee..dcb3afed 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.1016

+

Versione: 6.16.2311.1017


Note di rilascio:
  • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index e1f886bd..8b8eb08c 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1016 +6.16.2311.1017 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index e8dda042..998f69ad 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1016 + 6.16.2311.1017 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP.Data/Constants.cs b/MP.Data/Constants.cs index 9f43bd5b..ea73a57c 100644 --- a/MP.Data/Constants.cs +++ b/MP.Data/Constants.cs @@ -20,6 +20,7 @@ public static string redisMseKey = "MP:MON:Cache:MSE"; + public static string redisMseKeySingle = "MP:MON:Cache:MseSingle"; #endregion Public Fields } diff --git a/MP.Data/Controllers/MpTabController.cs b/MP.Data/Controllers/MpTabController.cs index ef4d23f9..6224c7ac 100644 --- a/MP.Data/Controllers/MpTabController.cs +++ b/MP.Data/Controllers/MpTabController.cs @@ -765,6 +765,35 @@ namespace MP.Data.Controllers return fatto; } + /// + /// Dati MSE x singola macchina SUB (tipicamente TAV) + /// + /// + /// + /// + public List MseGetSub(string idxMacc, string idxMacchSub) + { + List dbResult = new List(); + using (var dbCtx = new MoonProContext(_configuration)) + { + try + { + var IdxMacc = new SqlParameter("@IdxMacchina", idxMacc); + var IdxMacchSub = new SqlParameter("@IdxMacchSub", idxMacchSub); + dbResult = dbCtx + .DbSetMSE + .FromSqlRaw("EXEC stp_ODL_fineProd @IdxMacchina, @IdxMacchSub", IdxMacc, IdxMacchSub) + .AsNoTracking() + .ToList(); + } + catch (Exception exc) + { + Log.Error($"Eccezione durante MseGetSub{Environment.NewLine}{exc}"); + } + } + return dbResult; + } + /// /// ODL da key /// @@ -821,33 +850,6 @@ namespace MP.Data.Controllers return dbResult; } - /// - /// Registro fine prod ODL - /// - /// - /// - /// - public bool OdlFineProd(int idxODL, string idxMacchina) - { - bool fatto = false; - using (var dbCtx = new MoonProContext(_configuration)) - { - try - { - var IdxODL = new SqlParameter("@IdxODL", idxODL); - var IdxMacc = new SqlParameter("@IdxMacchina", idxMacchina); - var result = dbCtx - .Database - .ExecuteSqlRaw("EXEC stp_ODL_fineProd @IdxODL, @IdxMacchina", IdxODL, IdxMacc); - fatto = result != 0; - } - catch (Exception exc) - { - Log.Error($"Eccezione durante OdlFineProd{Environment.NewLine}{exc}"); - } - } - return fatto; - } /// /// Attrezzo stesso ODL dell'altra tavola /// @@ -878,7 +880,33 @@ namespace MP.Data.Controllers return fatto; } - + /// + /// Registro fine prod ODL + /// + /// + /// + /// + public bool OdlFineProd(int idxODL, string idxMacchina) + { + bool fatto = false; + using (var dbCtx = new MoonProContext(_configuration)) + { + try + { + var IdxODL = new SqlParameter("@IdxODL", idxODL); + var IdxMacc = new SqlParameter("@IdxMacchina", idxMacchina); + var result = dbCtx + .Database + .ExecuteSqlRaw("EXEC stp_ODL_fineProd @IdxODL, @IdxMacchina", IdxODL, IdxMacc); + fatto = result != 0; + } + catch (Exception exc) + { + Log.Error($"Eccezione durante OdlFineProd{Environment.NewLine}{exc}"); + } + } + return fatto; + } /// /// Fix ODL per macchine SLAVE @@ -946,6 +974,33 @@ namespace MP.Data.Controllers return fatto; } + /// + /// Ultimo ODL data macchina + /// + /// + /// + public List OdlLastByMacc(string idxMacchina) + { + List dbResult = new List(); + using (var dbCtx = new MoonProContext(_configuration)) + { + try + { + var IdxMacchina = new SqlParameter("@IdxMacchina", idxMacchina); + dbResult = dbCtx + .DbSetODL + .FromSqlRaw("EXEC stp_ODL_getLastByMacchina @IdxMacchina", IdxMacchina) + .AsNoTracking() + .ToList(); + } + catch (Exception exc) + { + Log.Error($"Eccezione durante OdlLastByMacc{Environment.NewLine}{exc}"); + } + } + return dbResult; + } + /// /// Elenco ODL data macchina e periodo /// @@ -977,34 +1032,6 @@ namespace MP.Data.Controllers return dbResult; } - /// - /// Ultimo ODL data macchina - /// - /// - /// - public List OdlLastByMacc(string idxMacchina) - { - List dbResult = new List(); - using (var dbCtx = new MoonProContext(_configuration)) - { - try - { - var IdxMacchina = new SqlParameter("@IdxMacchina", idxMacchina); - dbResult = dbCtx - .DbSetODL - .FromSqlRaw("EXEC stp_ODL_getLastByMacchina @IdxMacchina", IdxMacchina) - .AsNoTracking() - .ToList(); - } - catch (Exception exc) - { - Log.Error($"Eccezione durante OdlLastByMacc{Environment.NewLine}{exc}"); - } - } - return dbResult; - } - - /// /// Riapertura ULTIMO ODL data macchina /// @@ -1032,8 +1059,6 @@ namespace MP.Data.Controllers return dbResult; } - - /// /// Setup ODL Postumo /// diff --git a/MP.Data/Services/TabDataService.cs b/MP.Data/Services/TabDataService.cs index d73c08cc..fa9b90de 100644 --- a/MP.Data/Services/TabDataService.cs +++ b/MP.Data/Services/TabDataService.cs @@ -1182,14 +1182,14 @@ namespace MP.Data.Services return answ; } - /// - /// Fix ODL per macchine SLAVE - /// - /// - /// - /// - /// - public async Task OdlFixMachineSlave(string idxMacchina, int numDayPrev, int doInsert) + /// + /// Fix ODL per macchine SLAVE + /// + /// + /// + /// + /// + public async Task OdlFixMachineSlave(string idxMacchina, int numDayPrev, int doInsert) { bool answ = false; try @@ -1994,6 +1994,49 @@ namespace MP.Data.Services await FlushCache(Constants.redisMseKey); return answ; } + /// + /// Recupera un valore MSE x una macchina sub specifica + /// + /// + /// + /// + /// + public MappaStatoExpl MseGetSub(string idxMacc, string idxMacchSub, bool forceDb) + { + Stopwatch stopWatch = new Stopwatch(); + stopWatch.Start(); + MappaStatoExpl result = new MappaStatoExpl(); + // cerco in redis... + string currKey = $"{Constants.redisMseKeySingle}:{idxMacchSub}"; + RedisValue rawData = redisDb.StringGet(currKey); + if (rawData.HasValue && !forceDb) + { + result = JsonConvert.DeserializeObject($"{rawData}"); + stopWatch.Stop(); + TimeSpan ts = stopWatch.Elapsed; + Log.Debug($"Read from REDIS: {ts.TotalMilliseconds}ms"); + } + else + { + var rawResult = dbTabController.MseGetSub(idxMacc, idxMacchSub); + if (rawResult != null && rawResult.Count > 0) + { + result = rawResult.FirstOrDefault(); + } + // serializzp e salvo... + rawData = JsonConvert.SerializeObject(result); + redisDb.StringSet(currKey, rawData, UltraLongCache); + stopWatch.Stop(); + TimeSpan ts = stopWatch.Elapsed; + Log.Debug($"Read from DB: {ts.TotalMilliseconds}ms"); + } + if (result == null) + { + result = new MappaStatoExpl(); + } + return result; + } + /// /// Processa registrazione di un counter x una data macchina IOB From 7470e8a768bcab48703a9c5afec8344671e827f0 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 10 Nov 2023 19:26:51 +0100 Subject: [PATCH 002/100] Fix catena update ODL in doppia tavola --- MP-TAB-SERV/Components/MachineBlock.razor.cs | 10 +++++----- MP-TAB-SERV/Components/OdlMan.razor.cs | 4 ---- MP-TAB-SERV/MP-TAB-SERV.csproj | 2 +- MP-TAB-SERV/Pages/ODL.razor | 2 +- MP-TAB-SERV/Pages/ODL.razor.cs | 12 ++++-------- 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 +- 9 files changed, 15 insertions(+), 23 deletions(-) diff --git a/MP-TAB-SERV/Components/MachineBlock.razor.cs b/MP-TAB-SERV/Components/MachineBlock.razor.cs index a9723242..3ede46ee 100644 --- a/MP-TAB-SERV/Components/MachineBlock.razor.cs +++ b/MP-TAB-SERV/Components/MachineBlock.razor.cs @@ -164,11 +164,11 @@ namespace MP_TAB_SERV.Components protected override void OnParametersSet() { isLoading = RecMSE == null; - //// controllo SE avessi idxMacchSub --> rileggo! - //if (!string.IsNullOrEmpty(IdxMacchSub) && RecMSE != null) - //{ - // RecMSE = TabDServ.MseGetSub(RecMSE.IdxMacchina, IdxMacchSub, true); - //} + // controllo SE avessi idxMacchSub --> rileggo! + if (!string.IsNullOrEmpty(IdxMacchSub) && RecMSE != null) + { + RecMSE = TabDServ.MseGetSub(RecMSE.IdxMacchina, IdxMacchSub, true); + } setGaugeVals(); } diff --git a/MP-TAB-SERV/Components/OdlMan.razor.cs b/MP-TAB-SERV/Components/OdlMan.razor.cs index 20cff024..c166639a 100644 --- a/MP-TAB-SERV/Components/OdlMan.razor.cs +++ b/MP-TAB-SERV/Components/OdlMan.razor.cs @@ -790,13 +790,9 @@ namespace MP_TAB_SERV.Components protected async Task SetMacc(string selIdxMacc) { - isProcessing = true; - await Task.Delay(10); IdxMaccSel = selIdxMacc; await DoUpdate(); - isProcessing = false; await E_MachSel.InvokeAsync(selIdxMacc); - await Task.Delay(10); } protected async Task ToggleOdlDetail() diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index a7bdcc19..4fc13f95 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.1017 + 6.16.2311.1019 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Pages/ODL.razor b/MP-TAB-SERV/Pages/ODL.razor index 8f141d37..cea8d71f 100644 --- a/MP-TAB-SERV/Pages/ODL.razor +++ b/MP-TAB-SERV/Pages/ODL.razor @@ -7,6 +7,6 @@ } else { - + } diff --git a/MP-TAB-SERV/Pages/ODL.razor.cs b/MP-TAB-SERV/Pages/ODL.razor.cs index 016371db..fd99ee58 100644 --- a/MP-TAB-SERV/Pages/ODL.razor.cs +++ b/MP-TAB-SERV/Pages/ODL.razor.cs @@ -50,15 +50,11 @@ namespace MP_TAB_SERV.Pages } } - protected async Task SetMacc(string selIdxMacc) + private string IdxMaccSubSel = ""; + + protected void SetMacc(string selIdxMacc) { - CurrMSE = null; - await Task.Delay(1); - IdxMacc = selIdxMacc; - await MsgServ.IdxMaccSet(selIdxMacc); - // recupero MSE macchina.... - CurrMSE = await MsgServ.GetMachineMse(IdxMacc); - await InvokeAsync(StateHasChanged); + IdxMaccSubSel = selIdxMacc; } #endregion Protected Methods diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index dcb3afed..84db16e8 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.1017

    +

    Versione: 6.16.2311.1019


    Note di rilascio:
    • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 8b8eb08c..0c7d7816 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1017 +6.16.2311.1019 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index 998f69ad..d91e2e95 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1017 + 6.16.2311.1019 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP.Data/Controllers/MpTabController.cs b/MP.Data/Controllers/MpTabController.cs index 6224c7ac..50a5b34f 100644 --- a/MP.Data/Controllers/MpTabController.cs +++ b/MP.Data/Controllers/MpTabController.cs @@ -782,7 +782,7 @@ namespace MP.Data.Controllers var IdxMacchSub = new SqlParameter("@IdxMacchSub", idxMacchSub); dbResult = dbCtx .DbSetMSE - .FromSqlRaw("EXEC stp_ODL_fineProd @IdxMacchina, @IdxMacchSub", IdxMacc, IdxMacchSub) + .FromSqlRaw("EXEC stp_MSE_getByIdxMacchAndSub @IdxMacchina, @IdxMacchSub", IdxMacc, IdxMacchSub) .AsNoTracking() .ToList(); } From b6752983a2da1f2db6bdf0f1692990cfb4589dc1 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Mon, 13 Nov 2023 08:57:55 +0100 Subject: [PATCH 003/100] ok pagina user prefs --- MP-TAB-SERV/Pages/User.razor | 72 +++++++++++++++++++----------------- 1 file changed, 38 insertions(+), 34 deletions(-) diff --git a/MP-TAB-SERV/Pages/User.razor b/MP-TAB-SERV/Pages/User.razor index bf09134d..9662f576 100644 --- a/MP-TAB-SERV/Pages/User.razor +++ b/MP-TAB-SERV/Pages/User.razor @@ -14,15 +14,50 @@
      }
      -
      + @*
      USER DATA
      -
      +
      *@
      +
      + Preferenze +
      +
      +
        +
      • +
        Modalità di inserimento del tempo ciclo
        +
        +
        + + +
        +
        +
      • +
      • +
        Lingua
        + +
      • +
      • +
        Modalità di visualizzazione delle macchine in 'Mappa Stato'
        +
        +
        + + +
        +
        +
      • +
      +
      +
      + User Data +
      • @@ -43,38 +78,7 @@
      -
      - Preferenze -
      -
      -
        -
      • -
        Modalità di inserimento del tempo ciclo
        -
        -
        - - -
        -
        -
      • -
      • -
        Lingua
        - -
      • -
      • -
        Modalità di visualizzazione delle macchine in 'Mappa Stato'
        -
        -
        - - -
        -
        -
      • -
      -
      +
      + +
      +
      +
      + +
      +
      +
      +
      \ No newline at end of file diff --git a/MP-TAB-SERV/Components/CmpTop.razor.cs b/MP-TAB-SERV/Components/CmpTop.razor.cs new file mode 100644 index 00000000..6a1cf5b8 --- /dev/null +++ b/MP-TAB-SERV/Components/CmpTop.razor.cs @@ -0,0 +1,127 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Components; +using System.Net.Http; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Components.Authorization; +using Microsoft.AspNetCore.Components.Forms; +using Microsoft.AspNetCore.Components.Routing; +using Microsoft.AspNetCore.Components.Web; +using Microsoft.AspNetCore.Components.Web.Virtualization; +using Microsoft.JSInterop; +using MP_TAB_SERV; +using MP_TAB_SERV.Shared; +using MP_TAB_SERV.Components; +using MP.Data; +using MP.Data.DatabaseModels; +using MP.Data.DTO; +using MP.Data.Services; +using Newtonsoft.Json; +using NLog; +using EgwCoreLib.Razor; +using MP_TAB_SERV.Pages; +using NLog.Fluent; +using System.Diagnostics; + +namespace MP_TAB_SERV.Components +{ + public partial class CmpTop + { + [Inject] + protected ListSelectDataSrv MDataService { get; set; } = null!; + + [Inject] + protected MessageService MsgServ { get; set; } = null!; + + [Inject] + protected SharedMemService MStor { get; set; } = null!; + + [Inject] + protected NavigationManager NavMan { get; set; } = null!; + + [Inject] + protected TabDataService TDataService { get; set; } = null!; + + [Parameter] + public List CurrMenuItems { get; set; } = new List(); + + + protected string ResetClass = "btn-primary"; + + protected async Task ReloadMemStor() + { + // in primis svuoto... + MStor.ClearCache(); + // rileggo link + var allData = await MDataService.ListLinkAll(); + MStor.SetupMenu(allData); + // fix config... + var allConf = await MDataService.ConfigGetAll(); + MStor.SetConfig(allConf); + // fix MSFD... + var allMSFD = await TDataService.VMSFDGetAll(); + MStor.SetMsfd(allMSFD); + // fix slave + var macSlave = await TDataService.Macchine2Slave(); + MStor.SetM2S(macSlave); + + // fix elenco eventi + var allEvents = await TDataService.AnagEventiGetAll(); + MStor.SetEventi(allEvents); + // fix elenco stati + var allStati = await TDataService.AnaStatiGetAll(); + MStor.SetStati(allStati); + // non da farsi globalmente // fix macchine var allMach = await + // MDataService.MacchineByMatrOper(0); MStor.DictMacchine = allMach.ToDictionary(x => + // x.IdxMacchina, x => $"{x.IdxMacchina} | {x.Nome}"); + + // fix vocabolario + var allVoc = TDataService.VocabolarioGetAll(); + MStor.SetVocab(allVoc); + + // resetto il tabDServ + await TDataService.FlushCache(); + // ricarica la config... + TDataService.SetupConfig(); + } + + protected async Task ForceReload() + { + Stopwatch sw = new Stopwatch(); + sw.Start(); + Log.Info("Start ForceReload"); + ResetClass = "btn-warning"; + await InvokeAsync(StateHasChanged); + // reset cache varie + await MsgServ.ClearLocalStor(); + await MsgServ.ClearSessionStor(); + await MDataService.FlushCache(); + // reload MStor + await ReloadMemStor(); + // calcolo tempo esecuzione + sw.Stop(); + int delta = 500 - (int)sw.ElapsedMilliseconds; + delta = delta > 0 ? delta : 50; + await Task.Delay(delta); + ResetClass = "btn-primary"; + // await InvokeAsync(StateHasChanged); + Log.Info($"ForceReload completed in {sw.ElapsedMilliseconds}ms"); + // ricarica pagina! + NavMan.NavigateTo("/", true); + } + + protected override async Task OnInitializedAsync() + { + await Task.Delay(1); + if (MsgServ.RigaOper == null) + { + if (!NavMan.Uri.Contains("regnewdevice")) + { + NavMan.NavigateTo("/regnewdevice", true); + } + } + } + } +} \ No newline at end of file diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 4fc13f95..c62aca7e 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.1019 + 6.16.2311.1317 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Pages/RegNewDevice.razor b/MP-TAB-SERV/Pages/RegNewDevice.razor new file mode 100644 index 00000000..ead2ed88 --- /dev/null +++ b/MP-TAB-SERV/Pages/RegNewDevice.razor @@ -0,0 +1,56 @@ +@page "/regnewdevice" + +
      + QR-Scan USER LOGIN +
      +
      +
      + + + +
      +
      + + + + +@if (oprsList.Count > 0) +{ +
      + Selezionare un operatore + +
      +
      + User Auth Key + +
      +} + +
      +
      + +
      +
      + +
      +
      + +@if(rigaOpr != null) +{ +
      @($"{MsgServ.UserAuthKey} {MsgServ.MatrOpr}")
      +} + +@*@if (done) +{ +
      Logged In
      +} +else +{ +
      Not logged in
      +}*@ + diff --git a/MP-TAB-SERV/Pages/RegNewDevice.razor.cs b/MP-TAB-SERV/Pages/RegNewDevice.razor.cs new file mode 100644 index 00000000..32a76e51 --- /dev/null +++ b/MP-TAB-SERV/Pages/RegNewDevice.razor.cs @@ -0,0 +1,81 @@ +using Microsoft.AspNetCore.Components; +//using MongoDB.Bson.IO; +using MP.Data.DatabaseModels; +using MP.Data.DTO; +using MP.Data.Services; +using Newtonsoft.Json; + +namespace MP_TAB_SERV.Pages +{ + public partial class RegNewDevice + { + [Inject] + protected TabDataService TDService { get; set; } = null!; + + [Inject] + protected MessageService MsgServ { get; set; } = null!; + + [Inject] + protected NavigationManager NavMan { get; set; } = null!; + + protected List oprsList { get; set; } = new List(); + + protected override async Task OnInitializedAsync() + { + await Task.Delay(1); + + //var currOpr = await TDService.LoginOperatore(matrOpr, authKey); + //if (currOpr.MatrOpr != 0) + //{ + // MsgServ.RigaOper = currOpr; + //} + TDService.ConfigGetVal("cookieDayExpire", ref expDays); + + expDT = DateTime.Now.AddDays(expDays); + + CurrOprTknLS = await MsgServ.getCurrOperDtoAsync(); + CurrOprTknRedis = await TDService.OperatoreGetRedis(CurrOprTknLS); + + if (CurrOprTknRedis != "") + { + NavMan.NavigateTo("status-map"); + } + + //if (MsgServ.RigaOper != null) + //{ + // NavMan.NavigateTo("status-map", true); + //} + oprsList = await TDService.ElencoOperatori(); + } + + protected int expDays = 1; + protected int matrOpr { get; set; } = 0; + protected string authKey { get; set; } = ""; + protected AnagOperatoriModel rigaOpr { get; set; } = null!; + protected string CurrOprTknLS { get; set; } = null!; + protected string CurrOprTknRedis { get; set; } = null!; + + protected DateTime expDT { get; set; } = DateTime.Now; + protected async Task logIn() + { + await Task.Delay(1); + rigaOpr = await TDService.LoginOperatore(matrOpr, authKey); + if (rigaOpr != null) + { + userTknDTO newUserTkn = new userTknDTO() + { + currOpr = rigaOpr, + expTime = expDT + }; + + var jsonTkn = JsonConvert.SerializeObject(newUserTkn); + string hash = TDService.EncriptData(jsonTkn); + MsgServ.RigaOper = rigaOpr; + await MsgServ.setCurrOperDtoAsync(hash); + await TDService.OperatoreSetRedis(hash); + NavMan.NavigateTo("status-map"); + } + //StateHasChanged(); + } + } +} \ No newline at end of file diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 84db16e8..6b4a3545 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.1019

      +

      Versione: 6.16.2311.1317


      Note di rilascio:
      • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 0c7d7816..9d59cd72 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1019 +6.16.2311.1317 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index d91e2e95..c744469f 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1019 + 6.16.2311.1317 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP-TAB-SERV/Shared/MainLayout.razor b/MP-TAB-SERV/Shared/MainLayout.razor index d18e77a9..8a029f91 100644 --- a/MP-TAB-SERV/Shared/MainLayout.razor +++ b/MP-TAB-SERV/Shared/MainLayout.razor @@ -7,7 +7,7 @@
        -
        + @*
        @@ -30,7 +30,10 @@
        -
        + *@ + + +
        diff --git a/MP-TAB-SERV/Shared/MainLayout.razor.cs b/MP-TAB-SERV/Shared/MainLayout.razor.cs index c20d5162..0dc08eec 100644 --- a/MP-TAB-SERV/Shared/MainLayout.razor.cs +++ b/MP-TAB-SERV/Shared/MainLayout.razor.cs @@ -55,31 +55,6 @@ namespace MP_TAB_SERV.Shared #region Protected Methods - protected async Task ForceReload() - { - Stopwatch sw = new Stopwatch(); - sw.Start(); - Log.Info("Start ForceReload"); - ResetClass = "btn-warning"; - await InvokeAsync(StateHasChanged); - // reset cache varie - await MServ.ClearLocalStor(); - await MServ.ClearSessionStor(); - await MDataService.FlushCache(); - // reload MStor - await ReloadMemStor(); - // calcolo tempo esecuzione - sw.Stop(); - int delta = 500 - (int)sw.ElapsedMilliseconds; - delta = delta > 0 ? delta : 50; - await Task.Delay(delta); - ResetClass = "btn-primary"; - // await InvokeAsync(StateHasChanged); - Log.Info($"ForceReload completed in {sw.ElapsedMilliseconds}ms"); - // ricarica pagina! - NavMan.NavigateTo("/", true); - } - /// /// Init struttura dati /// diff --git a/MP-TAB-SERV/Shared/MainLayout.razor.css b/MP-TAB-SERV/Shared/MainLayout.razor.css index 20fe1add..a80c3036 100644 --- a/MP-TAB-SERV/Shared/MainLayout.razor.css +++ b/MP-TAB-SERV/Shared/MainLayout.razor.css @@ -13,29 +13,7 @@ main { padding: 0 10px 0 0; } -.top-row { - background-color: #05173d; - /*border-bottom: 1px solid #d6d5d5;*/ - justify-content: flex-end; - height: 3.5rem; - display: flex; - align-items: center; -} - .top-row ::deep a, .top-row ::deep .btn-link { - white-space: nowrap; - /*margin-left: 1.5rem;*/ - text-decoration: none; - } - - .top-row ::deep a:hover, .top-row ::deep .btn-link:hover { - text-decoration: underline; - } - - .top-row ::deep a:first-child { - overflow: hidden; - text-overflow: ellipsis; - } @media (min-width: 640.98px) { .slideMen:not(.auth) { @@ -48,26 +26,6 @@ main { } - - -@media (max-width: 640.98px) { - .top-row:not(.auth) { - display: none; - } - - #mainBody { - width: 100%; - } - - .top-row.auth { - justify-content: space-between; - } - - .top-row ::deep a, .top-row ::deep .btn-link { - margin-left: 0; - } -} - @media (min-width: 641px) { .page { flex-direction: row; @@ -82,22 +40,6 @@ main { } } -.top-row { - position: sticky; - top: 0; - z-index: 1; -} - - .top-row.auth ::deep a:first-child { - flex: 1; - text-align: right; - width: 0; - } - -.top-row, article { - padding-left: 1rem !important; - padding-right: .5rem !important; -} #blazor-error-ui { background: lightyellow; diff --git a/MP-TAB-SERV/wwwroot/css/site.css b/MP-TAB-SERV/wwwroot/css/site.css index 924a71e9..508a0b26 100644 --- a/MP-TAB-SERV/wwwroot/css/site.css +++ b/MP-TAB-SERV/wwwroot/css/site.css @@ -101,4 +101,56 @@ a, } .blazor-error-boundary::after { content: "An error has occurred."; +} +.top-row { + background-color: #05173d; + /*border-bottom: 1px solid #d6d5d5;*/ + justify-content: flex-end; + height: 3.5rem; + display: flex; + align-items: center; +} +.top-row ::deep a, +.top-row ::deep .btn-link { + white-space: nowrap; + /*margin-left: 1.5rem;*/ + text-decoration: none; +} +.top-row ::deep a:hover, +.top-row ::deep .btn-link:hover { + text-decoration: underline; +} +.top-row ::deep a:first-child { + overflow: hidden; + text-overflow: ellipsis; +} +@media (max-width: 640.98px) { + .top-row:not(.auth) { + display: none; + } + #mainBody { + width: 100%; + } + .top-row.auth { + justify-content: space-between; + } + .top-row ::deep a, + .top-row ::deep .btn-link { + margin-left: 0; + } +} +.top-row { + position: sticky; + top: 0; + z-index: 1; +} +.top-row.auth ::deep a:first-child { + flex: 1; + text-align: right; + width: 0; +} +.top-row, +article { + padding-left: 1rem !important; + padding-right: 0.5rem !important; } \ No newline at end of file diff --git a/MP-TAB-SERV/wwwroot/css/site.less b/MP-TAB-SERV/wwwroot/css/site.less index f1f08aa8..3623ea46 100644 --- a/MP-TAB-SERV/wwwroot/css/site.less +++ b/MP-TAB-SERV/wwwroot/css/site.less @@ -114,3 +114,63 @@ html, body { .blazor-error-boundary::after { content: "An error has occurred." } + +.top-row { + background-color: #05173d; + /*border-bottom: 1px solid #d6d5d5;*/ + justify-content: flex-end; + height: 3.5rem; + display: flex; + align-items: center; +} + +.top-row ::deep a, .top-row ::deep .btn-link { + white-space: nowrap; + /*margin-left: 1.5rem;*/ + text-decoration: none; +} + +.top-row ::deep a:hover, .top-row ::deep .btn-link:hover { + text-decoration: underline; +} + +.top-row ::deep a:first-child { + overflow: hidden; + text-overflow: ellipsis; +} + + +@media (max-width: 640.98px) { + .top-row:not(.auth) { + display: none; + } + + #mainBody { + width: 100%; + } + + .top-row.auth { + justify-content: space-between; + } + + .top-row ::deep a, .top-row ::deep .btn-link { + margin-left: 0; + } +} + +.top-row { + position: sticky; + top: 0; + z-index: 1; +} + +.top-row.auth ::deep a:first-child { + flex: 1; + text-align: right; + width: 0; +} + +.top-row, article { + padding-left: 1rem !important; + padding-right: .5rem !important; +} \ No newline at end of file diff --git a/MP-TAB-SERV/wwwroot/css/site.min.css b/MP-TAB-SERV/wwwroot/css/site.min.css index 9ec2a048..c429c6c5 100644 --- a/MP-TAB-SERV/wwwroot/css/site.min.css +++ b/MP-TAB-SERV/wwwroot/css/site.min.css @@ -1 +1 @@ -@import url('open-iconic/font/css/open-iconic-bootstrap.min.css');html,body{font-family:'Open Sans Condensed',sans-serif;background-color:#151321;color:#ededed;}.cardObj{border-radius:.375rem;background:linear-gradient(121deg,rgba(255,255,255,.2) -.71%,rgba(255,255,255,.05) 97.66%);box-shadow:0 4px 24px -1px rgba(0,0,0,.25);flex-shrink:0;}.cardObjNoBL{border-radius:.375rem 0 0 .375rem;background:linear-gradient(121deg,rgba(255,255,255,.2) -.71%,rgba(255,255,255,.05) 97.66%);box-shadow:0 4px 24px -1px rgba(0,0,0,.25);flex-shrink:0;}.cardFullHeight{border-radius:.375rem;background:linear-gradient(121deg,rgba(255,255,255,.2) -.71%,rgba(255,255,255,.05) 97.66%);box-shadow:0 4px 24px -1px rgba(0,0,0,.25);flex-shrink:0;height:100%;}.longStopListNotes{height:100%;}@media(max-width:640.98px){.longStopListNotes{max-height:120px;}}.borderStd{border-radius:.375rem;}.table-dark{--bs-table-color:#fff;--bs-table-bg:transparent;--bs-table-border-color:#4d5154;--bs-table-striped-bg:#2c3034;--bs-table-striped-color:#fff;--bs-table-active-bg:#373b3e;--bs-table-active-color:#fff;--bs-table-hover-bg:#323539;--bs-table-hover-color:#fff;color:var(--bs-table-color);border-color:var(--bs-table-border-color);}h1:focus{outline:0;}a,.btn-link{color:#0071c1;}.btn-primary{color:#fff;background-color:#1b6ec2;border-color:#1861ac;}.content{padding-top:1.1rem;}.valid.modified:not([type=checkbox]){outline:1px solid #26b050;}.invalid{outline:1px solid #f00;}.validation-message{color:#f00;}#blazor-error-ui{background:#ffffe0;bottom:0;box-shadow:0 -1px 2px rgba(0,0,0,.2);display:none;left:0;padding:.6rem 1.25rem .7rem 1.25rem;position:fixed;width:100%;z-index:1000;}#blazor-error-ui .dismiss{cursor:pointer;position:absolute;right:.75rem;top:.5rem;}.blazor-error-boundary{background:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem,#b32121;padding:1rem 1rem 1rem 3.7rem;color:#fff;}.blazor-error-boundary::after{content:"An error has occurred.";} \ No newline at end of file +@import url('open-iconic/font/css/open-iconic-bootstrap.min.css');html,body{font-family:'Open Sans Condensed',sans-serif;background-color:#151321;color:#ededed;}.cardObj{border-radius:.375rem;background:linear-gradient(121deg,rgba(255,255,255,.2) -.71%,rgba(255,255,255,.05) 97.66%);box-shadow:0 4px 24px -1px rgba(0,0,0,.25);flex-shrink:0;}.cardObjNoBL{border-radius:.375rem 0 0 .375rem;background:linear-gradient(121deg,rgba(255,255,255,.2) -.71%,rgba(255,255,255,.05) 97.66%);box-shadow:0 4px 24px -1px rgba(0,0,0,.25);flex-shrink:0;}.cardFullHeight{border-radius:.375rem;background:linear-gradient(121deg,rgba(255,255,255,.2) -.71%,rgba(255,255,255,.05) 97.66%);box-shadow:0 4px 24px -1px rgba(0,0,0,.25);flex-shrink:0;height:100%;}.longStopListNotes{height:100%;}@media(max-width:640.98px){.longStopListNotes{max-height:120px;}}.borderStd{border-radius:.375rem;}.table-dark{--bs-table-color:#fff;--bs-table-bg:transparent;--bs-table-border-color:#4d5154;--bs-table-striped-bg:#2c3034;--bs-table-striped-color:#fff;--bs-table-active-bg:#373b3e;--bs-table-active-color:#fff;--bs-table-hover-bg:#323539;--bs-table-hover-color:#fff;color:var(--bs-table-color);border-color:var(--bs-table-border-color);}h1:focus{outline:0;}a,.btn-link{color:#0071c1;}.btn-primary{color:#fff;background-color:#1b6ec2;border-color:#1861ac;}.content{padding-top:1.1rem;}.valid.modified:not([type=checkbox]){outline:1px solid #26b050;}.invalid{outline:1px solid #f00;}.validation-message{color:#f00;}#blazor-error-ui{background:#ffffe0;bottom:0;box-shadow:0 -1px 2px rgba(0,0,0,.2);display:none;left:0;padding:.6rem 1.25rem .7rem 1.25rem;position:fixed;width:100%;z-index:1000;}#blazor-error-ui .dismiss{cursor:pointer;position:absolute;right:.75rem;top:.5rem;}.blazor-error-boundary{background:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem,#b32121;padding:1rem 1rem 1rem 3.7rem;color:#fff;}.blazor-error-boundary::after{content:"An error has occurred.";}.top-row{background-color:#05173d;justify-content:flex-end;height:3.5rem;display:flex;align-items:center;}.top-row ::deep a,.top-row ::deep .btn-link{white-space:nowrap;text-decoration:none;}.top-row ::deep a:hover,.top-row ::deep .btn-link:hover{text-decoration:underline;}.top-row ::deep a:first-child{overflow:hidden;text-overflow:ellipsis;}@media(max-width:640.98px){.top-row:not(.auth){display:none;}#mainBody{width:100%;}.top-row.auth{justify-content:space-between;}.top-row ::deep a,.top-row ::deep .btn-link{margin-left:0;}}.top-row{position:sticky;top:0;z-index:1;}.top-row.auth ::deep a:first-child{flex:1;text-align:right;width:0;}.top-row,article{padding-left:1rem!important;padding-right:.5rem!important;} \ No newline at end of file diff --git a/MP.Data/Controllers/MpTabController.cs b/MP.Data/Controllers/MpTabController.cs index 50a5b34f..7b30d069 100644 --- a/MP.Data/Controllers/MpTabController.cs +++ b/MP.Data/Controllers/MpTabController.cs @@ -54,6 +54,51 @@ namespace MP.Data.Controllers return dbResult; } + + /// + /// Elenco operatori + /// + /// + public List ElencoOperatori() + { + List dbResult = new List(); + using (var dbCtx = new MoonProContext(_configuration)) + { + dbResult = dbCtx + .DbOperatori + .Where(s => s.MatrOpr > 0) + .AsNoTracking() + .OrderBy(x => x.MatrOpr) + .ToList(); + } + return dbResult; + } + + /// + /// login operatori + /// + /// /// + /// /// + /// + public AnagOperatoriModel LoginOperatore(int matrOpr, string authKey) + { + AnagOperatoriModel dbResult = null; + AnagOperatoriModel answ = new AnagOperatoriModel(); + using (var dbCtx = new MoonProContext(_configuration)) + { + dbResult = dbCtx + .DbOperatori + .Where(s => (s.MatrOpr > 0) && (s.MatrOpr == matrOpr) && (s.authKey == authKey)) + .AsNoTracking() + .FirstOrDefault(); + if (dbResult != null) + { + answ = dbResult; + } + } + return answ; + } + /// /// Registrato ACK allarme /// diff --git a/MP.Data/DTO/userTknDTO.cs b/MP.Data/DTO/userTknDTO.cs new file mode 100644 index 00000000..bc9a8db5 --- /dev/null +++ b/MP.Data/DTO/userTknDTO.cs @@ -0,0 +1,15 @@ +using MP.Data.DatabaseModels; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace MP.Data.DTO +{ + public class userTknDTO + { + public AnagOperatoriModel currOpr { get; set; } = null; + public DateTime expTime { get; set; } = DateTime.Now; + } +} diff --git a/MP.Data/Services/MessageService.cs b/MP.Data/Services/MessageService.cs index 6d751191..faeb93c4 100644 --- a/MP.Data/Services/MessageService.cs +++ b/MP.Data/Services/MessageService.cs @@ -2,6 +2,7 @@ using Blazored.SessionStorage; using Microsoft.Extensions.Configuration; using MP.Data.DatabaseModels; +using MP.Data.DTO; using Newtonsoft.Json; using NLog; using StackExchange.Redis; @@ -339,6 +340,7 @@ namespace MP.Data.Services return answ; } + /// /// Recupero singola preferenza utente /// @@ -482,6 +484,35 @@ namespace MP.Data.Services return fatto; } + + /// + /// Restituisce il record OperatoreDTO da localstorage + /// + /// + public async Task getCurrOperDtoAsync() + { + string answ = ""; + var result = await localStorage.GetItemAsync("currTkn"); + if (result != null) + { + //var data = JsonConvert.DeserializeObject(result); + answ = result; + } + return answ; + } + + /// + /// scrive il record OperatoreDTO nel localstorage + /// + /// + public async Task setCurrOperDtoAsync(string currTkn) + { + bool answ = false; + await localStorage.SetItemAsync("currTkn", currTkn); + answ = true; + return answ; + } + #endregion Private Methods #if false diff --git a/MP.Data/Services/TabDataService.cs b/MP.Data/Services/TabDataService.cs index fa9b90de..24c95f37 100644 --- a/MP.Data/Services/TabDataService.cs +++ b/MP.Data/Services/TabDataService.cs @@ -1,4 +1,5 @@ -using Microsoft.EntityFrameworkCore; +using EgwCoreLib.Utils; +using Microsoft.EntityFrameworkCore; using Microsoft.Extensions.Configuration; using MP.Data.DatabaseModels; using MP.Data.DTO; @@ -176,6 +177,41 @@ namespace MP.Data.Services return result; } + + /// + /// Elenco operatori + /// + /// + public async Task> ElencoOperatori() + { + string source = "DB"; + Stopwatch sw = new Stopwatch(); + sw.Start(); + List? result = new List(); + // cerco in redis... + string currKey = $"{redisBaseKey}:ElencoOpr"; + RedisValue rawData = await redisDb.StringGetAsync(currKey); + if (rawData.HasValue) + { + result = JsonConvert.DeserializeObject>($"{rawData}"); + source = "REDIS"; + } + else + { + result = dbTabController.ElencoOperatori(); + // serializzo e salvo... + rawData = JsonConvert.SerializeObject(result); + await redisDb.StringSetAsync(currKey, rawData, UltraLongCache); + } + if (result == null) + { + result = new List(); + } + sw.Stop(); + Log.Debug($"ElencoOperatori | {source} | {sw.Elapsed.TotalMilliseconds}ms"); + return result; + } + /// /// Registrato ACK allarme /// @@ -189,6 +225,128 @@ namespace MP.Data.Services return answ; } + public string EncriptData(string rawData) + { + return SteamCrypto.EncryptString(rawData, passPhrase); + } + public string DeriptData(string encData) + { + return SteamCrypto.DecryptString(encData, passPhrase); + } + + protected const string passPhrase = "7871D817-C71F-4DFC-BF12-00A95BE507B5"; + + protected int expDays = 1; + + protected void setExpDays() + { + ConfigGetVal("cookieDayExpire", ref expDays); + } + + /// + /// Log in operatore + /// + /// matricola operatore + /// Auth Key + /// + public async Task LoginOperatore(int matrOpr, string authKey) + { + string source = "DB"; + Stopwatch sw = new Stopwatch(); + sw.Start(); + AnagOperatoriModel answ = null; + // cerco in redis... + string currKey = $"{redisBaseKey}:CurrOpr:{matrOpr}"; + RedisValue rawData = await redisDb.StringGetAsync(currKey); + if (rawData.HasValue) + { + //var encrData = SteamCrypto.DecryptString(rawData, passPhrase); + answ = JsonConvert.DeserializeObject($"{rawData}"); + source = "REDIS"; + } + else + { + answ = dbTabController.LoginOperatore(matrOpr, authKey); + // serializzo e salvo... + rawData = JsonConvert.SerializeObject(answ); + //var encrData = SteamCrypto.EncryptString(rawData, passPhrase); + await redisDb.StringSetAsync(currKey, rawData, ConfigCache); + } + if (answ == null) + { + answ = new AnagOperatoriModel(); + } + sw.Stop(); + Log.Debug($"LoginOperatore | {source} | {sw.Elapsed.TotalMilliseconds}ms"); + await Task.Delay(1); + return answ; + } + + /// + /// Scrive l'hash dell'oggetto curr opr + /// + /// + /// + public async Task OperatoreGetRedis(string currOpr) + { + string source = "REDIS"; + Stopwatch sw = new Stopwatch(); + sw.Start(); + string answ = ""; + // cerco in redis... + string currKey = $"{redisBaseKey}:CurrOpr:{currOpr}"; + RedisValue rawData = await redisDb.StringGetAsync(currKey); + if (rawData.HasValue) + { + //var encrData = SteamCrypto.DecryptString(rawData, passPhrase); + answ = JsonConvert.DeserializeObject(rawData); + } + if (answ == null) + { + answ = ""; + } + sw.Stop(); + Log.Debug($"OperatoreGetRedis | {source} | {sw.Elapsed.TotalMilliseconds}ms"); + await Task.Delay(1); + return answ; + } + /// + /// legge l'hash dell'oggetto curr opr + /// + /// + /// + public async Task OperatoreSetRedis(string currOpr) + { + string source = "REDIS"; + Stopwatch sw = new Stopwatch(); + sw.Start(); + string answ = ""; + // cerco in redis... + string currKey = $"{redisBaseKey}:CurrOpr:{currOpr}"; + //RedisValue rawData = await redisDb.StringGetAsync(currKey); + // serializzo e salvo... + //rawData = JsonConvert.SerializeObject(currOpr); + answ = currOpr; + //var encrData = SteamCrypto.EncryptString(rawData, passPhrase); + await redisDb.StringSetAsync(currKey, currOpr, ConfigCache); + if (answ == null) + { + answ = ""; + } + sw.Stop(); + Log.Debug($"OperatoreSetRedis | {source} | {sw.Elapsed.TotalMilliseconds}ms"); + await Task.Delay(1); + return answ; + } + + /// + /// Durata cache data dal valore in config + /// + protected TimeSpan ConfigCache + { + get => TimeSpan.FromDays(expDays); + } + /// /// Registrato ACK allarme /// From 2516f4943e1cc36f51456708bd408b6e3fe8ce1c Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Mon, 13 Nov 2023 17:53:34 +0100 Subject: [PATCH 005/100] Update gestione ODL su doppia tavola --- MP-TAB-SERV/Components/OdlMan.razor.cs | 52 +++++++++++++++------ MP-TAB-SERV/Components/ProdConfirm.razor.cs | 8 +++- MP-TAB-SERV/MP-TAB-SERV.csproj | 2 +- MP-TAB-SERV/Pages/MachineDetail.razor | 4 +- MP-TAB-SERV/Pages/MachineDetail.razor.cs | 7 ++- MP-TAB-SERV/Pages/ODL.razor.cs | 8 +++- MP-TAB-SERV/Resources/ChangeLog.html | 2 +- MP-TAB-SERV/Resources/VersNum.txt | 2 +- MP-TAB-SERV/Resources/manifest.xml | 2 +- MP.Data/Services/TabDataService.cs | 9 ++-- 10 files changed, 68 insertions(+), 28 deletions(-) diff --git a/MP-TAB-SERV/Components/OdlMan.razor.cs b/MP-TAB-SERV/Components/OdlMan.razor.cs index c166639a..9d63c85b 100644 --- a/MP-TAB-SERV/Components/OdlMan.razor.cs +++ b/MP-TAB-SERV/Components/OdlMan.razor.cs @@ -14,6 +14,9 @@ namespace MP_TAB_SERV.Components { #region Public Properties + [Parameter] + public EventCallback E_MachSel { get; set; } + /// /// Post update restituisco nuova lista dati /// @@ -200,7 +203,7 @@ namespace MP_TAB_SERV.Components await advStep(currStep); isProcessing = true; // chiamo stored x riprendere ODL (toglie data chiusura...) - var rowRes = TabDServ.OdlReopenOdlMacc(IdxMaccSel); + var rowRes = await TabDServ.OdlReopenOdlMacc(IdxMaccSel); if (rowRes != null && rowRes.IdxOdl > 0) { // messaggio utente @@ -367,11 +370,10 @@ namespace MP_TAB_SERV.Components { TimeSpan estDur = TimeSpan.FromMinutes((double)tcRichAttr * currPodl.NumPezzi); string stima = estDur.TotalHours > 1 ? $"{estDur.TotalHours:N1} ore" : $"{estDur.TotalMinutes:N1} min"; + if (!await JSRuntime.InvokeAsync("confirm", $"PODL: {currPodl.IdxPromessa}{Environment.NewLine}Art: [{currPodl.CodArticolo}] {currPodl.DescArticolo}{Environment.NewLine}Pezzi: {currPodl.NumPezzi:N0} * TCiclo: {tcRichAttr:N3}min{Environment.NewLine}Tempo stimato: {stima}{Environment.NewLine}{Environment.NewLine}Confermi inizio della fase di attrezzaggio?")) return; - //if (!await JSRuntime.InvokeAsync("confirm", $"Confermi inizio della fase di attrezzaggio per l'articolo [{currPodl.CodArticolo}] {currPodl.DescArticolo}?")) - // return; /*************************************************** * comprende gestione machineSlave x fix ODL master --> slave * @@ -419,6 +421,11 @@ namespace MP_TAB_SERV.Components } } await advStep(currStep++); + // se fosse multi cambio dati di promODL x successivo setup... + if (isMulti) + { + currPodl.IdxMacchina = IdxMaccSel; + } // 2018.07.24 verifico se devo lavorare come ODL classico o come RPO (Richiesta / // Promessa / ODL) if (enableRPO) @@ -755,9 +762,6 @@ namespace MP_TAB_SERV.Components } } - [Parameter] - public EventCallback E_MachSel { get; set; } - protected async Task SendWarnTcChangeReq(int idxOdl, decimal tcAss, decimal tcRich) { // carico altri parametri email... @@ -790,8 +794,15 @@ namespace MP_TAB_SERV.Components protected async Task SetMacc(string selIdxMacc) { + // imposto macchina IdxMaccSel = selIdxMacc; + // recupero dati + RecMSE = TabDServ.MseGetSub(IdxMaccParent, selIdxMacc, true); await DoUpdate(); + if (showOdlDetail) + { + await ReloadXDL(true); + } await E_MachSel.InvokeAsync(selIdxMacc); } @@ -932,21 +943,36 @@ namespace MP_TAB_SERV.Components ///
    private int IdxOdl { - get => RecMSE != null ? RecMSE.IdxOdl ?? 0 : 0; + get + { + int answ = 0; + var pUpd = Task.Run(async () => + { + var tabOdl = await TabDServ.OdlCurrByMacc(IdxMaccSel, false); + answ = tabOdl.IdxOdl; + }); + pUpd.Wait(); + return answ; + } } + #if false + { + get => RecMSE != null ? RecMSE.IdxOdl ?? 0 : 0; + } +#endif - /// - /// Valore calcolato key ODL altra tavola attivo... - /// - private int IdxOdlAltra + /// + /// Valore calcolato key ODL altra tavola attivo... + /// + private int IdxOdlAltra { get { int answ = 0; var pUpd = Task.Run(async () => { - var tabOdlAltra = await TabDServ.OdlCurrByMacc(idxMaccAltraTav, false); - answ = tabOdlAltra.IdxOdl; + var tabOdl = await TabDServ.OdlCurrByMacc(idxMaccAltraTav, false); + answ = tabOdl.IdxOdl; }); pUpd.Wait(); return answ; diff --git a/MP-TAB-SERV/Components/ProdConfirm.razor.cs b/MP-TAB-SERV/Components/ProdConfirm.razor.cs index b9867dc0..c226464e 100644 --- a/MP-TAB-SERV/Components/ProdConfirm.razor.cs +++ b/MP-TAB-SERV/Components/ProdConfirm.razor.cs @@ -14,6 +14,9 @@ namespace MP_TAB_SERV.Components [Parameter] public EventCallback E_inserting { get; set; } + [Parameter] + public EventCallback E_MachSel { get; set; } + /// /// registrato nuovo valore /// @@ -196,11 +199,12 @@ namespace MP_TAB_SERV.Components protected async Task SetMacc(string selIdxMacc) { isProcessing = true; - await Task.Delay(10); + await Task.Delay(1); IdxMaccSel = selIdxMacc; await DoUpdate(); isProcessing = false; - await Task.Delay(10); + await Task.Delay(1); + await E_MachSel.InvokeAsync(selIdxMacc); } /// diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 4fc13f95..c62aca7e 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.1019 + 6.16.2311.1317 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Pages/MachineDetail.razor b/MP-TAB-SERV/Pages/MachineDetail.razor index ecda23b2..fd965bef 100644 --- a/MP-TAB-SERV/Pages/MachineDetail.razor +++ b/MP-TAB-SERV/Pages/MachineDetail.razor @@ -8,7 +8,7 @@ } else { - - + + } diff --git a/MP-TAB-SERV/Pages/MachineDetail.razor.cs b/MP-TAB-SERV/Pages/MachineDetail.razor.cs index c5e36643..67275899 100644 --- a/MP-TAB-SERV/Pages/MachineDetail.razor.cs +++ b/MP-TAB-SERV/Pages/MachineDetail.razor.cs @@ -61,14 +61,19 @@ namespace MP_TAB_SERV.Pages } } + protected void SetMacc(string selIdxMacc) + { + IdxMaccSubSel = selIdxMacc; + } + #endregion Protected Methods #region Private Fields private static Logger Log = LogManager.GetCurrentClassLogger(); - private bool enableMagLotti = false; private bool enableSchedaTecnica = false; + private string IdxMaccSubSel = ""; #endregion Private Fields diff --git a/MP-TAB-SERV/Pages/ODL.razor.cs b/MP-TAB-SERV/Pages/ODL.razor.cs index fd99ee58..487859a9 100644 --- a/MP-TAB-SERV/Pages/ODL.razor.cs +++ b/MP-TAB-SERV/Pages/ODL.razor.cs @@ -50,8 +50,6 @@ namespace MP_TAB_SERV.Pages } } - private string IdxMaccSubSel = ""; - protected void SetMacc(string selIdxMacc) { IdxMaccSubSel = selIdxMacc; @@ -59,6 +57,12 @@ namespace MP_TAB_SERV.Pages #endregion Protected Methods + #region Private Fields + + private string IdxMaccSubSel = ""; + + #endregion Private Fields + #region Private Methods private async Task ReloadData() diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 84db16e8..6b4a3545 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.1019

    +

    Versione: 6.16.2311.1317


    Note di rilascio:
    • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 0c7d7816..9d59cd72 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1019 +6.16.2311.1317 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index d91e2e95..c744469f 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1019 + 6.16.2311.1317 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP.Data/Services/TabDataService.cs b/MP.Data/Services/TabDataService.cs index fa9b90de..fc5b5e1a 100644 --- a/MP.Data/Services/TabDataService.cs +++ b/MP.Data/Services/TabDataService.cs @@ -1280,7 +1280,7 @@ namespace MP.Data.Services ///
    /// /// - public ODLModel OdlReopenOdlMacc(string idxMacchina) + public async Task OdlReopenOdlMacc(string idxMacchina) { string source = "DB"; Stopwatch sw = new Stopwatch(); @@ -1291,9 +1291,10 @@ namespace MP.Data.Services var results = dbTabController.OdlReopenOdlMacc(idxMacchina); // riordino result = results.FirstOrDefault(); - // serializzp e salvo... - var rawData = JsonConvert.SerializeObject(result); - redisDb.StringSet(currKey, rawData, UltraLongCache); + // svuoto cache + await FlushCache("ODL"); + await FlushCache("PODL"); + await FlushCache("VSODL"); if (result == null) { result = new ODLModel(); From 17a12c537cd2641af15e53488445f5883b5d8cf0 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Tue, 14 Nov 2023 10:37:48 +0100 Subject: [PATCH 006/100] ok lettura qr code --- MP-TAB-SERV/Components/CmpTop.razor.cs | 30 ++++-- MP-TAB-SERV/MP-TAB-SERV.csproj | 3 +- MP-TAB-SERV/Pages/RegNewDevice.razor | 7 ++ MP-TAB-SERV/Pages/RegNewDevice.razor.cs | 127 ++++++++++++++++++++++-- MP-TAB-SERV/Pages/_Layout.cshtml | 3 + MP-TAB-SERV/Resources/ChangeLog.html | 2 +- MP-TAB-SERV/Resources/VersNum.txt | 2 +- MP-TAB-SERV/Resources/manifest.xml | 2 +- MP.Data/Services/TabDataService.cs | 11 +- 9 files changed, 162 insertions(+), 25 deletions(-) diff --git a/MP-TAB-SERV/Components/CmpTop.razor.cs b/MP-TAB-SERV/Components/CmpTop.razor.cs index 6a1cf5b8..5d9c7944 100644 --- a/MP-TAB-SERV/Components/CmpTop.razor.cs +++ b/MP-TAB-SERV/Components/CmpTop.razor.cs @@ -42,7 +42,7 @@ namespace MP_TAB_SERV.Components protected NavigationManager NavMan { get; set; } = null!; [Inject] - protected TabDataService TDataService { get; set; } = null!; + protected TabDataService TDService { get; set; } = null!; [Parameter] public List CurrMenuItems { get; set; } = new List(); @@ -61,30 +61,30 @@ namespace MP_TAB_SERV.Components var allConf = await MDataService.ConfigGetAll(); MStor.SetConfig(allConf); // fix MSFD... - var allMSFD = await TDataService.VMSFDGetAll(); + var allMSFD = await TDService.VMSFDGetAll(); MStor.SetMsfd(allMSFD); // fix slave - var macSlave = await TDataService.Macchine2Slave(); + var macSlave = await TDService.Macchine2Slave(); MStor.SetM2S(macSlave); // fix elenco eventi - var allEvents = await TDataService.AnagEventiGetAll(); + var allEvents = await TDService.AnagEventiGetAll(); MStor.SetEventi(allEvents); // fix elenco stati - var allStati = await TDataService.AnaStatiGetAll(); + var allStati = await TDService.AnaStatiGetAll(); MStor.SetStati(allStati); // non da farsi globalmente // fix macchine var allMach = await // MDataService.MacchineByMatrOper(0); MStor.DictMacchine = allMach.ToDictionary(x => // x.IdxMacchina, x => $"{x.IdxMacchina} | {x.Nome}"); // fix vocabolario - var allVoc = TDataService.VocabolarioGetAll(); + var allVoc = TDService.VocabolarioGetAll(); MStor.SetVocab(allVoc); // resetto il tabDServ - await TDataService.FlushCache(); + await TDService.FlushCache(); // ricarica la config... - TDataService.SetupConfig(); + TDService.SetupConfig(); } protected async Task ForceReload() @@ -115,13 +115,25 @@ namespace MP_TAB_SERV.Components protected override async Task OnInitializedAsync() { await Task.Delay(1); - if (MsgServ.RigaOper == null) + CurrOprTknLS = await MsgServ.getCurrOperDtoAsync(); + var decodedUrl = Uri.UnescapeDataString(CurrOprTknLS); + CurrOprTknRedis = await TDService.OperatoreGetRedis(MsgServ.MatrOpr); + if (CurrOprTknRedis == "") { if (!NavMan.Uri.Contains("regnewdevice")) { NavMan.NavigateTo("/regnewdevice", true); } } + else if (CurrOprTknRedis != "") + { + if (!NavMan.Uri.Contains("status-map")) + { + NavMan.NavigateTo("/status-map", true); + } + } } + protected string CurrOprTknLS { get; set; } = null!; + protected string CurrOprTknRedis { get; set; } = null!; } } \ No newline at end of file diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index c62aca7e..5f5130e9 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.1317 + 6.16.2311.1410 enable MP_TAB_SERV @@ -20,6 +20,7 @@ + diff --git a/MP-TAB-SERV/Pages/RegNewDevice.razor b/MP-TAB-SERV/Pages/RegNewDevice.razor index ead2ed88..1f05bdf0 100644 --- a/MP-TAB-SERV/Pages/RegNewDevice.razor +++ b/MP-TAB-SERV/Pages/RegNewDevice.razor @@ -1,4 +1,5 @@ @page "/regnewdevice" +@using ZXingBlazor.Components
    QR-Scan USER LOGIN @@ -11,6 +12,12 @@
    + diff --git a/MP-TAB-SERV/Pages/RegNewDevice.razor.cs b/MP-TAB-SERV/Pages/RegNewDevice.razor.cs index 32a76e51..142f9f2a 100644 --- a/MP-TAB-SERV/Pages/RegNewDevice.razor.cs +++ b/MP-TAB-SERV/Pages/RegNewDevice.razor.cs @@ -1,4 +1,6 @@ +using EgwCoreLib.Utils; using Microsoft.AspNetCore.Components; +using Microsoft.AspNetCore.WebUtilities; //using MongoDB.Bson.IO; using MP.Data.DatabaseModels; using MP.Data.DTO; @@ -33,13 +35,14 @@ namespace MP_TAB_SERV.Pages expDT = DateTime.Now.AddDays(expDays); - CurrOprTknLS = await MsgServ.getCurrOperDtoAsync(); - CurrOprTknRedis = await TDService.OperatoreGetRedis(CurrOprTknLS); + //CurrOprTknLS = await MsgServ.getCurrOperDtoAsync(); + //var decodedUrl = Uri.UnescapeDataString(CurrOprTknLS); + //CurrOprTknRedis = await TDService.OperatoreGetRedis(decodedUrl); - if (CurrOprTknRedis != "") - { - NavMan.NavigateTo("status-map"); - } + //if (CurrOprTknRedis != "") + //{ + // NavMan.NavigateTo("status-map"); + //} //if (MsgServ.RigaOper != null) //{ @@ -72,10 +75,120 @@ namespace MP_TAB_SERV.Pages string hash = TDService.EncriptData(jsonTkn); MsgServ.RigaOper = rigaOpr; await MsgServ.setCurrOperDtoAsync(hash); - await TDService.OperatoreSetRedis(hash); + await TDService.OperatoreSetRedis(matrOpr, hash); NavMan.NavigateTo("status-map"); } //StateHasChanged(); } + + protected DateTime vetoScan = DateTime.Now; + + protected async Task ScanDoneHandler(string value) + { + DateTime adesso = DateTime.Now; + // non nullo + if (!string.IsNullOrEmpty(value)) + { + // non veto... + if (adesso.Subtract(vetoScan).TotalMinutes > 0) + { + vetoScan = adesso.AddSeconds(4); + //NavManager.NavigateTo($"CodeProcess/{value}"); + var uri = NavMan.ToAbsoluteUri(value); + if (QueryHelpers.ParseQuery(uri.Query).TryGetValue("MatrOpr", out var _matrOpr)) + { + if (!string.IsNullOrEmpty(_matrOpr)) + { + matrOpr = int.Parse(_matrOpr); + } + } + if (QueryHelpers.ParseQuery(uri.Query).TryGetValue("UserAuthKey", out var _authKey)) + { + if (!string.IsNullOrEmpty(_authKey)) + { + authKey = _authKey; + } + } + + + rigaOpr = await TDService.LoginOperatore(matrOpr, authKey); + if (rigaOpr == null) + { + var deHash = TDService.DeriptData(authKey); + rigaOpr = await TDService.LoginOperatore(matrOpr, deHash); + } + if (rigaOpr != null) + { + userTknDTO newUserTkn = new userTknDTO() + { + currOpr = rigaOpr, + expTime = expDT + }; + + var jsonTkn = JsonConvert.SerializeObject(newUserTkn); + string hash = TDService.EncriptData(jsonTkn); + MsgServ.RigaOper = rigaOpr; + await MsgServ.setCurrOperDtoAsync(hash); + await TDService.OperatoreSetRedis(matrOpr, hash); + NavMan.NavigateTo("status-map"); + } + } + } + } + + private bool ShowScanBarcode { get; set; } = false; + + + //private async Task ProcessBarcode(string Barcode) + //{ + // if (OrderCode != Barcode) + // { + // await InvokeAsync(() => + // { + // OrderCode = Barcode; + // }); + // var ordine = await DataService.OrderGetByCode(Barcode); + // if (ordine != null) + // { + // if (ordine.DtExecEnd > ordine.DtOrder) + // { + // await InvokeAsync(() => + // { + // errorDescription = "Errore: ordine già completato"; + // }); + // await Task.Run(() => + // { + // Thread.Sleep(3000); + // forceReset(); + // }); + // } + // else if (ordine.PlantId != SelPlantId) + // { + // await InvokeAsync(() => + // { + // errorDescription = "Errore: ordine destinato ad altro impianto"; + // }); + + // await Task.Run(() => + // { + // Thread.Sleep(3000); + // forceReset(); + // }); + // } + // else + // { + // // salvo... + // MessageService.SelPlantId = $"{SelPlantId}"; + // MessageService.SelOrderCode = Barcode; + // // rimando a pagina load.... + // NavManager.NavigateTo($"GasStationLoad"); + // } + // } + // else + // { + // errorDescription = "Errore: ordine non trovato"; + // } + // } + //} } } \ No newline at end of file diff --git a/MP-TAB-SERV/Pages/_Layout.cshtml b/MP-TAB-SERV/Pages/_Layout.cshtml index 24f41386..1958df59 100644 --- a/MP-TAB-SERV/Pages/_Layout.cshtml +++ b/MP-TAB-SERV/Pages/_Layout.cshtml @@ -38,6 +38,9 @@ 🗙 + + + diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 6b4a3545..15d31c57 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.1317

    +

    Versione: 6.16.2311.1410


    Note di rilascio:
    • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 9d59cd72..df8d750d 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1317 +6.16.2311.1410 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index c744469f..0d76dc00 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1317 + 6.16.2311.1410 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP.Data/Services/TabDataService.cs b/MP.Data/Services/TabDataService.cs index 7d439377..49194873 100644 --- a/MP.Data/Services/TabDataService.cs +++ b/MP.Data/Services/TabDataService.cs @@ -287,19 +287,20 @@ namespace MP.Data.Services ///
    /// /// - public async Task OperatoreGetRedis(string currOpr) + public async Task OperatoreGetRedis(int matrOpr) { string source = "REDIS"; Stopwatch sw = new Stopwatch(); sw.Start(); string answ = ""; // cerco in redis... - string currKey = $"{redisBaseKey}:CurrOpr:{currOpr}"; + string currKey = $"{redisBaseKey}:CurrOpr:{matrOpr}"; RedisValue rawData = await redisDb.StringGetAsync(currKey); if (rawData.HasValue) { //var encrData = SteamCrypto.DecryptString(rawData, passPhrase); - answ = JsonConvert.DeserializeObject(rawData); + //answ = JsonConvert.DeserializeObject(rawData); + answ = rawData; } if (answ == null) { @@ -315,14 +316,14 @@ namespace MP.Data.Services /// /// /// - public async Task OperatoreSetRedis(string currOpr) + public async Task OperatoreSetRedis(int matrOpr, string currOpr) { string source = "REDIS"; Stopwatch sw = new Stopwatch(); sw.Start(); string answ = ""; // cerco in redis... - string currKey = $"{redisBaseKey}:CurrOpr:{currOpr}"; + string currKey = $"{redisBaseKey}:CurrOpr:{matrOpr}"; //RedisValue rawData = await redisDb.StringGetAsync(currKey); // serializzo e salvo... //rawData = JsonConvert.SerializeObject(currOpr); From 9de748ebcbbde571ee1dc01360862e4eb6277234 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Tue, 14 Nov 2023 10:45:00 +0100 Subject: [PATCH 007/100] fix grafico --- MP-TAB-SERV/Pages/RegNewDevice.razor | 20 ++++++++++++-------- MP-TAB-SERV/Pages/RegNewDevice.razor.cs | 6 ++++++ 2 files changed, 18 insertions(+), 8 deletions(-) diff --git a/MP-TAB-SERV/Pages/RegNewDevice.razor b/MP-TAB-SERV/Pages/RegNewDevice.razor index 1f05bdf0..f7faf040 100644 --- a/MP-TAB-SERV/Pages/RegNewDevice.razor +++ b/MP-TAB-SERV/Pages/RegNewDevice.razor @@ -6,18 +6,22 @@
    - +
    - +@if (ShowScanBarcode) +{ + + +} @@ -47,7 +51,7 @@ -@if(rigaOpr != null) +@if (rigaOpr != null) {
    @($"{MsgServ.UserAuthKey} {MsgServ.MatrOpr}")
    } diff --git a/MP-TAB-SERV/Pages/RegNewDevice.razor.cs b/MP-TAB-SERV/Pages/RegNewDevice.razor.cs index 142f9f2a..583780f6 100644 --- a/MP-TAB-SERV/Pages/RegNewDevice.razor.cs +++ b/MP-TAB-SERV/Pages/RegNewDevice.razor.cs @@ -81,6 +81,12 @@ namespace MP_TAB_SERV.Pages //StateHasChanged(); } + protected async Task btnMode() + { + await Task.Delay(1); + ShowScanBarcode = !ShowScanBarcode; + } + protected DateTime vetoScan = DateTime.Now; protected async Task ScanDoneHandler(string value) From 32aaac3744c33d9e37b23fc5791027b13b96e90d Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Tue, 14 Nov 2023 10:54:53 +0100 Subject: [PATCH 008/100] fix redirect --- MP-TAB-SERV/Components/CmpTop.razor.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MP-TAB-SERV/Components/CmpTop.razor.cs b/MP-TAB-SERV/Components/CmpTop.razor.cs index 5d9c7944..796476d5 100644 --- a/MP-TAB-SERV/Components/CmpTop.razor.cs +++ b/MP-TAB-SERV/Components/CmpTop.razor.cs @@ -122,14 +122,14 @@ namespace MP_TAB_SERV.Components { if (!NavMan.Uri.Contains("regnewdevice")) { - NavMan.NavigateTo("/regnewdevice", true); + NavMan.NavigateTo("regnewdevice", true); } } else if (CurrOprTknRedis != "") { if (!NavMan.Uri.Contains("status-map")) { - NavMan.NavigateTo("/status-map", true); + NavMan.NavigateTo("status-map", true); } } } From 4bdf4493e0de5f6b3803cc3f1b6c969703fd0549 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Tue, 14 Nov 2023 11:05:18 +0100 Subject: [PATCH 009/100] Ancora update ODL --- MP-TAB-SERV/Components/OdlMan.razor | 10 +- MP-TAB-SERV/Components/OdlMan.razor.cs | 140 +++++++++++++-- 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 | 31 ++++ MP.Data/Services/TabDataService.cs | 230 ++++++++++++++----------- 8 files changed, 298 insertions(+), 121 deletions(-) diff --git a/MP-TAB-SERV/Components/OdlMan.razor b/MP-TAB-SERV/Components/OdlMan.razor index 355f0de0..eb43683b 100644 --- a/MP-TAB-SERV/Components/OdlMan.razor +++ b/MP-TAB-SERV/Components/OdlMan.razor @@ -26,7 +26,12 @@
    @lblWarnHead
    -
    @lblWarnBody @numPz2Conf.ToString("N0") pz NC
    +
    + @lblWarnBody +
    + Pezzi NC: @numPz2Conf.ToString("N0") +
    +
    @if (!odlOk) @@ -63,7 +68,8 @@ @if (cancelSetupEnabled) {
    - + +
    } diff --git a/MP-TAB-SERV/Components/OdlMan.razor.cs b/MP-TAB-SERV/Components/OdlMan.razor.cs index 9d63c85b..ee193877 100644 --- a/MP-TAB-SERV/Components/OdlMan.razor.cs +++ b/MP-TAB-SERV/Components/OdlMan.razor.cs @@ -191,6 +191,72 @@ namespace MP_TAB_SERV.Components return answ; } + /// + /// Annulla setup ODL (come se avesse fatto FINE PROD) + /// + /// + /// + protected async Task OdlAnnullaSetup() + { + if (!await JSRuntime.InvokeAsync("confirm", $"Confermi di voler annullare il setup ODL in corso, equivalente a registrare solo la fine produzione?")) + return; + + // preparo gestione progress display + MaxVal = 9; + isProcessing = true; + int currStep = 0; + await advStep(currStep); + + // leggo idxOdl da ultimo odl attivo x macchina + var odlLast = await TabDServ.OdlCurrByMacc(IdxMaccSel, true); + int idxODLCurr = odlLast.IdxOdl; + int idxEvento = 7; // !!!HARD CODED + await advStep(currStep++); + + try + { + // confermo prod vecchio ODL + await confermaProdOdl(true); + await advStep(currStep++); + + // processo x macchina selezionata + await TabDServ.OdlFineProd(idxODLCurr, IdxMaccSel); + await advStep(currStep++); + + string evText = "Registrata ANNULLAMENTO ATTREZZAGGIO per ODL {0}"; + StringBuilder sb = new StringBuilder(); + sb.AppendLine(String.Format(evText, idxODLCurr)); + await processaEvento(IdxMaccSel, idxEvento, sb.ToString(), idxODLCurr); + await advStep(currStep++); + + // resetta PODL e rimuove ODL x poi TOGLIERE info di setup su macchina corrente + await TabDServ.OdlClearSetup(idxODLCurr, IdxMaccSel); + await advStep(currStep++); + + // se è master --> chiamo update child! + if (isMaster) + { + // hard coded 60gg last + await TabDServ.OdlFixMachineSlave(IdxMaccSel, 60, 1); + } + await advStep(currStep++); + + // cancella dati correnti ODL + DoRemoveCurrOdlData(); + await advStep(currStep++); + } + catch + { } + + // refresh finale + checkAll(); + await RefreshData(); + await CheckAttr(); + await advStep(currStep++); + isProcessing = false; + await InvokeAsync(StateHasChanged); + } + /// /// Effettua ripresa ODL su tavola /// @@ -198,6 +264,9 @@ namespace MP_TAB_SERV.Components /// protected async Task OdlReopenTav() { + if (!await JSRuntime.InvokeAsync("confirm", $"Confermi di voler riprendere in carico l'ODL precedente?")) + return; + MaxVal = 3; int currStep = 0; await advStep(currStep); @@ -230,6 +299,9 @@ namespace MP_TAB_SERV.Components /// protected async Task OdlSetSameAsOtherTav() { + if (!await JSRuntime.InvokeAsync("confirm", $"Confermi di voler impostare lo stesso ODL dell'altra tavola?")) + return; + MaxVal = 3; int currStep = 0; await advStep(currStep); @@ -573,6 +645,7 @@ namespace MP_TAB_SERV.Components enableSplitODL = SMServ.GetConfBool("enableSplitODL"); modoConfProd = SMServ.GetConfInt("modoConfProd"); enableRPO = SMServ.GetConfBool("enableRPO"); + enableAnnullaSetup = SMServ.GetConfBool("enableAnnullaSetup"); enableSchedaTecnica = SMServ.GetConfBool("enableSchedaTecnica"); enableFixSetup = SMServ.GetConfBool("OptEnableFixSetup"); showSplitOdlOnTav = SMServ.GetConfBool("showSplitOdlOnTav"); @@ -610,8 +683,8 @@ namespace MP_TAB_SERV.Components // leggo idxOdl da ultimo odl attivo x macchina var currOdl = await TabDServ.OdlCurrByMacc(IdxMaccSel, false); int idxODLCurr = currOdl.IdxOdl; - int idxEvento = 7; // !!!HARD CODED - // confermo prod vecchio ODL + int idxEvento = 7; + // !!!HARD CODED confermo prod vecchio ODL await confermaProdOdl(false); await advStep(currStep++); @@ -798,6 +871,7 @@ namespace MP_TAB_SERV.Components IdxMaccSel = selIdxMacc; // recupero dati RecMSE = TabDServ.MseGetSub(IdxMaccParent, selIdxMacc, true); + await ReloadData(true); await DoUpdate(); if (showOdlDetail) { @@ -827,14 +901,14 @@ namespace MP_TAB_SERV.Components private static Logger Log = LogManager.GetCurrentClassLogger(); - private bool cancelSetupEnabled = false; - private bool confRett = true; private double currVal = 0; private List emailAdmDest = new List(); + private bool enableAnnullaSetup = false; + private bool enableFixSetup = false; private bool enableRPO = true; @@ -903,6 +977,11 @@ namespace MP_TAB_SERV.Components set { MServ.UserPrefGet("Lang"); } } + private bool cancelSetupEnabled + { + get => inAttr && enableSchedaTecnica && enableAnnullaSetup; + } + private string cssDetailOdl { get => IdxPOdlSel > 0 ? "bg-primary text-light" : "bg-warning"; @@ -955,16 +1034,11 @@ namespace MP_TAB_SERV.Components return answ; } } - #if false - { - get => RecMSE != null ? RecMSE.IdxOdl ?? 0 : 0; - } -#endif - /// - /// Valore calcolato key ODL altra tavola attivo... - /// - private int IdxOdlAltra + /// + /// Valore calcolato key ODL altra tavola attivo... + /// + private int IdxOdlAltra { get { @@ -1343,6 +1417,46 @@ namespace MP_TAB_SERV.Components } } + /// + /// Rimozione dati e parametri (TAB e su PLC) x ODL corrente + /// + private void DoRemoveCurrOdlData() + { + // invio task x end produzione... + string setArtVal = "NO ART"; + string setPzCommVal = "0"; + string setCommVal = $"NO ODL"; + // FIXME TODO: scrivere come sotto? testare valvital x linea LASCO + TabDServ.addTask4Machine(IdxMaccSel, taskType.endProd, ""); + TabDServ.addTask4Machine(IdxMaccSel, taskType.setArt, setArtVal); + TabDServ.addTask4Machine(IdxMaccSel, taskType.setPzComm, setPzCommVal); + TabDServ.addTask4Machine(IdxMaccSel, taskType.setComm, setCommVal); + // se è master --> chiamo update child! + if (isMaster) + { + // calcolo gli slave... + var slaveList = SMServ.ListM2S + .Where(x => x.IdxMacchina.Equals(IdxMaccSel, StringComparison.InvariantCultureIgnoreCase)) + .ToList(); + foreach (var machine in slaveList) + { + // invio task x end produzione... + TabDServ.addTask4Machine(machine.IdxMacchinaSlave, taskType.endProd, ""); + TabDServ.addTask4Machine(machine.IdxMacchinaSlave, taskType.setArt, setArtVal); + TabDServ.addTask4Machine(machine.IdxMacchinaSlave, taskType.setPzComm, setPzCommVal); + TabDServ.addTask4Machine(machine.IdxMacchinaSlave, taskType.setComm, setCommVal); + } + } + // rimando a pagina dettaglio... + NavMan.NavigateTo("machine-detail", true); + } + +#if false + { + get => RecMSE != null ? RecMSE.IdxOdl ?? 0 : 0; + } +#endif + /// /// sistema buttons split /// diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index c62aca7e..d9f262ea 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.1317 + 6.16.2311.1319 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 6b4a3545..11570614 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.1317

    +

    Versione: 6.16.2311.1319


    Note di rilascio:
    • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 9d59cd72..1d647080 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1317 +6.16.2311.1319 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index c744469f..8e83637d 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1317 + 6.16.2311.1319 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP.Data/Controllers/MpTabController.cs b/MP.Data/Controllers/MpTabController.cs index 50a5b34f..bee0b466 100644 --- a/MP.Data/Controllers/MpTabController.cs +++ b/MP.Data/Controllers/MpTabController.cs @@ -823,6 +823,34 @@ namespace MP.Data.Controllers return dbResult; } + /// + /// Clear operazione setup ODL (annullamento) + /// + /// + /// + /// + public bool OdlClearSetup(int idxODL, string idxMacchina) + { + bool answ = false; + using (var dbCtx = new MoonProContext(_configuration)) + { + try + { + var IdxODL = new SqlParameter("@idxODL", idxODL); + var IdxMacchina = new SqlParameter("@IdxMacchina", idxMacchina); + var result = dbCtx + .Database + .ExecuteSqlRaw("EXEC stp_ODL_clearSetup @IdxODL, @IdxMacchina", IdxODL, IdxMacchina); + answ = result != 0; + } + catch (Exception exc) + { + Log.Error($"Eccezione durante OdlClearSetup{Environment.NewLine}{exc}"); + } + } + return answ; + } + /// /// ODL corrente macchina /// @@ -1162,6 +1190,9 @@ namespace MP.Data.Controllers /// /// /// + /// + /// + /// /// public bool OdlUpdate(int idxODL, int matrOpr, decimal tCRichAttr, int pzPallet, string note) { diff --git a/MP.Data/Services/TabDataService.cs b/MP.Data/Services/TabDataService.cs index fc5b5e1a..27ef61d0 100644 --- a/MP.Data/Services/TabDataService.cs +++ b/MP.Data/Services/TabDataService.cs @@ -10,7 +10,6 @@ using System; using System.Collections.Generic; using System.Data; using System.Diagnostics; -using System.Drawing.Drawing2D; using System.Linq; using System.Text; using System.Threading.Tasks; @@ -1057,6 +1056,49 @@ namespace MP.Data.Services return answ; } + /// + /// Recupera un valore MSE x una macchina sub specifica + /// + /// + /// + /// + /// + public MappaStatoExpl MseGetSub(string idxMacc, string idxMacchSub, bool forceDb) + { + Stopwatch stopWatch = new Stopwatch(); + stopWatch.Start(); + MappaStatoExpl result = new MappaStatoExpl(); + // cerco in redis... + string currKey = $"{Constants.redisMseKeySingle}:{idxMacchSub}"; + RedisValue rawData = redisDb.StringGet(currKey); + if (rawData.HasValue && !forceDb) + { + result = JsonConvert.DeserializeObject($"{rawData}"); + stopWatch.Stop(); + TimeSpan ts = stopWatch.Elapsed; + Log.Debug($"Read from REDIS: {ts.TotalMilliseconds}ms"); + } + else + { + var rawResult = dbTabController.MseGetSub(idxMacc, idxMacchSub); + if (rawResult != null && rawResult.Count > 0) + { + result = rawResult.FirstOrDefault(); + } + // serializzp e salvo... + rawData = JsonConvert.SerializeObject(result); + redisDb.StringSet(currKey, rawData, UltraLongCache); + stopWatch.Stop(); + TimeSpan ts = stopWatch.Elapsed; + Log.Debug($"Read from DB: {ts.TotalMilliseconds}ms"); + } + if (result == null) + { + result = new MappaStatoExpl(); + } + return result; + } + /// /// ODL da key /// @@ -1094,6 +1136,31 @@ namespace MP.Data.Services return result; } + /// + /// Clear operazione setup ODL (annullamento) + /// + /// + /// + /// + public async Task OdlClearSetup(int idxODL, string idxMacchina) + { + bool answ = false; + try + { + // inserisco evento + answ = dbTabController.OdlClearSetup(idxODL, idxMacchina); + await FlushCache("ODL"); + await FlushCache("PODL"); + await FlushCache("VSODL"); + } + catch (Exception exc) + { + string logMsg = $"Eccezione in OdlUpdate | idxODL: {idxODL} | idxMacchina: {idxMacchina}{Environment.NewLine}{exc}"; + Log.Error(logMsg); + } + return answ; + } + /// /// ODL corrente macchina /// @@ -1130,32 +1197,6 @@ namespace MP.Data.Services return result; } - /// - /// Registro fine prod ODL - /// - /// - /// - /// - public async Task OdlFineProd(int idxODL, string idxMacchina) - { - bool answ = false; - try - { - // inserisco evento - answ = dbTabController.OdlFineProd(idxODL, idxMacchina); - await FlushCache("ODL"); - await FlushCache("PODL"); - await FlushCache("VSODL"); - } - catch (Exception exc) - { - string logMsg = $"Eccezione in OdlFineProd | idxODL: {idxODL} | idxMacchina: {idxMacchina}{Environment.NewLine}{exc}"; - Log.Error(logMsg); - } - return answ; - } - - /// /// Attrezzo stesso ODL dell'altra tavola /// @@ -1182,6 +1223,31 @@ namespace MP.Data.Services return answ; } + /// + /// Registro fine prod ODL + /// + /// + /// + /// + public async Task OdlFineProd(int idxODL, string idxMacchina) + { + bool answ = false; + try + { + // inserisco evento + answ = dbTabController.OdlFineProd(idxODL, idxMacchina); + await FlushCache("ODL"); + await FlushCache("PODL"); + await FlushCache("VSODL"); + } + catch (Exception exc) + { + string logMsg = $"Eccezione in OdlFineProd | idxODL: {idxODL} | idxMacchina: {idxMacchina}{Environment.NewLine}{exc}"; + Log.Error(logMsg); + } + return answ; + } + /// /// Fix ODL per macchine SLAVE /// @@ -1275,35 +1341,6 @@ namespace MP.Data.Services return result; } - /// - /// Riapertura ULTIMO ODL data macchina - /// - /// - /// - public async Task OdlReopenOdlMacc(string idxMacchina) - { - string source = "DB"; - Stopwatch sw = new Stopwatch(); - sw.Start(); - ODLModel result = new ODLModel(); - // cerco in redis... - string currKey = $"{redisBaseKey}:ODL:{idxMacchina}:LAST"; - var results = dbTabController.OdlReopenOdlMacc(idxMacchina); - // riordino - result = results.FirstOrDefault(); - // svuoto cache - await FlushCache("ODL"); - await FlushCache("PODL"); - await FlushCache("VSODL"); - if (result == null) - { - result = new ODLModel(); - } - sw.Stop(); - Log.Debug($"OdlReopenOdlMacc | {source} | {sw.Elapsed.TotalMilliseconds}ms"); - return result; - } - /// /// Elenco ODL data macchina e periodo /// @@ -1343,6 +1380,35 @@ namespace MP.Data.Services return result; } + /// + /// Riapertura ULTIMO ODL data macchina + /// + /// + /// + public async Task OdlReopenOdlMacc(string idxMacchina) + { + string source = "DB"; + Stopwatch sw = new Stopwatch(); + sw.Start(); + ODLModel result = new ODLModel(); + // cerco in redis... + string currKey = $"{redisBaseKey}:ODL:{idxMacchina}:LAST"; + var results = await Task.FromResult(dbTabController.OdlReopenOdlMacc(idxMacchina)); + // riordino + result = results.FirstOrDefault(); + // svuoto cache + await FlushCache("ODL"); + await FlushCache("PODL"); + await FlushCache("VSODL"); + if (result == null) + { + result = new ODLModel(); + } + sw.Stop(); + Log.Debug($"OdlReopenOdlMacc | {source} | {sw.Elapsed.TotalMilliseconds}ms"); + return result; + } + /// /// Setup ODL Postumo /// @@ -1355,7 +1421,7 @@ namespace MP.Data.Services try { // inserisco evento - answ = dbTabController.OdlSetupPostumo(idxODL, idxMacchina); + answ = await Task.FromResult(dbTabController.OdlSetupPostumo(idxODL, idxMacchina)); await FlushCache("ODL"); await FlushCache("PODL"); await FlushCache("VSODL"); @@ -1381,7 +1447,7 @@ namespace MP.Data.Services try { // inserisco evento - answ = dbTabController.OdlSetupPromPostuma(idxPromOdl, matrOpr, idxMacchina); + answ = await Task.FromResult(dbTabController.OdlSetupPromPostuma(idxPromOdl, matrOpr, idxMacchina)); await FlushCache("ODL"); await FlushCache("PODL"); await FlushCache("VSODL"); @@ -1412,7 +1478,7 @@ namespace MP.Data.Services try { // inserisco evento - answ = dbTabController.OdlSplit(idxODL, matrOpr, idxMacchina, TCRich, pzPallet, note, startNewOdl, qtyRich); + answ = await Task.FromResult(dbTabController.OdlSplit(idxODL, matrOpr, idxMacchina, TCRich, pzPallet, note, startNewOdl, qtyRich)); await FlushCache("ODL"); await FlushCache("PODL"); await FlushCache("VSODL"); @@ -1430,6 +1496,9 @@ namespace MP.Data.Services /// /// /// + /// + /// + /// /// public async Task OdlUpdate(int idxODL, int matrOpr, decimal tCRichAttr, int pzPallet, string note) { @@ -1995,49 +2064,6 @@ namespace MP.Data.Services await FlushCache(Constants.redisMseKey); return answ; } - /// - /// Recupera un valore MSE x una macchina sub specifica - /// - /// - /// - /// - /// - public MappaStatoExpl MseGetSub(string idxMacc, string idxMacchSub, bool forceDb) - { - Stopwatch stopWatch = new Stopwatch(); - stopWatch.Start(); - MappaStatoExpl result = new MappaStatoExpl(); - // cerco in redis... - string currKey = $"{Constants.redisMseKeySingle}:{idxMacchSub}"; - RedisValue rawData = redisDb.StringGet(currKey); - if (rawData.HasValue && !forceDb) - { - result = JsonConvert.DeserializeObject($"{rawData}"); - stopWatch.Stop(); - TimeSpan ts = stopWatch.Elapsed; - Log.Debug($"Read from REDIS: {ts.TotalMilliseconds}ms"); - } - else - { - var rawResult = dbTabController.MseGetSub(idxMacc, idxMacchSub); - if (rawResult != null && rawResult.Count > 0) - { - result = rawResult.FirstOrDefault(); - } - // serializzp e salvo... - rawData = JsonConvert.SerializeObject(result); - redisDb.StringSet(currKey, rawData, UltraLongCache); - stopWatch.Stop(); - TimeSpan ts = stopWatch.Elapsed; - Log.Debug($"Read from DB: {ts.TotalMilliseconds}ms"); - } - if (result == null) - { - result = new MappaStatoExpl(); - } - return result; - } - /// /// Processa registrazione di un counter x una data macchina IOB From 94e4b91155a61c086c05997b0680679446b7ffbf Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Tue, 14 Nov 2023 11:51:03 +0100 Subject: [PATCH 010/100] fix sicurezza --- MP-TAB-SERV/MP-TAB-SERV.csproj | 2 +- MP-TAB-SERV/Pages/Logout.razor | 4 +- MP-TAB-SERV/Pages/Logout.razor.cs | 47 +++++++++++++++++++++ MP-TAB-SERV/Resources/ChangeLog.html | 2 +- MP-TAB-SERV/Resources/VersNum.txt | 2 +- MP-TAB-SERV/Resources/manifest.xml | 2 +- MP.Data/Services/TabDataService.cs | 62 +++++++++++++++++++++------- 7 files changed, 98 insertions(+), 23 deletions(-) create mode 100644 MP-TAB-SERV/Pages/Logout.razor.cs diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 5f5130e9..654471b0 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.1410 + 6.16.2311.1411 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Pages/Logout.razor b/MP-TAB-SERV/Pages/Logout.razor index a881db05..6579df65 100644 --- a/MP-TAB-SERV/Pages/Logout.razor +++ b/MP-TAB-SERV/Pages/Logout.razor @@ -1,8 +1,6 @@ @page "/logout" -

      logout

      + -@code { -} diff --git a/MP-TAB-SERV/Pages/Logout.razor.cs b/MP-TAB-SERV/Pages/Logout.razor.cs new file mode 100644 index 00000000..7d75c64a --- /dev/null +++ b/MP-TAB-SERV/Pages/Logout.razor.cs @@ -0,0 +1,47 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Components; +using System.Net.Http; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Components.Authorization; +using Microsoft.AspNetCore.Components.Forms; +using Microsoft.AspNetCore.Components.Routing; +using Microsoft.AspNetCore.Components.Web; +using Microsoft.AspNetCore.Components.Web.Virtualization; +using Microsoft.JSInterop; +using MP_TAB_SERV; +using MP_TAB_SERV.Shared; +using MP_TAB_SERV.Components; +using MP.Data; +using MP.Data.DatabaseModels; +using MP.Data.DTO; +using MP.Data.Services; +using Newtonsoft.Json; +using NLog; +using EgwCoreLib.Razor; +using Blazored.LocalStorage; + +namespace MP_TAB_SERV.Pages +{ + public partial class Logout + { + [Inject] + protected ILocalStorageService localStorage { get; set; } = null!; + [Inject] + protected TabDataService TDService { get; set; } = null!; + [Inject] + protected MessageService MsgServ { get; set; } = null!; + [Inject] + protected NavigationManager NavMan { get; set; } = null!; + + protected override async Task OnInitializedAsync() + { + await Task.Delay(1); + await localStorage.SetItemAsync("currTkn", ""); + await TDService.OperatoreDeleteRedis(MsgServ.MatrOpr); + NavMan.NavigateTo("regnewdevice"); + } + } +} \ No newline at end of file diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 15d31c57..6e880a19 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.1410

      +

      Versione: 6.16.2311.1411


      Note di rilascio:
      protected List CurrMenuItems { get; set; } = new List(); + protected bool HideMenu + { + get => NavMan.Uri.Contains("reg-new-device"); + } + [Inject] protected ListSelectDataSrv MDataService { get; set; } = null!; [Inject] - protected MessageService MServ { get; set; } = null!; + protected MessageService MsgServ { get; set; } = null!; [Inject] protected SharedMemService MStor { get; set; } = null!; diff --git a/MP.Data/Services/MessageService.cs b/MP.Data/Services/MessageService.cs index 36b8c517..34d750e1 100644 --- a/MP.Data/Services/MessageService.cs +++ b/MP.Data/Services/MessageService.cs @@ -416,33 +416,6 @@ namespace MP.Data.Services } private AnagOperatoriModel? _rigaOper; - //{ - // get - // { - // AnagOperatoriModel answ = new AnagOperatoriModel(); - // string rawData = ""; - // var pUpd = Task.Run(async () => - // { - // rawData = await getCurrOperDtoAsync(); - // }); - // pUpd.Wait(); - // var decodedUrl = Uri.UnescapeDataString(rawData); - // var decrData = DecryptData(decodedUrl); - // answ = JsonConvert.DeserializeObject(decodedUrl); - // return answ; - // } - // set - // { - // var serVal = JsonConvert.SerializeObject(value); - // var encData = EncryptData(serVal); - // var escdata = Uri.EscapeDataString(encData); - // var pUpd = Task.Run(async () => - // { - // await setCurrOperDtoAsync(escdata); - // }); - // pUpd.Wait(); - // } - //} public string EncryptData(string rawData) { return SteamCrypto.EncryptString(rawData, Constants.passPhrase); @@ -527,7 +500,7 @@ namespace MP.Data.Services /// Restituisce il record OperatoreDTO da localstorage /// /// - public async Task getCurrOperDtoAsync() + public async Task GetCurrOperDtoAsync() { string answ = ""; var result = await localStorage.GetItemAsync("currTkn"); @@ -539,11 +512,39 @@ namespace MP.Data.Services return answ; } + /// + /// Restituisce ultima matrOpr registrata da localstorage + /// + /// + public async Task GetLastMatrOprAsync() + { + int answ = -1; + var result = await localStorage.GetItemAsync("lastMatrOpr"); + if (!string.IsNullOrEmpty(result)) + { + answ = int.Parse(result); + } + return answ; + } + + + /// + /// Salva matrOpr nel localstorage + /// + /// + public async Task SetLastMatrOprAsync(int matrOpr) + { + bool answ = false; + await localStorage.SetItemAsync("lastMatrOpr", matrOpr); + answ = true; + return answ; + } + /// /// scrive il record OperatoreDTO nel localstorage /// /// - public async Task setCurrOperDtoAsync(string currTkn) + public async Task SetCurrOperDtoAsync(string currTkn) { bool answ = false; await localStorage.SetItemAsync("currTkn", currTkn); @@ -551,244 +552,9 @@ namespace MP.Data.Services return answ; } + + #endregion Private Methods -#if false - public event Action EA_DateChanged = null!; - public event Action EA_CalModeChanged = null!; - - public event Action EA_TimbUpd = null!; -#endif - -#if false - public RegAttivitaModel? clonedRA { get; set; } = null; - - /// - /// Calcola HASH del codice impiego = payload utente - /// - /// - public string HashDip - { - get - { - DataValidator cDV = new DataValidator(_rigaOper); - string hash = cDV.HashDip; - return hash; - } - } -#endif -#if false - public bool IsActive - { - get - { - bool answ = false; - if (_rigaOper != null && _rigaOper.Attivo != null) - { - answ = (bool)_rigaOper.Attivo; - } - return answ; - } - } - - public bool isRicTimb { get; set; } = false; - - public CalendarModeEnum.modoControllo modoCal { get; set; } = CalendarModeEnum.modoControllo.showCalendar; -#endif - -#if false - /// - /// Indica ultima azione compiuta - /// - public string LastAction - { - get => lastAction; - set - { - if (lastAction != value) - { - lastAction = value; - } - } - } - - /// - /// Indica se il prossimo stato timbratura sia entrata - /// - public bool NextIsEntrata - { - get => nextIsEntrata; - set - { - if (nextIsEntrata != value) - { - nextIsEntrata = value; - } - } - } - - public string PageIcon - { - get => _pageIcon; - set - { - if (_pageIcon != value) - { - _pageIcon = value; - ReportPageUpd(); - } - } - } - - public string PageName - { - get => _pageName; - set - { - if (_pageName != value) - { - _pageName = value; - ReportPageUpd(); - } - } - } - - public bool PayloadOk { get; set; } = false; - public RegAttivitaModel? recordRA { get; set; } = null; -#endif -#if false - public string SearchVal - { - get => _searchVal; - set - { - if (_searchVal != value) - { - _searchVal = value; - - if (EA_DipUpdated != null) - { - EA_DipUpdated?.Invoke(); - } - } - } - } - - public int selWeekNum { get; set; } = 0; - public int selYear { get; set; } = DateTime.Today.Year; - - public bool ShowSearch - { - get => showSearch; - set - { - if (showSearch != value) - { - showSearch = value; - } - } - } - - public DateTime targetDate { get; set; } = DateTime.Today; - public DateTime targetDateMancTimb { get; set; } -#endif -#if false - - public void ReportDateChange() - { - if (EA_DateChanged != null) - { - EA_DateChanged?.Invoke(); - } - } - - public void setModeCalendar() - { - modoCal = CalendarModeEnum.modoControllo.showCalendar; - if (EA_CalModeChanged != null) - { - EA_CalModeChanged?.Invoke(); - } - } - public void setModeGauge() - { - modoCal = CalendarModeEnum.modoControllo.showGauge; - if (EA_CalModeChanged != null) - { - EA_CalModeChanged?.Invoke(); - } - } - public void setModeProj() - { - modoCal = CalendarModeEnum.modoControllo.showProj; - if (EA_CalModeChanged != null) - { - EA_CalModeChanged?.Invoke(); - } - } - public void setModeTempRil() - { - modoCal = CalendarModeEnum.modoControllo.showTempRil; - if (EA_CalModeChanged != null) - { - EA_CalModeChanged?.Invoke(); - } - } - public void setModeRichTimb() - { - modoCal = CalendarModeEnum.modoControllo.showTimbr; - if (EA_CalModeChanged != null) - { - EA_CalModeChanged?.Invoke(); - } - } - public void setModeShowWeek() - { - modoCal = CalendarModeEnum.modoControllo.showWeek; - if (EA_CalModeChanged != null) - { - EA_CalModeChanged?.Invoke(); - } - } - - public void ReportTimbratura() - { - if (EA_TimbUpd != null) - { - EA_TimbUpd?.Invoke(); - } - } -#endif -#if false - private string _pageIcon = ""; - private string _pageName = ""; -#endif -#if false - private string _searchVal = ""; - private bool showSearch; -#endif - -#if false - private string lastAction { get; set; } = ""; - private bool nextIsEntrata { get; set; } = true; -#endif - -#if false - private void ReportPageUpd() - { - if (EA_PageUpdated != null) - { - EA_PageUpdated?.Invoke(); - } - } - - private void ReportSearch() - { - if (EA_DipUpdated != null) - { - EA_DipUpdated?.Invoke(); - } - } -#endif } } \ No newline at end of file From 80638a2d8f896199d9f7783ad6318a1ff765379d Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Wed, 15 Nov 2023 08:44:17 +0100 Subject: [PATCH 017/100] fix grafici --- 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-TAB-SERV/Shared/MainLayout.razor | 2 +- MP-TAB-SERV/Shared/MainLayout.razor.cs | 6 ++++++ MP-TAB-SERV/Shared/MainLayout.razor.css | 7 +++++-- MP-TAB-SERV/Shared/NavMenu.razor.css | 2 +- 8 files changed, 17 insertions(+), 8 deletions(-) diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 5f9739f3..836f7e44 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.1417 + 6.16.2311.1508 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 33605a51..ea60b6fc 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.1417

      +

      Versione: 6.16.2311.1508


      Note di rilascio:
      • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index aa26489c..a277c76b 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1417 +6.16.2311.1508 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index f30904f9..f720b67a 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1417 + 6.16.2311.1508 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP-TAB-SERV/Shared/MainLayout.razor b/MP-TAB-SERV/Shared/MainLayout.razor index 1e089fb4..cb0b5b31 100644 --- a/MP-TAB-SERV/Shared/MainLayout.razor +++ b/MP-TAB-SERV/Shared/MainLayout.razor @@ -9,7 +9,7 @@
        -
        +
        @Body
        @if (!HideMenu) diff --git a/MP-TAB-SERV/Shared/MainLayout.razor.cs b/MP-TAB-SERV/Shared/MainLayout.razor.cs index 13aab913..c102a904 100644 --- a/MP-TAB-SERV/Shared/MainLayout.razor.cs +++ b/MP-TAB-SERV/Shared/MainLayout.razor.cs @@ -59,6 +59,12 @@ namespace MP_TAB_SERV.Shared #region Protected Methods + protected string bodyTipe + { + get => NavMan.Uri.Contains("reg-new-device") ? "mainBodyNoSide" : "mainBody"; + } + + /// /// Init struttura dati /// diff --git a/MP-TAB-SERV/Shared/MainLayout.razor.css b/MP-TAB-SERV/Shared/MainLayout.razor.css index a80c3036..bea7a149 100644 --- a/MP-TAB-SERV/Shared/MainLayout.razor.css +++ b/MP-TAB-SERV/Shared/MainLayout.razor.css @@ -16,13 +16,16 @@ main { @media (min-width: 640.98px) { - .slideMen:not(.auth) { + /*.slideMen:not(.auth) { display: none; - } + }*/ #mainBody { width: 83%; } + #mainBodyNoSide { + width: 100%; + } } diff --git a/MP-TAB-SERV/Shared/NavMenu.razor.css b/MP-TAB-SERV/Shared/NavMenu.razor.css index 4e972e81..1cf40bb7 100644 --- a/MP-TAB-SERV/Shared/NavMenu.razor.css +++ b/MP-TAB-SERV/Shared/NavMenu.razor.css @@ -35,7 +35,7 @@ } -@media (min-width: 640.98px) { +@media (max-width: 640.98px) { .slideMen:not(.auth) { display: none; } From 87bdf4582546b237ba7e4041f2885855300f2191 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Wed, 15 Nov 2023 08:49:09 +0100 Subject: [PATCH 018/100] tentativo fix cam --- MP-TAB-SERV/Pages/RegNewDevice.razor | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MP-TAB-SERV/Pages/RegNewDevice.razor b/MP-TAB-SERV/Pages/RegNewDevice.razor index b6be7e2f..ad136c16 100644 --- a/MP-TAB-SERV/Pages/RegNewDevice.razor +++ b/MP-TAB-SERV/Pages/RegNewDevice.razor @@ -35,7 +35,7 @@
        - +
        From 0f9c66b92c8e3099333ba72189df9103e7584451 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Wed, 15 Nov 2023 08:57:58 +0100 Subject: [PATCH 019/100] cambiati riferimenti js zxing --- MP-TAB-SERV/Pages/_Layout.cshtml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/MP-TAB-SERV/Pages/_Layout.cshtml b/MP-TAB-SERV/Pages/_Layout.cshtml index 1958df59..e784a06a 100644 --- a/MP-TAB-SERV/Pages/_Layout.cshtml +++ b/MP-TAB-SERV/Pages/_Layout.cshtml @@ -38,8 +38,10 @@ 🗙 - - + @* + *@ + + From c3cb860376ffc885967e4f52b98f1984110f8c4c Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Wed, 15 Nov 2023 09:44:51 +0100 Subject: [PATCH 020/100] ancora cambiata definizioe script --- MP-TAB-SERV/MP-TAB-SERV.csproj | 2 +- MP-TAB-SERV/Pages/_Layout.cshtml | 6 +++--- MP-TAB-SERV/Resources/ChangeLog.html | 2 +- MP-TAB-SERV/Resources/VersNum.txt | 2 +- MP-TAB-SERV/Resources/manifest.xml | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 836f7e44..d8b92daf 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.1508 + 6.16.2311.1509 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Pages/_Layout.cshtml b/MP-TAB-SERV/Pages/_Layout.cshtml index e784a06a..b60b4827 100644 --- a/MP-TAB-SERV/Pages/_Layout.cshtml +++ b/MP-TAB-SERV/Pages/_Layout.cshtml @@ -40,10 +40,10 @@ @* *@ - - + - + diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index ea60b6fc..4429f6cd 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.1508

        +

        Versione: 6.16.2311.1509


        Note di rilascio:
        • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index a277c76b..cc35155b 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1508 +6.16.2311.1509 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index f720b67a..f6cec06f 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1508 + 6.16.2311.1509 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From 78a49a8e0b62321e72856faba98daa85210c5aed Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Wed, 15 Nov 2023 10:09:28 +0100 Subject: [PATCH 021/100] script --- MP-TAB-SERV/MP-TAB-SERV.csproj | 2 +- MP-TAB-SERV/Pages/_Layout.cshtml | 3 ++- MP-TAB-SERV/Resources/ChangeLog.html | 2 +- MP-TAB-SERV/Resources/VersNum.txt | 2 +- MP-TAB-SERV/Resources/manifest.xml | 2 +- 5 files changed, 6 insertions(+), 5 deletions(-) diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index d8b92daf..c5c607f5 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.1509 + 6.16.2311.1510 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Pages/_Layout.cshtml b/MP-TAB-SERV/Pages/_Layout.cshtml index b60b4827..4678051d 100644 --- a/MP-TAB-SERV/Pages/_Layout.cshtml +++ b/MP-TAB-SERV/Pages/_Layout.cshtml @@ -41,8 +41,9 @@ @* *@ - + diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 4429f6cd..81c90735 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.1509

          +

          Versione: 6.16.2311.1510


          Note di rilascio:
          • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index cc35155b..66e5e33a 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1509 +6.16.2311.1510 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index f6cec06f..548ee2c2 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1509 + 6.16.2311.1510 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From b89293ed91459f04201838f2350e6763bd9c8dd4 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Wed, 15 Nov 2023 10:15:22 +0100 Subject: [PATCH 022/100] scripts --- MP-TAB-SERV/Pages/_Layout.cshtml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MP-TAB-SERV/Pages/_Layout.cshtml b/MP-TAB-SERV/Pages/_Layout.cshtml index 4678051d..3483e39c 100644 --- a/MP-TAB-SERV/Pages/_Layout.cshtml +++ b/MP-TAB-SERV/Pages/_Layout.cshtml @@ -40,8 +40,8 @@ @* *@ - - + + From 944092e80a88bb1e11ed668a75315f910641f3a3 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Wed, 15 Nov 2023 10:18:46 +0100 Subject: [PATCH 023/100] prova cambio script --- MP-TAB-SERV/Pages/_Layout.cshtml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MP-TAB-SERV/Pages/_Layout.cshtml b/MP-TAB-SERV/Pages/_Layout.cshtml index 3483e39c..e0fa2b9b 100644 --- a/MP-TAB-SERV/Pages/_Layout.cshtml +++ b/MP-TAB-SERV/Pages/_Layout.cshtml @@ -40,7 +40,7 @@ @* *@ - + *@ - + @**@ - + @**@ - + diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 81c90735..01912779 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.1510

            +

            Versione: 6.16.2311.1514


            Note di rilascio:
            • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 66e5e33a..c099c126 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1510 +6.16.2311.1514 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index 548ee2c2..ffecf15c 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1510 + 6.16.2311.1514 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From ce175aab4055c75eb00fec45f8d1658bd44e14b6 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Wed, 15 Nov 2023 15:43:04 +0100 Subject: [PATCH 026/100] tentativo cambiando file js --- MP-TAB-SERV/MP-TAB-SERV.csproj | 3 +- MP-TAB-SERV/Pages/_Layout.cshtml | 5 +- MP-TAB-SERV/Resources/ChangeLog.html | 2 +- MP-TAB-SERV/Resources/VersNum.txt | 2 +- MP-TAB-SERV/Resources/manifest.xml | 2 +- MP-TAB-SERV/wwwroot/lib/BarcodeReade.js | 317 ++++++++++++++++++++++++ 6 files changed, 324 insertions(+), 7 deletions(-) create mode 100644 MP-TAB-SERV/wwwroot/lib/BarcodeReade.js diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 096beae5..6a2bf820 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.1514 + 6.16.2311.1515 enable MP_TAB_SERV @@ -26,7 +26,6 @@ - diff --git a/MP-TAB-SERV/Pages/_Layout.cshtml b/MP-TAB-SERV/Pages/_Layout.cshtml index 9c2f97bf..0a7d54c9 100644 --- a/MP-TAB-SERV/Pages/_Layout.cshtml +++ b/MP-TAB-SERV/Pages/_Layout.cshtml @@ -41,9 +41,10 @@ @* *@ @**@ - - + @* + *@ @**@ + diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 01912779..fed77556 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.1514

              +

              Versione: 6.16.2311.1515


              Note di rilascio:
              • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index c099c126..1c32dbea 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1514 +6.16.2311.1515 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index ffecf15c..2231ee99 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1514 + 6.16.2311.1515 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP-TAB-SERV/wwwroot/lib/BarcodeReade.js b/MP-TAB-SERV/wwwroot/lib/BarcodeReade.js new file mode 100644 index 00000000..2fbce212 --- /dev/null +++ b/MP-TAB-SERV/wwwroot/lib/BarcodeReade.js @@ -0,0 +1,317 @@ +import '_content/ZXingBlazor/lib/zxing/zxing.min.js'; +let codeReader = null; +let id = null; +let supportsVibrate = false; +let opt = null; +let inst = null; +let selectedDeviceId = null; +let deviceID = null; +let element = null; +let debug = false; +export function vibrate() { + if (supportsVibrate) navigator.vibrate(1000); +} +export function init(instance, ele, elementid, options, deviceid) { + console.log('init' + elementid); + inst = instance; + opt = options; + id = elementid; + deviceID = deviceid; + element = ele; + debug = options.debug; + supportsVibrate = "vibrate" in navigator; + let startButton = element.querySelector("[data-action=startButton]"); + let resetButton = element.querySelector("[data-action=resetButton]"); + let closeButton = element.querySelector("[data-action=closeButton]"); + + if (startButton) startButton.addEventListener('click', () => { + start(elementid); + }) + + if (resetButton) resetButton.addEventListener('click', () => { + stop(elementid); + if (debug) console.log('Reset.') + }) + + if (closeButton) closeButton.addEventListener('click', () => { + stop(elementid); + if (debug) console.log('closeButton.') + instance.invokeMethodAsync("CloseScan"); + }) + + load(elementid); +} + +export function reload(elementid) { + load(elementid); +} + +function genHints(opt) { + const hints = new Map(); + if (opt.TRY_HARDER) { + hints.set(ZXing.DecodeHintType.TRY_HARDER, opt.TRY_HARDER); + } + if (opt.ASSUME_CODE_39_CHECK_DIGIT) { + hints.set(ZXing.DecodeHintType.ASSUME_CODE_39_CHECK_DIGIT, opt.ASSUME_CODE_39_CHECK_DIGIT); + } + if (opt.ASSUME_GS1) { + hints.set(ZXing.DecodeHintType.ASSUME_GS1, opt.ASSUME_GS1); + } + if (opt.CHARACTER_SET) { + hints.set(ZXing.DecodeHintType.CHARACTER_SET, opt.CHARACTER_SET); + } + if (opt.OTHER) { + hints.set(ZXing.DecodeHintType.OTHER, opt.OTHER); + } + if (opt.PURE_BARCODE) { + hints.set(ZXing.DecodeHintType.PURE_BARCODE, opt.PURE_BARCODE); + } + if (opt.RETURN_CODABAR_START_END) { + hints.set(ZXing.DecodeHintType.RETURN_CODABAR_START_END, opt.RETURN_CODABAR_START_END); + } + if (opt.TRY_HARDER) { + hints.set(ZXing.DecodeHintType.TRY_HARDER, opt.TRY_HARDER); + } + return hints; +} + +export function load(elementid) { + if (id == elementid) { + + const sourceSelect = element.querySelector("[data-action=sourceSelect]"); + const sourceSelectPanel = element.querySelector("[data-action=sourceSelectPanel]"); + const hints = genHints(opt); + + if (opt.pdf417) { + codeReader = new ZXing.BrowserPDF417Reader(hints); + if (debug) console.log('ZXing code PDF417 reader initialized') + } else if (opt.decodeAllFormats) { + const formats = opt.formats; + hints.set(ZXing.DecodeHintType.POSSIBLE_FORMATS, formats); + codeReader = new ZXing.BrowserMultiFormatReader(hints) + if (debug) console.log('ZXing code reader initialized with all formats') + } else { + codeReader = new ZXing.BrowserMultiFormatReader(hints) + if (debug) console.log('ZXing code reader initialized') + } + codeReader.timeBetweenDecodingAttempts = opt.timeBetweenDecodingAttempts; + + if (navigator.mediaDevices && navigator.mediaDevices.getUserMedia) { + navigator.mediaDevices + .getUserMedia({ audio: false, video: true }) + .then(() => { + + codeReader.listVideoInputDevices() + .then((videoInputDevices) => { + if (deviceID != null) { + selectedDeviceId = deviceID + } else if (videoInputDevices.length > 1) { + selectedDeviceId = videoInputDevices[1].deviceId + } else { + selectedDeviceId = videoInputDevices[0].deviceId + } + if (debug) console.log('videoInputDevices:' + videoInputDevices.length); + if (videoInputDevices.length > 1) { + sourceSelect.innerHTML = ''; + videoInputDevices.forEach((device) => { + const sourceOption = document.createElement('option'); + if (device.label === '') { + sourceOption.text = 'Camera' + (sourceSelect.length + 1); + } else { + sourceOption.text = device.label + } + sourceOption.value = device.deviceId + if (selectedDeviceId != null && device.deviceId == selectedDeviceId) { + sourceOption.selected = true + } + sourceSelect.appendChild(sourceOption) + }) + + sourceSelect.onchange = () => { + selectedDeviceId = sourceSelect.value; + inst.invokeMethodAsync('SelectDeviceID', selectedDeviceId, sourceSelect.options[sourceSelect.selectedIndex].text); + codeReader.reset(); + start(elementid); + } + + sourceSelectPanel.style.display = 'block' + } + + start(elementid); + + }) + .catch((err) => { + console.log(err) + inst.invokeMethodAsync("GetError", err + ''); + }) + + }) + .catch((err) => { + console.error(`An error occurred: ${err}`); + inst.invokeMethodAsync('GetError', `An error occurred: ${err}`); + }); + + } + } +} + +export function start(elementid) { + if (undefined !== codeReader && null !== codeReader && id == elementid) { + if (opt.decodeonce) { + codeReader.decodeOnceFromVideoDevice(selectedDeviceId, 'video').then((result) => { + if (debug) console.log(result) + vibrate(); + if (debug) console.log('autostop'); + codeReader.reset(); + return inst.invokeMethodAsync("GetResult", result.text); + }).catch((err) => { + if (err && !(err instanceof ZXing.NotFoundException)) { + console.log(err) + inst.invokeMethodAsync("GetError", err + ''); + } + }) + } else { + codeReader.decodeFromVideoDevice(selectedDeviceId, 'video', (result, err) => { + if (result) { + if (debug) console.log(result) + vibrate(); + if (debug) console.log('None-stop'); + inst.invokeMethodAsync("GetResult", result.text); + } + if (err && !(err instanceof ZXing.NotFoundException)) { + console.log(err) + inst.invokeMethodAsync("GetError", err + ''); + } + }) + } + + var x = `decodeContinuously`; + if (opt.decodeonce) x = `decodeOnce`; + if (debug) console.log(`Started ` + x + ` decode from camera with id ${selectedDeviceId}`) + if (debug) console.log(id, 'start'); + } +} + +export function stop(elementid) { + if (undefined !== codeReader && null !== codeReader && id == elementid) { + codeReader.reset(); + if (debug) console.log(id, 'stop'); + } +} + +export function QRCodeSvg(instance, input, element, tobase64, size = 300) { + const codeWriter = new ZXing.BrowserQRCodeSvgWriter() + + if (debug) console.log('ZXing code writer initialized') + + if (tobase64) { + const elementTemp = document.createElement('elementTemp'); + codeWriter.writeToDom(elementTemp, input, size, size) + let svgElement = elementTemp.firstChild + const svgData = (new XMLSerializer()).serializeToString(svgElement) + //const blob = new Blob([svgData]) + instance.invokeMethodAsync("GetQRCode", svgData); + } else { + codeWriter.writeToDom(element.querySelector("[data-action=result]"), input, size, size) + } +} + +export function DecodeFormImage(instance, element, options, data) { + var codeReaderImage = null; + const hints = genHints(options); + if (options.pdf417) { + codeReaderImage = new ZXing.BrowserPDF417Reader(hints); + if (debug) console.log('ZXing code PDF417 reader initialized') + } else if (options.decodeAllFormats) { + const formats = options.formats; + hints.set(ZXing.DecodeHintType.POSSIBLE_FORMATS, formats); + codeReaderImage = new ZXing.BrowserMultiFormatReader(hints) + if (debug) console.log('ZXing code reader initialized with all formats') + } else { + codeReaderImage = new ZXing.BrowserMultiFormatReader(hints) + if (debug) console.log('ZXing code reader initialized') + } + if (debug) console.log('ZXing code reader initialized') + + if (data != null) { + codeReaderImage.decodeFromImageUrl(data).then(result => { + if (result) { + vibrate(); + if (debug) console.log(result.text); + instance.invokeMethodAsync('GetResult', result.text) + } + }).catch((err) => { + if (err) { + console.log(err) + instance.invokeMethodAsync('GetError', err.message) + } + }) + + } + else { + const resetFile = () => { + let file = element.querySelector('[type="file"]') + if (file) { + file.removeEventListener('change', scanImageHandler) + file.remove() + } + file = document.createElement('input') + file.setAttribute('type', 'file') + file.setAttribute('hidden', 'true') + file.setAttribute('accept', 'image/*') + //file.setAttribute('capture', 'true') + element.append(file) + file.addEventListener('change', scanImageHandler) + codeReaderImage.file = file + return file + } + + const scanImageHandler = () => { + const files = codeReaderImage.file.files + if (files.length === 0) { + return + } + + + const reader = new FileReader() + reader.onloadend = e => { + + codeReaderImage.decodeFromImageUrl(e.target.result).then(result => { + if (result) { + vibrate(); + if (debug) console.log(result.text); + instance.invokeMethodAsync('GetResult', result.text) + } else { + instance.invokeMethodAsync('GetError', "no valid barcode detected") + } + }).catch((err) => { + if (err) { + console.log(err) + instance.invokeMethodAsync('GetError', err.message) + } + }) + } + reader.readAsDataURL(files[0]) + } + + let file = resetFile() + file.click() + + } + +} + +export function destroy(elementid) { + if (undefined !== codeReader && null !== codeReader && id == elementid) { + codeReader.reset(); + codeReader = null; + //id = null; + id = null; + opt = null; + inst = null; + selectedDeviceId = null; + deviceID = null; + element = null; + if (debug) console.log(id, 'destroy'); + } +} \ No newline at end of file From 3890c6a100a4e959f2648ef4cddd1f22f924ed9e Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Wed, 15 Nov 2023 20:05:50 +0100 Subject: [PATCH 027/100] OK test riattrezzaggio --- MP-TAB-SERV/Components/OdlMan.razor | 22 +++- MP-TAB-SERV/Components/OdlMan.razor.cs | 2 +- MP-TAB-SERV/MP-TAB-SERV.csproj | 2 +- MP-TAB-SERV/Pages/RegNewDevice.razor | 1 - MP-TAB-SERV/Pages/StatusMap.razor.cs | 108 +++++++---------- MP-TAB-SERV/Pages/User.razor | 20 +--- MP-TAB-SERV/Resources/ChangeLog.html | 2 +- MP-TAB-SERV/Resources/VersNum.txt | 2 +- MP-TAB-SERV/Resources/manifest.xml | 2 +- MP.Data/Services/MessageService.cs | 159 ++++++++++++++----------- 10 files changed, 160 insertions(+), 160 deletions(-) diff --git a/MP-TAB-SERV/Components/OdlMan.razor b/MP-TAB-SERV/Components/OdlMan.razor index 68db7337..1b7e773a 100644 --- a/MP-TAB-SERV/Components/OdlMan.razor +++ b/MP-TAB-SERV/Components/OdlMan.razor @@ -13,7 +13,7 @@ @if (isSlave) {
                -
                +
                @(Traduci("lblWarnHeadSlave"))
                @(Traduci("lblWarnBodySlave"))
                @@ -23,6 +23,25 @@ { @if (needConfProd) { + @if (showSplitOdlOnTavVal || showReopOdlTav) + { +
                +
                +
                + @if (showSplitOdlOnTavVal) + { + + } +
                +
                + @if (showReopOdlTav) + { + + } +
                +
                +
                + }
                @lblWarnHead
                @@ -69,7 +88,6 @@ {
                -
                } diff --git a/MP-TAB-SERV/Components/OdlMan.razor.cs b/MP-TAB-SERV/Components/OdlMan.razor.cs index 229fbfc9..4edb6619 100644 --- a/MP-TAB-SERV/Components/OdlMan.razor.cs +++ b/MP-TAB-SERV/Components/OdlMan.razor.cs @@ -875,7 +875,7 @@ namespace MP_TAB_SERV.Components RecMSE = TabDServ.MseGetSub(IdxMaccParent, selIdxMacc, true); await ReloadData(true); await DoUpdate(); - if (showOdlDetail) + if (showOdlDetail || inAttr) { await ReloadXDL(true); } diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 5f9739f3..9d924d75 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.1417 + 6.16.2311.1519 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Pages/RegNewDevice.razor b/MP-TAB-SERV/Pages/RegNewDevice.razor index b6be7e2f..02700e89 100644 --- a/MP-TAB-SERV/Pages/RegNewDevice.razor +++ b/MP-TAB-SERV/Pages/RegNewDevice.razor @@ -23,7 +23,6 @@
                - @*
                *@
                diff --git a/MP-TAB-SERV/Pages/StatusMap.razor.cs b/MP-TAB-SERV/Pages/StatusMap.razor.cs index cbc1c392..13543c8b 100644 --- a/MP-TAB-SERV/Pages/StatusMap.razor.cs +++ b/MP-TAB-SERV/Pages/StatusMap.razor.cs @@ -10,6 +10,20 @@ namespace MP_TAB_SERV.Pages { public partial class StatusMap { + #region Public Classes + + public class WindowDimension + { + #region Public Properties + + public int Height { get; set; } + public int Width { get; set; } + + #endregion Public Properties + } + + #endregion Public Classes + #region Protected Fields protected bool _showCard = false; @@ -25,13 +39,18 @@ namespace MP_TAB_SERV.Pages [Inject] protected IConfiguration config { get; set; } = null!; + protected int Height { get; set; } = 0; + + protected bool isCalcSize { get; set; } = false; + + [Inject] + protected IJSRuntime JSRuntime { get; set; } = null!; + [Inject] protected StatusData MDataService { get; set; } = null!; [Inject] - protected MessageService MServ { get; set; } = null!; - [Inject] - protected IJSRuntime JSRuntime{ get; set; } = null!; + protected MessageService MsgServ { get; set; } = null!; protected bool ShowCard { @@ -46,50 +65,19 @@ namespace MP_TAB_SERV.Pages [Inject] protected TabDataService TabDServ { get; set; } = null!; + protected int Width { get; set; } = 0; + #endregion Protected Properties #region Protected Methods - /// - /// Recupera da conf eventuale setup tag dell'IOB indicato - /// - /// - /// - protected List? getIobTag(string codIob) + protected async Task getWDim() { - List? answ = null; - if (MDataService.currTagConf != null) - { - // cerco x chiave IOB... - if (MDataService.currTagConf.ContainsKey(codIob)) - { - answ = MDataService.currTagConf[codIob]; - } - } - return answ; + var dimension = await JSRuntime.InvokeAsync("getWindowDimensions"); + Height = dimension.Height; + Width = dimension.Width; } - /// - /// Recupera da redis (in una chiamata soltanto) tutti i valori richiesti e compone un - /// dizionario x ottimizzare visualizzazione - /// - /// - /// - protected Dictionary getTagVal(string codIob) - { - Dictionary answ = new Dictionary(); - // recupero conf tags... - var currTags = getIobTag(codIob); - if (currTags != null && currTags.Count > 0) - { - // FIXME TODO !!!! FARE !!!! - da verificare - answ = currTags.ToDictionary(x => x.TagLocation, x => MDataService.getTagConf(x.TagLocation)); - } - return answ; - } - - protected bool isCalcSize { get; set; } = false; - protected override async Task OnAfterRenderAsync(bool firstRender) { if (firstRender) @@ -102,24 +90,20 @@ namespace MP_TAB_SERV.Pages if (ListMSE != null) { // salvo in LocalStorage... - await MServ.SaveMse(ListMSE); + await MsgServ.SaveMse(ListMSE); } } protected override void OnInitialized() { - var df = MServ.UserPrefGet("DefCardMode"); - ShowCard = df == "shrink" ? false : true; - isCalcSize = true; + setDefaults(); ListMSE = null; SetupConf(); } protected void SaveData(List newList) { - //await Task.Delay(1); ListMSE = newList; - //await InvokeAsync(StateHasChanged); } #endregion Protected Methods @@ -140,6 +124,19 @@ namespace MP_TAB_SERV.Pages #region Private Methods + private void setDefaults() + { + string df = MsgServ.UserPrefSetup("DefCardMode", "full"); + baseLang = MsgServ.UserPrefSetup("Lang", "IT"); + tcMode = MsgServ.UserPrefSetup("TcMode", "ms"); + ShowCard = df == "shrink" ? false : true; + isCalcSize = true; + } + + + private string baseLang { get; set; } = ""; + private string tcMode { get; set; } = ""; + private void SetupConf() { // sistemo i parametri opzionali... @@ -149,24 +146,5 @@ namespace MP_TAB_SERV.Pages } #endregion Private Methods - - protected int Width { get; set; } = 0; - protected int Height { get; set; } = 0; - - public class WindowDimension - { - #region Public Properties - - public int Height { get; set; } - public int Width { get; set; } - - #endregion Public Properties - } - protected async Task getWDim() - { - var dimension = await JSRuntime.InvokeAsync("getWindowDimensions"); - Height = dimension.Height; - Width = dimension.Width; - } } } \ No newline at end of file diff --git a/MP-TAB-SERV/Pages/User.razor b/MP-TAB-SERV/Pages/User.razor index 31e65078..d23fee31 100644 --- a/MP-TAB-SERV/Pages/User.razor +++ b/MP-TAB-SERV/Pages/User.razor @@ -196,7 +196,7 @@ } } - protected string _langIns { get; set; } = ""; + protected string _langIns { get; set; } = "EN"; protected string langIns { @@ -246,21 +246,9 @@ } protected async override Task OnInitializedAsync() { - var tcPrefItem = MsgServ.UserPrefGet("TcMode"); - if (tcPrefItem != null) - { - tcModIns = tcPrefItem; - } - var langPrefItem = MsgServ.UserPrefGet("Lang"); - if (langPrefItem != null) - { - langIns = langPrefItem; - } - var defCardPrefItem = MsgServ.UserPrefGet("DefCardMode"); - if (defCardPrefItem != null) - { - defCardModeIns = defCardPrefItem; - } + tcModIns = MsgServ.UserPrefSetup("TcMode", "ms"); + langIns = MsgServ.UserPrefSetup("Lang", "IT"); + defCardModeIns = MsgServ.UserPrefSetup("DefCardMode", "full"); await Task.Delay(1); if (string.IsNullOrEmpty(currIpv4)) { diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 33605a51..3e4302c9 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.1417

                +

                Versione: 6.16.2311.1519


                Note di rilascio:
                • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index aa26489c..cc3607ab 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1417 +6.16.2311.1519 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index f30904f9..c7dfe782 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1417 + 6.16.2311.1519 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP.Data/Services/MessageService.cs b/MP.Data/Services/MessageService.cs index 34d750e1..d9ddde30 100644 --- a/MP.Data/Services/MessageService.cs +++ b/MP.Data/Services/MessageService.cs @@ -212,6 +212,32 @@ namespace MP.Data.Services await sessionStore.SetItemAsync(KeyCommText, Valore); } + public string DecryptData(string encData) + { + return SteamCrypto.DecryptString(encData, Constants.passPhrase); + } + + public string EncryptData(string rawData) + { + return SteamCrypto.EncryptString(rawData, Constants.passPhrase); + } + + /// + /// Restituisce il record OperatoreDTO da localstorage + /// + /// + public async Task GetCurrOperDtoAsync() + { + string answ = ""; + var result = await localStorage.GetItemAsync("currTkn"); + if (result != null) + { + //var data = JsonConvert.DeserializeObject(result); + answ = result; + } + return answ; + } + /// /// Restituisce il valore Ipv4 del Device da localstorage /// @@ -242,6 +268,21 @@ namespace MP.Data.Services return answ; } + /// + /// Restituisce ultima matrOpr registrata da localstorage + /// + /// + public async Task GetLastMatrOprAsync() + { + int answ = -1; + var result = await localStorage.GetItemAsync("lastMatrOpr"); + if (!string.IsNullOrEmpty(result)) + { + answ = int.Parse(result); + } + return answ; + } + /// /// Recupero dati MSE x macchina /// @@ -300,6 +341,18 @@ namespace MP.Data.Services return hasKey; } + /// + /// scrive il record OperatoreDTO nel localstorage + /// + /// + public async Task SetCurrOperDtoAsync(string currTkn) + { + bool answ = false; + await localStorage.SetItemAsync("currTkn", currTkn); + answ = true; + return answ; + } + /// /// Scrive il valore di IPV4 del device nel localstoragee /// @@ -340,6 +393,17 @@ namespace MP.Data.Services return answ; } + /// + /// Salva matrOpr nel localstorage + /// + /// + public async Task SetLastMatrOprAsync(int matrOpr) + { + bool answ = false; + await localStorage.SetItemAsync("lastMatrOpr", matrOpr); + answ = true; + return answ; + } /// /// Recupero singola preferenza utente @@ -379,6 +443,30 @@ namespace MP.Data.Services return done; } + /// + /// Recupero singola preferenza utente se presente, oppure imposto quella di default + /// indicata e la rendo + /// + /// + /// + public string UserPrefSetup(string chiave, string defValue) + { + string answ = defValue; + var currDict = UsersPrefDict; + if (currDict.ContainsKey(chiave)) + { + answ = currDict[chiave]; + } + else + { + if (MatrOpr > 0) + { + UserPrefSave(chiave, defValue); + } + } + return answ; + } + #endregion Public Methods #region Protected Fields @@ -410,18 +498,7 @@ namespace MP.Data.Services #region Private Fields - public string DecryptData(string encData) - { - return SteamCrypto.DecryptString(encData, Constants.passPhrase); - } - private AnagOperatoriModel? _rigaOper; - public string EncryptData(string rawData) - { - return SteamCrypto.EncryptString(rawData, Constants.passPhrase); - } - - /// /// Durata cache lunga IN SECONDI @@ -495,66 +572,6 @@ namespace MP.Data.Services return fatto; } - - /// - /// Restituisce il record OperatoreDTO da localstorage - /// - /// - public async Task GetCurrOperDtoAsync() - { - string answ = ""; - var result = await localStorage.GetItemAsync("currTkn"); - if (result != null) - { - //var data = JsonConvert.DeserializeObject(result); - answ = result; - } - return answ; - } - - /// - /// Restituisce ultima matrOpr registrata da localstorage - /// - /// - public async Task GetLastMatrOprAsync() - { - int answ = -1; - var result = await localStorage.GetItemAsync("lastMatrOpr"); - if (!string.IsNullOrEmpty(result)) - { - answ = int.Parse(result); - } - return answ; - } - - - /// - /// Salva matrOpr nel localstorage - /// - /// - public async Task SetLastMatrOprAsync(int matrOpr) - { - bool answ = false; - await localStorage.SetItemAsync("lastMatrOpr", matrOpr); - answ = true; - return answ; - } - - /// - /// scrive il record OperatoreDTO nel localstorage - /// - /// - public async Task SetCurrOperDtoAsync(string currTkn) - { - bool answ = false; - await localStorage.SetItemAsync("currTkn", currTkn); - answ = true; - return answ; - } - - - #endregion Private Methods - } } \ No newline at end of file From 68b65fb39f0c1897863f712ef6157fa6df55e003 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 10:12:20 +0100 Subject: [PATCH 028/100] cambiata gestione barcode reader --- MP-TAB-SERV/MP-TAB-SERV.csproj | 7 +++---- MP-TAB-SERV/Pages/RegNewDevice.razor | 1 - MP-TAB-SERV/Pages/RegNewDevice.razor.cs | 3 +-- MP-TAB-SERV/Resources/ChangeLog.html | 2 +- MP-TAB-SERV/Resources/VersNum.txt | 2 +- MP-TAB-SERV/Resources/manifest.xml | 2 +- 6 files changed, 7 insertions(+), 10 deletions(-) diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 6a2bf820..726679b9 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.1515 + 6.16.2311.1610 enable MP_TAB_SERV @@ -17,10 +17,9 @@ - - + + - diff --git a/MP-TAB-SERV/Pages/RegNewDevice.razor b/MP-TAB-SERV/Pages/RegNewDevice.razor index ad136c16..6833a663 100644 --- a/MP-TAB-SERV/Pages/RegNewDevice.razor +++ b/MP-TAB-SERV/Pages/RegNewDevice.razor @@ -1,5 +1,4 @@ @page "/reg-new-device" -@using ZXingBlazor.Components
                  QR-Scan USER LOGIN diff --git a/MP-TAB-SERV/Pages/RegNewDevice.razor.cs b/MP-TAB-SERV/Pages/RegNewDevice.razor.cs index d3d25f29..eb282c55 100644 --- a/MP-TAB-SERV/Pages/RegNewDevice.razor.cs +++ b/MP-TAB-SERV/Pages/RegNewDevice.razor.cs @@ -6,7 +6,6 @@ using MP.Data.DatabaseModels; using MP.Data.DTO; using MP.Data.Services; using Newtonsoft.Json; -using ZXingBlazor.Components; namespace MP_TAB_SERV.Pages { @@ -166,7 +165,7 @@ namespace MP_TAB_SERV.Pages private bool ShowScanBarcode { get; set; } = false; - protected BarcodeReader barcodeReaderCustom { get; set; } = null!; + protected EgwCoreLib.Razor.BarcodeReader barcodeReaderCustom { get; set; } = null!; #endregion Private Properties diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index fed77556..a87fed84 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.1515

                  +

                  Versione: 6.16.2311.1610


                  Note di rilascio:
                  • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 1c32dbea..cfe435a4 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1515 +6.16.2311.1610 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index 2231ee99..9adfd562 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1515 + 6.16.2311.1610 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From 2668f8ab59240a4f685d23af4c648113afc06e97 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 10:37:18 +0100 Subject: [PATCH 029/100] fix redirect post flush cache --- MP-TAB-SERV/Components/CmpTop.razor.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MP-TAB-SERV/Components/CmpTop.razor.cs b/MP-TAB-SERV/Components/CmpTop.razor.cs index 7eeea791..19dc63c4 100644 --- a/MP-TAB-SERV/Components/CmpTop.razor.cs +++ b/MP-TAB-SERV/Components/CmpTop.razor.cs @@ -112,7 +112,7 @@ namespace MP_TAB_SERV.Components // await InvokeAsync(StateHasChanged); Log.Info($"ForceReload completed in {sw.ElapsedMilliseconds}ms"); // ricarica pagina! - NavMan.NavigateTo("/", true); + NavMan.NavigateTo("status-map", true); } protected override async Task OnInitializedAsync() From f20ad5952c1819b9863c119b8d484895431dbddd Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 12:24:33 +0100 Subject: [PATCH 030/100] fix grafico --- 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-TAB-SERV/Shared/MainLayout.razor.css | 6 +++--- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 726679b9..bbeee8fb 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.1610 + 6.16.2311.1612 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index a87fed84..94b89c7d 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.1610

                    +

                    Versione: 6.16.2311.1612


                    Note di rilascio:
                    • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index cfe435a4..7d05e912 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1610 +6.16.2311.1612 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index 9adfd562..654147a1 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1610 + 6.16.2311.1612 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP-TAB-SERV/Shared/MainLayout.razor.css b/MP-TAB-SERV/Shared/MainLayout.razor.css index bea7a149..e22bf95a 100644 --- a/MP-TAB-SERV/Shared/MainLayout.razor.css +++ b/MP-TAB-SERV/Shared/MainLayout.razor.css @@ -23,11 +23,11 @@ main { #mainBody { width: 83%; } - #mainBodyNoSide { - width: 100%; - } } +#mainBodyNoSide { + width: 100%; +} @media (min-width: 641px) { .page { From 4aedfe9c7a862075b07d048b69f0f6b009158687 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 12:32:07 +0100 Subject: [PATCH 031/100] aggiornato pacchetto egwcorelib --- MP-TAB-SERV/MP-TAB-SERV.csproj | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index bbeee8fb..a2c67544 100644 --- a/MP-TAB-SERV/MP-TAB-SERV.csproj +++ b/MP-TAB-SERV/MP-TAB-SERV.csproj @@ -17,8 +17,8 @@ - - + + From 6f29589833d6ce6c690a6a79f40b24568506e634 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 15:32:50 +0100 Subject: [PATCH 032/100] prova compilazione condizionale --- .gitlab-ci.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index f731a786..f19d74dc 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -199,6 +199,8 @@ TAB3:build: - dotnet restore "$env:SOL_NAME.sln" script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj + when: + branch: 'match(${{CF_BRANCH}}, "..$env:APP_NAME.", true)' # ----- Start DEPLOY develop (IIS01) ----- @@ -354,6 +356,8 @@ TAB3:IIS01:deploy: script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj - dotnet publish -p:PublishProfile=IIS01.pubxml -p:RunCodeAnalysis=false -p:Configuration=Release -p:username=jenkins -p:Password=$IIS_PASSWD -p:AllowUntrustedCertificate=true -p:verbosity=quiet $env:APP_NAME/$env:APP_NAME.csproj + when: + branch: 'match(${{CF_BRANCH}}, "..$env:APP_NAME.", true)' # ----- Start DEPLOY master (IIS02/IIS04) ----- LAND:IIS02:deploy: From a9805a51ddb8d00e19aca2e3ef046d2d11aae2b1 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 15:45:49 +0100 Subject: [PATCH 033/100] prova compilazione condizionale con rule --- .gitlab-ci.yml | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index f19d74dc..386d0f43 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -197,10 +197,10 @@ TAB3:build: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" + rules: + if: ${{CF_BRANCH}} -match "$env:APP_NAME" script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj - when: - branch: 'match(${{CF_BRANCH}}, "..$env:APP_NAME.", true)' # ----- Start DEPLOY develop (IIS01) ----- @@ -350,14 +350,17 @@ TAB3:IIS01:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop + rules: + if: ${{CF_BRANCH}} -match "$env:APP_NAME" + # only: + # - develop needs: ["TAB3:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj - dotnet publish -p:PublishProfile=IIS01.pubxml -p:RunCodeAnalysis=false -p:Configuration=Release -p:username=jenkins -p:Password=$IIS_PASSWD -p:AllowUntrustedCertificate=true -p:verbosity=quiet $env:APP_NAME/$env:APP_NAME.csproj - when: - branch: 'match(${{CF_BRANCH}}, "..$env:APP_NAME.", true)' + # when: + # branch: + # - ${{CF_BRANCH}} -match # ----- Start DEPLOY master (IIS02/IIS04) ----- LAND:IIS02:deploy: From 4ab25b80331e4b8fd85c7db2d7fa15f0db171127 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 15:48:48 +0100 Subject: [PATCH 034/100] fix trattini mancanti per if --- .gitlab-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 386d0f43..da56c4f5 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -198,7 +198,7 @@ TAB3:build: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" rules: - if: ${{CF_BRANCH}} -match "$env:APP_NAME" + - if: ${{CF_BRANCH}} -match "$env:APP_NAME" script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -351,7 +351,7 @@ TAB3:IIS01:deploy: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" rules: - if: ${{CF_BRANCH}} -match "$env:APP_NAME" + - if: ${{CF_BRANCH}} -match "$env:APP_NAME" # only: # - develop needs: ["TAB3:build"] From f70ecc8518e3b186d3a422e64c02047584cf3054 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 15:52:57 +0100 Subject: [PATCH 035/100] prova fix IF statement --- .gitlab-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index da56c4f5..3158eebc 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -198,7 +198,7 @@ TAB3:build: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" rules: - - if: ${{CF_BRANCH}} -match "$env:APP_NAME" + - if: 'CI_COMMIT_BRANCH -match "$env:APP_NAME"' script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -351,7 +351,7 @@ TAB3:IIS01:deploy: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" rules: - - if: ${{CF_BRANCH}} -match "$env:APP_NAME" + - if: 'CI_COMMIT_BRANCH -match "$env:APP_NAME"' # only: # - develop needs: ["TAB3:build"] From 6e81ae6065b0c9601b97be40a4318fac97c54b18 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 15:54:46 +0100 Subject: [PATCH 036/100] cambiata posizione regole --- .gitlab-ci.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 3158eebc..b90c293b 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -197,10 +197,10 @@ TAB3:build: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - rules: - - if: 'CI_COMMIT_BRANCH -match "$env:APP_NAME"' script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj + rules: + - if: 'CI_COMMIT_BRANCH -match "$env:APP_NAME"' # ----- Start DEPLOY develop (IIS01) ----- @@ -349,15 +349,15 @@ TAB3:IIS01:deploy: SOL_NAME: MP-TAB3 before_script: - *nuget-fix - - dotnet restore "$env:SOL_NAME.sln" - rules: - - if: 'CI_COMMIT_BRANCH -match "$env:APP_NAME"' # only: # - develop needs: ["TAB3:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj - dotnet publish -p:PublishProfile=IIS01.pubxml -p:RunCodeAnalysis=false -p:Configuration=Release -p:username=jenkins -p:Password=$IIS_PASSWD -p:AllowUntrustedCertificate=true -p:verbosity=quiet $env:APP_NAME/$env:APP_NAME.csproj + - dotnet restore "$env:SOL_NAME.sln" + rules: + - if: 'CI_COMMIT_BRANCH -match "$env:APP_NAME"' # when: # branch: # - ${{CF_BRANCH}} -match From d9fc308b08ceec884d125de7110d4e47d2372be9 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 16:00:24 +0100 Subject: [PATCH 037/100] tentativo con 'only' --- .gitlab-ci.yml | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index b90c293b..7972263f 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -197,10 +197,12 @@ TAB3:build: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" + only: + variables: [CI_COMMIT_BRANCH -match "$env:APP_NAME"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj - rules: - - if: 'CI_COMMIT_BRANCH -match "$env:APP_NAME"' + # rules: + # - if: 'CI_COMMIT_BRANCH -match "$env:APP_NAME"' # ----- Start DEPLOY develop (IIS01) ----- @@ -349,15 +351,15 @@ TAB3:IIS01:deploy: SOL_NAME: MP-TAB3 before_script: - *nuget-fix - # only: - # - develop + only: + variables: [CI_COMMIT_BRANCH -match "$env:APP_NAME"] needs: ["TAB3:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj - dotnet publish -p:PublishProfile=IIS01.pubxml -p:RunCodeAnalysis=false -p:Configuration=Release -p:username=jenkins -p:Password=$IIS_PASSWD -p:AllowUntrustedCertificate=true -p:verbosity=quiet $env:APP_NAME/$env:APP_NAME.csproj - dotnet restore "$env:SOL_NAME.sln" - rules: - - if: 'CI_COMMIT_BRANCH -match "$env:APP_NAME"' + # rules: + # - if: 'CI_COMMIT_BRANCH -match "$env:APP_NAME"' # when: # branch: # - ${{CF_BRANCH}} -match From 3af09ee2b27edf2dbff72f3a7a21e607132b7b6d Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 17:02:09 +0100 Subject: [PATCH 038/100] forse fix chiamata variabile --- .gitlab-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 7972263f..063210dc 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -198,7 +198,7 @@ TAB3:build: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" only: - variables: [CI_COMMIT_BRANCH -match "$env:APP_NAME"] + variables: [$CI_COMMIT_BRANCH -match "$env:APP_NAME"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj # rules: @@ -352,7 +352,7 @@ TAB3:IIS01:deploy: before_script: - *nuget-fix only: - variables: [CI_COMMIT_BRANCH -match "$env:APP_NAME"] + variables: [$CI_COMMIT_BRANCH -match "$env:APP_NAME"] needs: ["TAB3:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj From 6c85108a6da70efc3124b7e34ad9d8c49b024156 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 17:03:12 +0100 Subject: [PATCH 039/100] aggiunte virgolette --- .gitlab-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 063210dc..c57ffaf4 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -198,7 +198,7 @@ TAB3:build: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" only: - variables: [$CI_COMMIT_BRANCH -match "$env:APP_NAME"] + variables: ["$CI_COMMIT_BRANCH" -match "$env:APP_NAME"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj # rules: @@ -352,7 +352,7 @@ TAB3:IIS01:deploy: before_script: - *nuget-fix only: - variables: [$CI_COMMIT_BRANCH -match "$env:APP_NAME"] + variables: ["$CI_COMMIT_BRANCH" -match "$env:APP_NAME"] needs: ["TAB3:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj From 2200397674d029e315390fed998187f7d3872207 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 17:04:44 +0100 Subject: [PATCH 040/100] tolte parentesi quadre --- .gitlab-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index c57ffaf4..dcb31cee 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -198,7 +198,7 @@ TAB3:build: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" only: - variables: ["$CI_COMMIT_BRANCH" -match "$env:APP_NAME"] + variables: "$CI_COMMIT_BRANCH" -match "$env:APP_NAME" script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj # rules: @@ -352,7 +352,7 @@ TAB3:IIS01:deploy: before_script: - *nuget-fix only: - variables: ["$CI_COMMIT_BRANCH" -match "$env:APP_NAME"] + variables: "$CI_COMMIT_BRANCH" -match "$env:APP_NAME" needs: ["TAB3:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj From bb8e97a8e3e78872461537906daaeb0c250828fb Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 17:06:44 +0100 Subject: [PATCH 041/100] aggiunte virgolette singole --- .gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index dcb31cee..362745ca 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -352,7 +352,7 @@ TAB3:IIS01:deploy: before_script: - *nuget-fix only: - variables: "$CI_COMMIT_BRANCH" -match "$env:APP_NAME" + variables: '"$CI_COMMIT_BRANCH" -match "$env:APP_NAME"' needs: ["TAB3:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj From 03bcaca6f47374385a00552690f7017e5d1ef13c Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 17:07:48 +0100 Subject: [PATCH 042/100] ancora --- .gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 362745ca..fa2a4f17 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -198,7 +198,7 @@ TAB3:build: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" only: - variables: "$CI_COMMIT_BRANCH" -match "$env:APP_NAME" + variables: '"$CI_COMMIT_BRANCH" -match "$env:APP_NAME"' script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj # rules: From b87c919fda87f9b656261bf802186803c2393155 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 16 Nov 2023 17:10:34 +0100 Subject: [PATCH 043/100] tornato alla situazione iniziale funzionante --- .gitlab-ci.yml | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index fa2a4f17..f731a786 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -197,12 +197,8 @@ TAB3:build: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - variables: '"$CI_COMMIT_BRANCH" -match "$env:APP_NAME"' script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj - # rules: - # - if: 'CI_COMMIT_BRANCH -match "$env:APP_NAME"' # ----- Start DEPLOY develop (IIS01) ----- @@ -351,18 +347,13 @@ TAB3:IIS01:deploy: SOL_NAME: MP-TAB3 before_script: - *nuget-fix + - dotnet restore "$env:SOL_NAME.sln" only: - variables: '"$CI_COMMIT_BRANCH" -match "$env:APP_NAME"' + - develop needs: ["TAB3:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj - dotnet publish -p:PublishProfile=IIS01.pubxml -p:RunCodeAnalysis=false -p:Configuration=Release -p:username=jenkins -p:Password=$IIS_PASSWD -p:AllowUntrustedCertificate=true -p:verbosity=quiet $env:APP_NAME/$env:APP_NAME.csproj - - dotnet restore "$env:SOL_NAME.sln" - # rules: - # - if: 'CI_COMMIT_BRANCH -match "$env:APP_NAME"' - # when: - # branch: - # - ${{CF_BRANCH}} -match # ----- Start DEPLOY master (IIS02/IIS04) ----- LAND:IIS02:deploy: From 492e59f6d5f1f76478c648459c326c7d5fba147a Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Thu, 16 Nov 2023 19:32:17 +0100 Subject: [PATCH 044/100] Update shadows x LAND --- .gitlab-ci.yml | 1 + MP.Land/Components/CmpFooter.razor | 2 +- MP.Land/MP.Land.csproj | 4 +- MP.Land/Pages/About.razor | 30 ++++++------ MP.Land/Pages/Contacts.razor | 4 +- MP.Land/Pages/Index.razor | 4 +- MP.Land/Pages/SysInfo.razor | 4 +- MP.Land/Pages/UpdateManager.razor | 4 +- MP.Land/Pages/UserQr.razor | 2 +- MP.Land/Resources/ChangeLog.html | 2 +- MP.Land/Resources/VersNum.txt | 2 +- MP.Land/Resources/manifest.xml | 2 +- MP.Land/wwwroot/img/LogoEgalware.svg | 21 +++++++++ MP.Land/wwwroot/img/LogoEgalwareBianco.svg | 55 ++++++++++++++++++++++ 14 files changed, 108 insertions(+), 29 deletions(-) create mode 100644 MP.Land/wwwroot/img/LogoEgalware.svg create mode 100644 MP.Land/wwwroot/img/LogoEgalwareBianco.svg diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index f731a786..33c96601 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -214,6 +214,7 @@ LAND:IIS01:deploy: - dotnet restore "$env:SOL_NAME.sln" only: - develop + - feature\/LAND.+ needs: ["LAND:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj diff --git a/MP.Land/Components/CmpFooter.razor b/MP.Land/Components/CmpFooter.razor index 75e13002..1ba50c22 100644 --- a/MP.Land/Components/CmpFooter.razor +++ b/MP.Land/Components/CmpFooter.razor @@ -4,7 +4,7 @@
                  @adesso - Egalware + Egalware  
                diff --git a/MP.Land/MP.Land.csproj b/MP.Land/MP.Land.csproj index 2cc99106..424ea1e4 100644 --- a/MP.Land/MP.Land.csproj +++ b/MP.Land/MP.Land.csproj @@ -3,7 +3,7 @@ net6.0 MP.Land - 6.16.2311.1009 + 6.16.2311.1619 @@ -44,6 +44,8 @@ + + diff --git a/MP.Land/Pages/About.razor b/MP.Land/Pages/About.razor index 945c6f4d..58a78d18 100644 --- a/MP.Land/Pages/About.razor +++ b/MP.Land/Pages/About.razor @@ -6,7 +6,7 @@
                -
                +
                @@ -16,7 +16,7 @@ @@ -41,51 +41,51 @@

                Info installazione


                -
                +
                Remote Server:
                -
                +
                @ServerStatus
                -
                +
                Cliente:
                -
                +
                @Installazione
                -
                +
                App:
                -
                +
                @Applicazione
                -
                +
                Licenze:
                -
                +
                @Licenze
                -
                +
                Scadenza:
                -
                +
                @($"{Scadenza:yyyy/MM/dd}")
                -
                +
                Key
                -
                - @MastKey +
                +
                diff --git a/MP.Land/Pages/Contacts.razor b/MP.Land/Pages/Contacts.razor index d621d0db..0c2f4157 100644 --- a/MP.Land/Pages/Contacts.razor +++ b/MP.Land/Pages/Contacts.razor @@ -5,7 +5,7 @@
                -
                +
                @@ -15,7 +15,7 @@ diff --git a/MP.Land/Pages/Index.razor b/MP.Land/Pages/Index.razor index 1d0d640f..95835196 100644 --- a/MP.Land/Pages/Index.razor +++ b/MP.Land/Pages/Index.razor @@ -3,7 +3,7 @@ @using MP.Land.Data @using MP.Land.Components -
                +

                MAPO Land

                @@ -24,7 +24,7 @@
                -
                +
                @if (ListRecords == null) { diff --git a/MP.Land/Pages/SysInfo.razor b/MP.Land/Pages/SysInfo.razor index f4e8ffe2..810db569 100644 --- a/MP.Land/Pages/SysInfo.razor +++ b/MP.Land/Pages/SysInfo.razor @@ -9,7 +9,7 @@
                -
                +
                @@ -19,7 +19,7 @@ diff --git a/MP.Land/Pages/UpdateManager.razor b/MP.Land/Pages/UpdateManager.razor index 454cea83..8e50d9b2 100644 --- a/MP.Land/Pages/UpdateManager.razor +++ b/MP.Land/Pages/UpdateManager.razor @@ -4,7 +4,7 @@ @using MP.Land.Components @inject LicenseService LicServ -
                +
                @@ -43,7 +43,7 @@
                } -
                +
                @if (ListRecords == null) { diff --git a/MP.Land/Pages/UserQr.razor b/MP.Land/Pages/UserQr.razor index 9f46b8c4..02a5b38c 100644 --- a/MP.Land/Pages/UserQr.razor +++ b/MP.Land/Pages/UserQr.razor @@ -3,7 +3,7 @@ @using MP.Land.Data @using MP.Land.Components -
                +
                @if (ListRecords == null) diff --git a/MP.Land/Resources/ChangeLog.html b/MP.Land/Resources/ChangeLog.html index 2076f49f..609a99c8 100644 --- a/MP.Land/Resources/ChangeLog.html +++ b/MP.Land/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo gestione Programmi MAPO -

                Versione: 6.16.2311.1009

                +

                Versione: 6.16.2311.1619


                Note di rilascio:
                  diff --git a/MP.Land/Resources/VersNum.txt b/MP.Land/Resources/VersNum.txt index cf39a0ed..1cc366fe 100644 --- a/MP.Land/Resources/VersNum.txt +++ b/MP.Land/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1009 +6.16.2311.1619 diff --git a/MP.Land/Resources/manifest.xml b/MP.Land/Resources/manifest.xml index e09e8ed5..faf03670 100644 --- a/MP.Land/Resources/manifest.xml +++ b/MP.Land/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1009 + 6.16.2311.1619 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.Land/wwwroot/img/LogoEgalware.svg b/MP.Land/wwwroot/img/LogoEgalware.svg new file mode 100644 index 00000000..afcdb10c --- /dev/null +++ b/MP.Land/wwwroot/img/LogoEgalware.svg @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/MP.Land/wwwroot/img/LogoEgalwareBianco.svg b/MP.Land/wwwroot/img/LogoEgalwareBianco.svg new file mode 100644 index 00000000..acb59f58 --- /dev/null +++ b/MP.Land/wwwroot/img/LogoEgalwareBianco.svg @@ -0,0 +1,55 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 374cb3478d771b508fa462469bcb911ddd192816 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Thu, 16 Nov 2023 19:35:19 +0100 Subject: [PATCH 045/100] test recogn feature --- .gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 33c96601..9cdea2ee 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -214,7 +214,7 @@ LAND:IIS01:deploy: - dotnet restore "$env:SOL_NAME.sln" only: - develop - - feature\/LAND.+ + - /^feature\/LAND.+ needs: ["LAND:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj From ac883d85d5c011f82ab2aa85d75b6ae408ba2956 Mon Sep 17 00:00:00 2001 From: Samuele Emilio Locatelli Date: Thu, 16 Nov 2023 18:38:09 +0000 Subject: [PATCH 046/100] Update .gitlab-ci.yml file --- .gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 9cdea2ee..0fba5e4b 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -214,7 +214,7 @@ LAND:IIS01:deploy: - dotnet restore "$env:SOL_NAME.sln" only: - develop - - /^feature\/LAND.+ + - .+LAND.+ needs: ["LAND:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj From 8edd19a5f3a1debe4343ccb598d55f640cdc8347 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 17 Nov 2023 08:39:11 +0100 Subject: [PATCH 047/100] update test yaml syntax --- .gitlab-ci.yml | 46 +++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 43 insertions(+), 3 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 0fba5e4b..2885c836 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -90,6 +90,10 @@ LAND:build: variables: APP_NAME: MP.Land SOL_NAME: MP-LAND + rules: + - if: $CI_COMMIT_BRANCH == develop + - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH =~ /^feature/LAND* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -103,6 +107,10 @@ PROG:build: variables: APP_NAME: MP.Prog SOL_NAME: MP-PROG + rules: + - if: $CI_COMMIT_BRANCH == develop + - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH =~ /^feature/PROG* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -116,6 +124,10 @@ STAT:build: variables: APP_NAME: MP.Stats SOL_NAME: MP-STATS + rules: + - if: $CI_COMMIT_BRANCH == develop + - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH =~ /^feature/STAT* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -129,6 +141,10 @@ MON:build: variables: APP_NAME: MP.Mon SOL_NAME: MP-MON + rules: + - if: $CI_COMMIT_BRANCH == develop + - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH =~ /^feature/MON* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -142,6 +158,10 @@ SPEC:build: variables: APP_NAME: MP.SPEC SOL_NAME: MP-SPEC + rules: + - if: $CI_COMMIT_BRANCH == develop + - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH =~ /^feature/SPEC* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -155,6 +175,10 @@ INVE:build: variables: APP_NAME: MP.INVE SOL_NAME: MP-INVE + rules: + - if: $CI_COMMIT_BRANCH == develop + - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH =~ /^feature/INVE* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -168,6 +192,10 @@ CONF:build: variables: APP_NAME: IobConf.UI SOL_NAME: IobConf + rules: + - if: $CI_COMMIT_BRANCH == develop + - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH =~ /^feature/CONF* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -181,6 +209,10 @@ IOC:build: variables: APP_NAME: MP.IOC SOL_NAME: MP-IOC + rules: + - if: $CI_COMMIT_BRANCH == develop + - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH =~ /^feature/IOC* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -194,6 +226,10 @@ TAB3:build: variables: APP_NAME: MP-TAB-SERV SOL_NAME: MP-TAB3 + rules: + - if: $CI_COMMIT_BRANCH == develop + - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH =~ /^feature/TAB* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -212,9 +248,13 @@ LAND:IIS01:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop - - .+LAND.+ + # only: + # - develop + # - feature/LAND.+ + rules: + - if: $CI_COMMIT_BRANCH == develop + - if: $CI_COMMIT_BRANCH =~ /^feature/LAND* + needs: ["LAND:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj From 4133c5b4e1738aa4bd5c8bb723a6137b5f54692e Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 17 Nov 2023 08:45:40 +0100 Subject: [PATCH 048/100] Update syntax --- .gitlab-ci.yml | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2885c836..d77141c6 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -91,8 +91,8 @@ LAND:build: APP_NAME: MP.Land SOL_NAME: MP-LAND rules: - - if: $CI_COMMIT_BRANCH == develop - - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH == "develop" + - if: $CI_COMMIT_BRANCH == "master" - if: $CI_COMMIT_BRANCH =~ /^feature/LAND* before_script: - *nuget-fix @@ -108,8 +108,8 @@ PROG:build: APP_NAME: MP.Prog SOL_NAME: MP-PROG rules: - - if: $CI_COMMIT_BRANCH == develop - - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH == "develop" + - if: $CI_COMMIT_BRANCH == "master" - if: $CI_COMMIT_BRANCH =~ /^feature/PROG* before_script: - *nuget-fix @@ -125,8 +125,8 @@ STAT:build: APP_NAME: MP.Stats SOL_NAME: MP-STATS rules: - - if: $CI_COMMIT_BRANCH == develop - - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH == "develop" + - if: $CI_COMMIT_BRANCH == "master" - if: $CI_COMMIT_BRANCH =~ /^feature/STAT* before_script: - *nuget-fix @@ -142,8 +142,8 @@ MON:build: APP_NAME: MP.Mon SOL_NAME: MP-MON rules: - - if: $CI_COMMIT_BRANCH == develop - - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH == "develop" + - if: $CI_COMMIT_BRANCH == "master" - if: $CI_COMMIT_BRANCH =~ /^feature/MON* before_script: - *nuget-fix @@ -159,8 +159,8 @@ SPEC:build: APP_NAME: MP.SPEC SOL_NAME: MP-SPEC rules: - - if: $CI_COMMIT_BRANCH == develop - - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH == "develop" + - if: $CI_COMMIT_BRANCH == "master" - if: $CI_COMMIT_BRANCH =~ /^feature/SPEC* before_script: - *nuget-fix @@ -176,8 +176,8 @@ INVE:build: APP_NAME: MP.INVE SOL_NAME: MP-INVE rules: - - if: $CI_COMMIT_BRANCH == develop - - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH == "develop" + - if: $CI_COMMIT_BRANCH == "master" - if: $CI_COMMIT_BRANCH =~ /^feature/INVE* before_script: - *nuget-fix @@ -193,8 +193,8 @@ CONF:build: APP_NAME: IobConf.UI SOL_NAME: IobConf rules: - - if: $CI_COMMIT_BRANCH == develop - - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH == "develop" + - if: $CI_COMMIT_BRANCH == "master" - if: $CI_COMMIT_BRANCH =~ /^feature/CONF* before_script: - *nuget-fix @@ -210,8 +210,8 @@ IOC:build: APP_NAME: MP.IOC SOL_NAME: MP-IOC rules: - - if: $CI_COMMIT_BRANCH == develop - - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH == "develop" + - if: $CI_COMMIT_BRANCH == "master" - if: $CI_COMMIT_BRANCH =~ /^feature/IOC* before_script: - *nuget-fix @@ -227,8 +227,8 @@ TAB3:build: APP_NAME: MP-TAB-SERV SOL_NAME: MP-TAB3 rules: - - if: $CI_COMMIT_BRANCH == develop - - if: $CI_COMMIT_BRANCH == master + - if: $CI_COMMIT_BRANCH == "develop" + - if: $CI_COMMIT_BRANCH == "master" - if: $CI_COMMIT_BRANCH =~ /^feature/TAB* before_script: - *nuget-fix @@ -252,7 +252,7 @@ LAND:IIS01:deploy: # - develop # - feature/LAND.+ rules: - - if: $CI_COMMIT_BRANCH == develop + - if: $CI_COMMIT_BRANCH == "develop" - if: $CI_COMMIT_BRANCH =~ /^feature/LAND* needs: ["LAND:build"] From 066bdf911b3a6cc08b1077c90b0d231a5d4abf83 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 17 Nov 2023 08:47:55 +0100 Subject: [PATCH 049/100] update yaml --- .gitlab-ci.yml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index d77141c6..638e8768 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -93,7 +93,7 @@ LAND:build: rules: - if: $CI_COMMIT_BRANCH == "develop" - if: $CI_COMMIT_BRANCH == "master" - - if: $CI_COMMIT_BRANCH =~ /^feature/LAND* + - if: $CI_COMMIT_BRANCH =~ "/^feature/LAND.+" before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -110,7 +110,7 @@ PROG:build: rules: - if: $CI_COMMIT_BRANCH == "develop" - if: $CI_COMMIT_BRANCH == "master" - - if: $CI_COMMIT_BRANCH =~ /^feature/PROG* + # - if: $CI_COMMIT_BRANCH =~ /^feature/PROG* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -127,7 +127,7 @@ STAT:build: rules: - if: $CI_COMMIT_BRANCH == "develop" - if: $CI_COMMIT_BRANCH == "master" - - if: $CI_COMMIT_BRANCH =~ /^feature/STAT* + # - if: $CI_COMMIT_BRANCH =~ /^feature/STAT* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -144,7 +144,7 @@ MON:build: rules: - if: $CI_COMMIT_BRANCH == "develop" - if: $CI_COMMIT_BRANCH == "master" - - if: $CI_COMMIT_BRANCH =~ /^feature/MON* + # - if: $CI_COMMIT_BRANCH =~ /^feature/MON* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -161,7 +161,7 @@ SPEC:build: rules: - if: $CI_COMMIT_BRANCH == "develop" - if: $CI_COMMIT_BRANCH == "master" - - if: $CI_COMMIT_BRANCH =~ /^feature/SPEC* + # - if: $CI_COMMIT_BRANCH =~ /^feature/SPEC* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -178,7 +178,7 @@ INVE:build: rules: - if: $CI_COMMIT_BRANCH == "develop" - if: $CI_COMMIT_BRANCH == "master" - - if: $CI_COMMIT_BRANCH =~ /^feature/INVE* + # - if: $CI_COMMIT_BRANCH =~ /^feature/INVE* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -195,7 +195,7 @@ CONF:build: rules: - if: $CI_COMMIT_BRANCH == "develop" - if: $CI_COMMIT_BRANCH == "master" - - if: $CI_COMMIT_BRANCH =~ /^feature/CONF* + # - if: $CI_COMMIT_BRANCH =~ /^feature/CONF* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -212,7 +212,7 @@ IOC:build: rules: - if: $CI_COMMIT_BRANCH == "develop" - if: $CI_COMMIT_BRANCH == "master" - - if: $CI_COMMIT_BRANCH =~ /^feature/IOC* + # - if: $CI_COMMIT_BRANCH =~ /^feature/IOC* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -229,7 +229,7 @@ TAB3:build: rules: - if: $CI_COMMIT_BRANCH == "develop" - if: $CI_COMMIT_BRANCH == "master" - - if: $CI_COMMIT_BRANCH =~ /^feature/TAB* + # - if: $CI_COMMIT_BRANCH =~ /^feature/TAB* before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -253,7 +253,7 @@ LAND:IIS01:deploy: # - feature/LAND.+ rules: - if: $CI_COMMIT_BRANCH == "develop" - - if: $CI_COMMIT_BRANCH =~ /^feature/LAND* + - if: $CI_COMMIT_BRANCH =~ "/^feature/LAND.+" needs: ["LAND:build"] script: From 9e8a94c94e5d69c4973c03f071d29bcf2d57c7ac Mon Sep 17 00:00:00 2001 From: Samuele Emilio Locatelli Date: Fri, 17 Nov 2023 08:08:41 +0000 Subject: [PATCH 050/100] Update .gitlab-ci.yml file --- .gitlab-ci.yml | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 638e8768..b2eaea8a 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -91,13 +91,16 @@ LAND:build: APP_NAME: MP.Land SOL_NAME: MP-LAND rules: - - if: $CI_COMMIT_BRANCH == "develop" - - if: $CI_COMMIT_BRANCH == "master" - - if: $CI_COMMIT_BRANCH =~ "/^feature/LAND.+" + # - if: $CI_COMMIT_BRANCH =~ /^feature/ + # when: never + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH == 'master' + # - if: $CI_COMMIT_BRANCH =~ /^feature/LAND.+/ before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" script: + - echo $CI_COMMIT_BRANCH - dotnet build $env:APP_NAME/$env:APP_NAME.csproj PROG:build: @@ -108,9 +111,11 @@ PROG:build: APP_NAME: MP.Prog SOL_NAME: MP-PROG rules: + - if: $CI_COMMIT_BRANCH =~ "feature/" + when: never - if: $CI_COMMIT_BRANCH == "develop" - if: $CI_COMMIT_BRANCH == "master" - # - if: $CI_COMMIT_BRANCH =~ /^feature/PROG* + - if: $CI_COMMIT_BRANCH =~ "feature/PROG.+" before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" From 2d68d35cdab23a5332344930d557b50f95b550be Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 17 Nov 2023 09:10:47 +0100 Subject: [PATCH 051/100] altro test yaml --- .gitlab-ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index b2eaea8a..505e7d2a 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -91,11 +91,11 @@ LAND:build: APP_NAME: MP.Land SOL_NAME: MP-LAND rules: - # - if: $CI_COMMIT_BRANCH =~ /^feature/ - # when: never + - if: $CI_COMMIT_BRANCH =~ /^feature/ + when: never - if: $CI_COMMIT_BRANCH == 'develop' - if: $CI_COMMIT_BRANCH == 'master' - # - if: $CI_COMMIT_BRANCH =~ /^feature/LAND.+/ + - if: $CI_COMMIT_BRANCH =~ /^feature/LAND.+/ before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" From 3f29166c0efc57d38b51be28c17cf66fdb234e39 Mon Sep 17 00:00:00 2001 From: Samuele Emilio Locatelli Date: Fri, 17 Nov 2023 08:11:45 +0000 Subject: [PATCH 052/100] Update .gitlab-ci.yml file --- .gitlab-ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 505e7d2a..112846b3 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -91,11 +91,11 @@ LAND:build: APP_NAME: MP.Land SOL_NAME: MP-LAND rules: - - if: $CI_COMMIT_BRANCH =~ /^feature/ - when: never + # - if: $CI_COMMIT_BRANCH =~ /^feature/ + # when: never - if: $CI_COMMIT_BRANCH == 'develop' - if: $CI_COMMIT_BRANCH == 'master' - - if: $CI_COMMIT_BRANCH =~ /^feature/LAND.+/ + - if: $CI_COMMIT_BRANCH =~ 'feature/LAND.+' before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" From 14477c59282f682bc000be14973407d6672aa84e Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 17 Nov 2023 09:14:17 +0100 Subject: [PATCH 053/100] cambio sintassi --- .gitlab-ci.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 112846b3..d29c6611 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -95,7 +95,8 @@ LAND:build: # when: never - if: $CI_COMMIT_BRANCH == 'develop' - if: $CI_COMMIT_BRANCH == 'master' - - if: $CI_COMMIT_BRANCH =~ 'feature/LAND.+' + - if: $CI_COMMIT_BRANCH =~ /^feature\/LAND.+/ + when: always before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" From f2ec177bb7a08b71a2c040e5cc1e287d182377b9 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 17 Nov 2023 09:17:14 +0100 Subject: [PATCH 054/100] Completata review x primi step LAND --- .gitlab-ci.yml | 69 ++++++++++++++++++++++++++------------------------ 1 file changed, 36 insertions(+), 33 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index d29c6611..51b0fcf2 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -91,8 +91,6 @@ LAND:build: APP_NAME: MP.Land SOL_NAME: MP-LAND rules: - # - if: $CI_COMMIT_BRANCH =~ /^feature/ - # when: never - if: $CI_COMMIT_BRANCH == 'develop' - if: $CI_COMMIT_BRANCH == 'master' - if: $CI_COMMIT_BRANCH =~ /^feature\/LAND.+/ @@ -112,11 +110,10 @@ PROG:build: APP_NAME: MP.Prog SOL_NAME: MP-PROG rules: - - if: $CI_COMMIT_BRANCH =~ "feature/" - when: never - - if: $CI_COMMIT_BRANCH == "develop" - - if: $CI_COMMIT_BRANCH == "master" - - if: $CI_COMMIT_BRANCH =~ "feature/PROG.+" + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH =~ /^feature\/PROG.+/ + when: always before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -131,9 +128,10 @@ STAT:build: APP_NAME: MP.Stats SOL_NAME: MP-STATS rules: - - if: $CI_COMMIT_BRANCH == "develop" - - if: $CI_COMMIT_BRANCH == "master" - # - if: $CI_COMMIT_BRANCH =~ /^feature/STAT* + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH =~ /^feature\/STAT.+/ + when: always before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -148,9 +146,10 @@ MON:build: APP_NAME: MP.Mon SOL_NAME: MP-MON rules: - - if: $CI_COMMIT_BRANCH == "develop" - - if: $CI_COMMIT_BRANCH == "master" - # - if: $CI_COMMIT_BRANCH =~ /^feature/MON* + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH =~ /^feature\/MON.+/ + when: always before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -165,9 +164,10 @@ SPEC:build: APP_NAME: MP.SPEC SOL_NAME: MP-SPEC rules: - - if: $CI_COMMIT_BRANCH == "develop" - - if: $CI_COMMIT_BRANCH == "master" - # - if: $CI_COMMIT_BRANCH =~ /^feature/SPEC* + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH =~ /^feature\/SPEC.+/ + when: always before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -182,9 +182,10 @@ INVE:build: APP_NAME: MP.INVE SOL_NAME: MP-INVE rules: - - if: $CI_COMMIT_BRANCH == "develop" - - if: $CI_COMMIT_BRANCH == "master" - # - if: $CI_COMMIT_BRANCH =~ /^feature/INVE* + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH =~ /^feature\/INVE.+/ + when: always before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -199,9 +200,10 @@ CONF:build: APP_NAME: IobConf.UI SOL_NAME: IobConf rules: - - if: $CI_COMMIT_BRANCH == "develop" - - if: $CI_COMMIT_BRANCH == "master" - # - if: $CI_COMMIT_BRANCH =~ /^feature/CONF* + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH =~ /^feature\/CONF.+/ + when: always before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -216,9 +218,10 @@ IOC:build: APP_NAME: MP.IOC SOL_NAME: MP-IOC rules: - - if: $CI_COMMIT_BRANCH == "develop" - - if: $CI_COMMIT_BRANCH == "master" - # - if: $CI_COMMIT_BRANCH =~ /^feature/IOC* + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH =~ /^feature\/IOC.+/ + when: always before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -233,9 +236,10 @@ TAB3:build: APP_NAME: MP-TAB-SERV SOL_NAME: MP-TAB3 rules: - - if: $CI_COMMIT_BRANCH == "develop" - - if: $CI_COMMIT_BRANCH == "master" - # - if: $CI_COMMIT_BRANCH =~ /^feature/TAB* + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH =~ /^feature\/TAB.+/ + when: always before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" @@ -254,12 +258,11 @@ LAND:IIS01:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - # only: - # - develop - # - feature/LAND.+ rules: - - if: $CI_COMMIT_BRANCH == "develop" - - if: $CI_COMMIT_BRANCH =~ "/^feature/LAND.+" + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH =~ /^feature\/LAND.+/ + when: always needs: ["LAND:build"] script: From 93ab3e808801016c638f7c3e01ae95504a142533 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 17 Nov 2023 09:29:32 +0100 Subject: [PATCH 055/100] review globale yaml --- .gitlab-ci.yml | 128 ++++++++++++++++++++++++++----------------------- 1 file changed, 69 insertions(+), 59 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 51b0fcf2..04c811f1 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -260,10 +260,8 @@ LAND:IIS01:deploy: - dotnet restore "$env:SOL_NAME.sln" rules: - if: $CI_COMMIT_BRANCH == 'develop' - - if: $CI_COMMIT_BRANCH == 'master' - if: $CI_COMMIT_BRANCH =~ /^feature\/LAND.+/ when: always - needs: ["LAND:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -279,8 +277,10 @@ PROG:IIS01:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop + rules: + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH =~ /^feature\/PROG.+/ + when: always needs: ["PROG:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -296,8 +296,10 @@ STAT:IIS01:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop + rules: + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH =~ /^feature\/STAT.+/ + when: always needs: ["STAT:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -313,8 +315,10 @@ MON:IIS01:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop + rules: + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH =~ /^feature\/MON.+/ + when: always needs: ["MON:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -330,8 +334,10 @@ SPEC:IIS01:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop + rules: + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH =~ /^feature\/SPEC.+/ + when: always needs: ["SPEC:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -347,8 +353,10 @@ INVE:IIS01:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop + rules: + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH =~ /^feature\/INVE.+/ + when: always needs: ["INVE:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -364,8 +372,10 @@ CONF:IIS01:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop + rules: + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH =~ /^feature\/CONF.+/ + when: always needs: ["CONF:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -381,8 +391,10 @@ IOC:IIS01:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop + rules: + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH =~ /^feature\/IOC.+/ + when: always needs: ["IOC:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -398,8 +410,10 @@ TAB3:IIS01:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop + rules: + - if: $CI_COMMIT_BRANCH == 'develop' + - if: $CI_COMMIT_BRANCH =~ /^feature\/TAB.+/ + when: always needs: ["TAB3:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -416,8 +430,8 @@ LAND:IIS02:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - master + rules: + - if: $CI_COMMIT_BRANCH == 'master' needs: ["LAND:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -434,8 +448,8 @@ PROG:IIS02:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - master + rules: + - if: $CI_COMMIT_BRANCH == 'master' needs: ["PROG:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -452,8 +466,8 @@ STAT:IIS02:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - master + rules: + - if: $CI_COMMIT_BRANCH == 'master' needs: ["STAT:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -470,8 +484,8 @@ MON:IIS02:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - master + rules: + - if: $CI_COMMIT_BRANCH == 'master' needs: ["MON:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -488,8 +502,8 @@ SPEC:IIS02:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - master + rules: + - if: $CI_COMMIT_BRANCH == 'master' needs: ["SPEC:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -506,8 +520,8 @@ INVE:IIS02:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - master + rules: + - if: $CI_COMMIT_BRANCH == 'master' needs: ["INVE:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -524,8 +538,8 @@ CONF:IIS02:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - master + rules: + - if: $CI_COMMIT_BRANCH == 'master' needs: ["CONF:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -542,8 +556,8 @@ IOC:IIS02:deploy: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop + rules: + - if: $CI_COMMIT_BRANCH == 'master' needs: ["IOC:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -562,9 +576,9 @@ LAND:installer: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop - - master + rules: + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH == 'develop' needs: ["LAND:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -584,9 +598,9 @@ PROG:installer: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop - - master + rules: + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH == 'develop' needs: ["PROG:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -606,9 +620,9 @@ STAT:installer: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop - - master + rules: + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH == 'develop' needs: ["STAT:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -628,9 +642,9 @@ MON:installer: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop - - master + rules: + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH == 'develop' needs: ["MON:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -650,9 +664,9 @@ SPEC:installer: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop - - master + rules: + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH == 'develop' needs: ["SPEC:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -672,9 +686,9 @@ INVE:installer: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop - - master + rules: + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH == 'develop' needs: ["INVE:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -716,9 +730,9 @@ IOC:installer: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - develop - - master + rules: + - if: $CI_COMMIT_BRANCH == 'master' + - if: $CI_COMMIT_BRANCH == 'develop' needs: ["IOC:build"] script: - dotnet build $env:APP_NAME/$env:APP_NAME.csproj @@ -763,8 +777,6 @@ PROG:release: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" only: - #- feature/Deploy_CI_CD - # - master - tags except: - branches @@ -788,8 +800,6 @@ STAT:release: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" only: - #- feature/Deploy_CI_CD - # - master - tags except: - branches From 716b3de91268e88275156871207e06c6e41bfa5d Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 17 Nov 2023 10:08:48 +0100 Subject: [PATCH 056/100] cambio only/rules per tags --- .gitlab-ci.yml | 36 +++++++++++++++++++----------------- 1 file changed, 19 insertions(+), 17 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 04c811f1..124c2f13 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -4,6 +4,8 @@ variables: APP_NAME: 'MP.Stats' SOL_NAME: 'MP-STATS' + # nota: cer creazione rules: https://docs.gitlab.com/ee/ci/jobs/job_control.html#common-if-clauses-for-rules + # helper x fix pacchetti nuget da repo locale nexus.steamware.net .nuget-fix: &nuget-fix - | @@ -708,7 +710,7 @@ INVE:installer: # before_script: # - *nuget-fix # - dotnet restore "$env:SOL_NAME.sln" -# only: +# rules: # - develop # - master # needs: ["CONF:build"] @@ -753,8 +755,8 @@ LAND:release: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - tags + rules: + - if: $CI_COMMIT_TAG except: - branches needs: ["LAND:build"] @@ -776,8 +778,8 @@ PROG:release: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - tags + rules: + - if: $CI_COMMIT_TAG except: - branches needs: ["PROG:build"] @@ -799,8 +801,8 @@ STAT:release: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - tags + rules: + - if: $CI_COMMIT_TAG except: - branches needs: ["STAT:build"] @@ -822,8 +824,8 @@ MON:release: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - tags + rules: + - if: $CI_COMMIT_TAG except: - branches needs: ["MON:build"] @@ -845,8 +847,8 @@ SPEC:release: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - tags + rules: + - if: $CI_COMMIT_TAG except: - branches needs: ["SPEC:build"] @@ -868,8 +870,8 @@ INVE:release: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - tags + rules: + - if: $CI_COMMIT_TAG except: - branches needs: ["INVE:build"] @@ -891,8 +893,8 @@ CONF:release: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - tags + rules: + - if: $CI_COMMIT_TAG except: - branches needs: ["CONF:build"] @@ -914,8 +916,8 @@ IOC:release: before_script: - *nuget-fix - dotnet restore "$env:SOL_NAME.sln" - only: - - tags + rules: + - if: $CI_COMMIT_TAG except: - branches needs: ["IOC:build"] From 3c67b98039d64ec4674e0ea6c245519ef92a1427 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 17 Nov 2023 10:21:56 +0100 Subject: [PATCH 057/100] modifica except con rules --- .gitlab-ci.yml | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 124c2f13..783b7936 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -757,8 +757,6 @@ LAND:release: - dotnet restore "$env:SOL_NAME.sln" rules: - if: $CI_COMMIT_TAG - except: - - branches needs: ["LAND:build"] artifacts: paths: @@ -780,8 +778,6 @@ PROG:release: - dotnet restore "$env:SOL_NAME.sln" rules: - if: $CI_COMMIT_TAG - except: - - branches needs: ["PROG:build"] artifacts: paths: @@ -803,8 +799,6 @@ STAT:release: - dotnet restore "$env:SOL_NAME.sln" rules: - if: $CI_COMMIT_TAG - except: - - branches needs: ["STAT:build"] artifacts: paths: @@ -826,8 +820,6 @@ MON:release: - dotnet restore "$env:SOL_NAME.sln" rules: - if: $CI_COMMIT_TAG - except: - - branches needs: ["MON:build"] artifacts: paths: @@ -849,8 +841,6 @@ SPEC:release: - dotnet restore "$env:SOL_NAME.sln" rules: - if: $CI_COMMIT_TAG - except: - - branches needs: ["SPEC:build"] artifacts: paths: @@ -872,8 +862,6 @@ INVE:release: - dotnet restore "$env:SOL_NAME.sln" rules: - if: $CI_COMMIT_TAG - except: - - branches needs: ["INVE:build"] artifacts: paths: @@ -895,8 +883,6 @@ CONF:release: - dotnet restore "$env:SOL_NAME.sln" rules: - if: $CI_COMMIT_TAG - except: - - branches needs: ["CONF:build"] artifacts: paths: @@ -918,8 +904,6 @@ IOC:release: - dotnet restore "$env:SOL_NAME.sln" rules: - if: $CI_COMMIT_TAG - except: - - branches needs: ["IOC:build"] artifacts: paths: From f914c28bf87a0864e8b26988f3ab53ee3ecf7331 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 17 Nov 2023 14:20:44 +0100 Subject: [PATCH 058/100] Renaming metodi x FluxLogPareto --- MP.Data/Controllers/MpSpecController.cs | 43 +++++++-------- MP.SPEC/Components/FLStatusList.razor.cs | 2 +- MP.SPEC/Data/MpDataService.cs | 70 ++++++++++++------------ MP.SPEC/MP.SPEC.csproj | 2 +- MP.SPEC/Resources/ChangeLog.html | 2 +- MP.SPEC/Resources/VersNum.txt | 2 +- MP.SPEC/Resources/manifest.xml | 2 +- 7 files changed, 61 insertions(+), 62 deletions(-) diff --git a/MP.Data/Controllers/MpSpecController.cs b/MP.Data/Controllers/MpSpecController.cs index 0b7b7aaa..73c17c66 100644 --- a/MP.Data/Controllers/MpSpecController.cs +++ b/MP.Data/Controllers/MpSpecController.cs @@ -611,7 +611,6 @@ namespace MP.Data.Controllers numRecProc += numRec; if (numRec > maxItem) { - List listPeriodi = new List(); switch (valMode) @@ -713,6 +712,27 @@ namespace MP.Data.Controllers return dbResult; } + /// + /// Elenco Gruppi + /// + /// + public List FluxLogPareto(string idxMacchina, DateTime dtFrom, DateTime dtTo) + { + List dbResult = new List(); + using (var dbCtx = new MoonProContext(_configuration)) + { + dbResult = dbCtx + .DbSetFluxLog + .Where(x => (string.IsNullOrEmpty(idxMacchina) || x.IdxMacchina == idxMacchina) && (dtFrom <= x.dtEvento && x.dtEvento <= dtTo)) + .AsNoTracking() + .GroupBy(x => x.CodFlux) + .Select(g => new ParetoFluxLogDTO() { IdxMacchina = idxMacchina, CodFlux = g.Key, Qty = g.Count() }) + .OrderByDescending(x => x.Qty) + .ToList(); + } + return dbResult; + } + /// /// Stored manutenzione del DB /// @@ -1270,27 +1290,6 @@ namespace MP.Data.Controllers return dbResult; } - /// - /// Elenco Gruppi - /// - /// - public List ParetoFluxLog(string idxMacchina, DateTime dtFrom, DateTime dtTo) - { - List dbResult = new List(); - using (var dbCtx = new MoonProContext(_configuration)) - { - dbResult = dbCtx - .DbSetFluxLog - .Where(x => (string.IsNullOrEmpty(idxMacchina) || x.IdxMacchina == idxMacchina) && (dtFrom <= x.dtEvento && x.dtEvento <= dtTo)) - .AsNoTracking() - .GroupBy(x => x.CodFlux) - .Select(g => new ParetoFluxLogDTO() { IdxMacchina = idxMacchina, CodFlux = g.Key, Qty = g.Count() }) - .OrderByDescending(x => x.Qty) - .ToList(); - } - return dbResult; - } - /// /// Stato prod macchina /// diff --git a/MP.SPEC/Components/FLStatusList.razor.cs b/MP.SPEC/Components/FLStatusList.razor.cs index f25e8b8c..d86c17dc 100644 --- a/MP.SPEC/Components/FLStatusList.razor.cs +++ b/MP.SPEC/Components/FLStatusList.razor.cs @@ -116,7 +116,7 @@ namespace MP.SPEC.Components { idxMaccLast = IdxMaccSel; lastPeriodo = CurrPeriodo; - ListComplete = await MDataServ.ParetoFluxLog(IdxMaccSel, CurrPeriodo.Inizio, CurrPeriodo.Fine); + ListComplete = await MDataServ.FluxLogPareto(IdxMaccSel, CurrPeriodo.Inizio, CurrPeriodo.Fine); TotalCount = ListComplete.Count; TotalRecords = ListComplete.Sum(x => x.Qty); FluxList = ListComplete.Select(x => x.CodFlux).ToList(); diff --git a/MP.SPEC/Data/MpDataService.cs b/MP.SPEC/Data/MpDataService.cs index 509f488a..f4957287 100644 --- a/MP.SPEC/Data/MpDataService.cs +++ b/MP.SPEC/Data/MpDataService.cs @@ -800,6 +800,41 @@ namespace MP.SPEC.Data return result; } + /// + /// Elenco Gruppi + /// + /// + public async Task> FluxLogPareto(string idxMacchina, DateTime dtFrom, DateTime dtTo) + { + Stopwatch stopWatch = new Stopwatch(); + stopWatch.Start(); + string source = "DB"; + List? result = new List(); + // cerco in redis... + string redKey = $"{Utils.redisParetoFLKey}:{idxMacchina}:{dtFrom:yyyyMMdd}:{dtTo:yyyyMMdd}"; + RedisValue rawData = await redisDb.StringGetAsync(redKey); + if (!string.IsNullOrEmpty($"{rawData}")) + { + result = JsonConvert.DeserializeObject>($"{rawData}"); + source = "REDIS"; + } + else + { + result = await Task.FromResult(dbController.FluxLogPareto(idxMacchina, dtFrom, dtTo)); + // serializzo e salvo... + rawData = JsonConvert.SerializeObject(result); + await redisDb.StringSetAsync(redKey, rawData, getRandTOut(redisLongTimeCache)); + } + if (result == null) + { + result = new List(); + } + stopWatch.Stop(); + TimeSpan ts = stopWatch.Elapsed; + Log.Debug($"ParetoFluxLog Read from {source}: {ts.TotalMilliseconds}ms"); + return result; + } + /// /// Stored manutenzione del DB /// @@ -1248,41 +1283,6 @@ namespace MP.SPEC.Data return result; } - /// - /// Elenco Gruppi - /// - /// - public async Task> ParetoFluxLog(string idxMacchina, DateTime dtFrom, DateTime dtTo) - { - Stopwatch stopWatch = new Stopwatch(); - stopWatch.Start(); - string source = "DB"; - List? result = new List(); - // cerco in redis... - string redKey = $"{Utils.redisParetoFLKey}:{idxMacchina}:{dtFrom:yyyyMMdd}:{dtTo:yyyyMMdd}"; - RedisValue rawData = await redisDb.StringGetAsync(redKey); - if (!string.IsNullOrEmpty($"{rawData}")) - { - result = JsonConvert.DeserializeObject>($"{rawData}"); - source = "REDIS"; - } - else - { - result = await Task.FromResult(dbController.ParetoFluxLog(idxMacchina, dtFrom, dtTo)); - // serializzo e salvo... - rawData = JsonConvert.SerializeObject(result); - await redisDb.StringSetAsync(redKey, rawData, getRandTOut(redisLongTimeCache)); - } - if (result == null) - { - result = new List(); - } - stopWatch.Stop(); - TimeSpan ts = stopWatch.Elapsed; - Log.Debug($"ParetoFluxLog Read from {source}: {ts.TotalMilliseconds}ms"); - return result; - } - /// /// Eliminazione record selezionato /// diff --git a/MP.SPEC/MP.SPEC.csproj b/MP.SPEC/MP.SPEC.csproj index e5ed1dd8..b77f0d49 100644 --- a/MP.SPEC/MP.SPEC.csproj +++ b/MP.SPEC/MP.SPEC.csproj @@ -5,7 +5,7 @@ enable enable MP.SPEC - 6.16.2311.1016 + 6.16.2311.1714 diff --git a/MP.SPEC/Resources/ChangeLog.html b/MP.SPEC/Resources/ChangeLog.html index 8d44feee..281f5398 100644 --- a/MP.SPEC/Resources/ChangeLog.html +++ b/MP.SPEC/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

                  Versione: 6.16.2311.1016

                  +

                  Versione: 6.16.2311.1714


                  Note di rilascio:
                  • diff --git a/MP.SPEC/Resources/VersNum.txt b/MP.SPEC/Resources/VersNum.txt index e1f886bd..3c587425 100644 --- a/MP.SPEC/Resources/VersNum.txt +++ b/MP.SPEC/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1016 +6.16.2311.1714 diff --git a/MP.SPEC/Resources/manifest.xml b/MP.SPEC/Resources/manifest.xml index a93e69cf..463d50ba 100644 --- a/MP.SPEC/Resources/manifest.xml +++ b/MP.SPEC/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1016 + 6.16.2311.1714 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 87fcfbc0b34f8ba0b541065058bcfff3e9d2d940 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Fri, 17 Nov 2023 18:49:55 +0100 Subject: [PATCH 059/100] Fix default end FluxLog a domani --- MP.SPEC/Components/ListPARAMS.razor.cs | 2 +- MP.SPEC/Components/ParamsFilter.razor.cs | 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, 6 insertions(+), 6 deletions(-) diff --git a/MP.SPEC/Components/ListPARAMS.razor.cs b/MP.SPEC/Components/ListPARAMS.razor.cs index 12593937..e16335c4 100644 --- a/MP.SPEC/Components/ListPARAMS.razor.cs +++ b/MP.SPEC/Components/ListPARAMS.razor.cs @@ -98,7 +98,7 @@ namespace MP.SPEC.Components SearchRecords = null; ListRecords = null; DateTime dataFrom = DateTime.Today.AddMonths(-1); - DateTime dataTo = DateTime.Now.AddMinutes(5); + DateTime dataTo = DateTime.Now.AddDays(1); if (SelFilter != null && SelFilter.dtMin != null) { dataFrom = (DateTime)SelFilter.dtMin; diff --git a/MP.SPEC/Components/ParamsFilter.razor.cs b/MP.SPEC/Components/ParamsFilter.razor.cs index 1ccadf88..09bcab53 100644 --- a/MP.SPEC/Components/ParamsFilter.razor.cs +++ b/MP.SPEC/Components/ParamsFilter.razor.cs @@ -204,7 +204,7 @@ namespace MP.SPEC.Components currFilt.LiveUpdate = true; currFilt.CurrPage = 0; currFilt.lastUpdate = $"{DateTime.Now:yyyy/MM/dd HH:mm:ss}"; - currFilt.dtMax = RoundDatetime(5); + currFilt.dtMax = DateTime.Today.AddDays(1); //RoundDatetime(5); currFilt.dtSnapMin = RoundDatetime(5).AddHours(-numOreAnticipoSnapshot); SelFilter = currFilt; } diff --git a/MP.SPEC/MP.SPEC.csproj b/MP.SPEC/MP.SPEC.csproj index b77f0d49..e6c60797 100644 --- a/MP.SPEC/MP.SPEC.csproj +++ b/MP.SPEC/MP.SPEC.csproj @@ -5,7 +5,7 @@ enable enable MP.SPEC - 6.16.2311.1714 + 6.16.2311.1718 diff --git a/MP.SPEC/Resources/ChangeLog.html b/MP.SPEC/Resources/ChangeLog.html index 281f5398..58cc7c59 100644 --- a/MP.SPEC/Resources/ChangeLog.html +++ b/MP.SPEC/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

                    Versione: 6.16.2311.1714

                    +

                    Versione: 6.16.2311.1718


                    Note di rilascio:
                    • diff --git a/MP.SPEC/Resources/VersNum.txt b/MP.SPEC/Resources/VersNum.txt index 3c587425..48ca2857 100644 --- a/MP.SPEC/Resources/VersNum.txt +++ b/MP.SPEC/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1714 +6.16.2311.1718 diff --git a/MP.SPEC/Resources/manifest.xml b/MP.SPEC/Resources/manifest.xml index 463d50ba..06c1a2e5 100644 --- a/MP.SPEC/Resources/manifest.xml +++ b/MP.SPEC/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1714 + 6.16.2311.1718 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 ee111d84c1a5dd1b8fad722d0646b11fb7479bad Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Tue, 28 Nov 2023 12:03:58 +0100 Subject: [PATCH 060/100] conf prod: - fix grafici per bottoni e finestra conferma - fix data di conferma = data di click bottone mostra conf --- MP-TAB-SERV/Components/ProdConfirm.razor | 88 ++++++++++----------- MP-TAB-SERV/Components/ProdConfirm.razor.cs | 6 +- 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 +- 6 files changed, 50 insertions(+), 52 deletions(-) diff --git a/MP-TAB-SERV/Components/ProdConfirm.razor b/MP-TAB-SERV/Components/ProdConfirm.razor index 27589b44..a57f7f52 100644 --- a/MP-TAB-SERV/Components/ProdConfirm.razor +++ b/MP-TAB-SERV/Components/ProdConfirm.razor @@ -12,7 +12,7 @@ @if (odlOk) {
                      -
                      @@ -27,49 +27,44 @@ @if (showInnov) { + @*class="d-flex justify-content-between"*@
                      -
                      - -
                      -
                      Pezzi confermati
                      - - +
                      +
                      +
                      +
                      Pezzi confermati
                      + +
                      - @*
                      - - -
                      *@ - @*
                      - - -
                      *@ -
                      -
                      -
                      - @if (enablePzProdLasciati) - { -
                      Lasciati
                      +
                      +
                      + @if (enablePzProdLasciati) + { +
                      Lasciati
                      - - } - else - { - - } + + } + else + { + + } +
                      -
                      -
                      Pz Buoni @lblPz2RecBuoni
                      -
                      Pz scarto @lblPz2RecScarto
                      -
                      -
                      - @if (showConfirm) - { - - } +
                      +
                      +
                      +
                      Pz Buoni @lblPz2RecBuoni
                      +
                      Pz scarto @lblPz2RecScarto
                      +
                      +
                      + @if (showConfirm) + { + + } +
                      +
                      @@ -80,14 +75,7 @@
                      Dati Globali ODL
                      -
                      -
                      - -
                      -
                      - -
                      -
                      +
                      @@ -161,6 +149,14 @@
                      +
                      +
                      + +
                      +
                      + +
                      +
                      @if (!string.IsNullOrEmpty(lblOut)) { diff --git a/MP-TAB-SERV/Components/ProdConfirm.razor.cs b/MP-TAB-SERV/Components/ProdConfirm.razor.cs index c226464e..8b4a743f 100644 --- a/MP-TAB-SERV/Components/ProdConfirm.razor.cs +++ b/MP-TAB-SERV/Components/ProdConfirm.razor.cs @@ -183,7 +183,7 @@ namespace MP_TAB_SERV.Components // cambio button conferma... showInnov = false; // sollevo evento! - dtReqUpdate = DateTime.Now; + //dtReqUpdate = DateTime.Now; numPzLasciati = 0; await DoUpdate(); await Task.Delay(1); @@ -210,10 +210,12 @@ namespace MP_TAB_SERV.Components /// /// Cambio stato visibilità pannello e testo button /// - protected void ToggleConfProd() + protected async Task ToggleConfProd() { showInnov = !showInnov; dtReqUpdate = DateTime.Now; + await RefreshData(); + StateHasChanged(); } #endregion Protected Methods diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index a2c67544..83c15eb7 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.1612 + 6.16.2311.2811 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 94b89c7d..002b4788 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.1612

                      +

                      Versione: 6.16.2311.2811


                      Note di rilascio:
                      • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 7d05e912..2d0218c4 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.1612 +6.16.2311.2811 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index 654147a1..c4142f97 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.1612 + 6.16.2311.2811 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From 60c64a925e9a7f4714eb6f8a6c77ce3f5ba807ea Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Tue, 28 Nov 2023 12:43:34 +0100 Subject: [PATCH 061/100] fix tolte tutte le virgole e i punti per migliaia --- MP-TAB-SERV/Components/MachineBlock.razor | 20 ++++++++++---------- MP-TAB-SERV/Components/OdlMan.razor.cs | 4 ++-- MP-TAB-SERV/Components/ProdConfirm.razor | 8 ++++---- MP-TAB-SERV/Components/ProdConfirm.razor.cs | 2 +- MP-TAB-SERV/Components/ProdPlanMan.razor | 2 +- MP-TAB-SERV/Components/ProdStat.razor | 20 ++------------------ 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 +- 10 files changed, 24 insertions(+), 40 deletions(-) diff --git a/MP-TAB-SERV/Components/MachineBlock.razor b/MP-TAB-SERV/Components/MachineBlock.razor index 42835411..ae75e5b8 100644 --- a/MP-TAB-SERV/Components/MachineBlock.razor +++ b/MP-TAB-SERV/Components/MachineBlock.razor @@ -58,15 +58,15 @@ else
                        -   @($" {RecMSE.PezziConf:N0}")   +   @($" {RecMSE.PezziConf}")  
                        - +   @($" {0:N0}") + +   @($" {0}")
                        -   @($" {RecMSE.PezziProd:N0}") +   @($" {RecMSE.PezziProd}")
                        @@ -111,16 +111,16 @@ else
                        - @($"{RecMSE.PezziConf:N0}") + @($"{RecMSE.PezziConf}")
                        - +   @($" {0:N0}") + +   @($" {0}")
                      -
                      @($"{RecMSE.PezziProd:N0}")
                      +
                      @($"{RecMSE.PezziProd}")
                      ART.
                      @@ -153,20 +153,20 @@ else
                      - @($"{RecMSE.PezziConf:N0}") + @($"{RecMSE.PezziConf}")
                      - +   @($" {0:N0}") + +   @($" {0}")
                      -
                      @($"{RecMSE.PezziProd:N0}")
                      +
                      @($"{RecMSE.PezziProd}")
                      -
                      @($"{RecMSE.extraVal:N0}")
                      +
                      @($"{RecMSE.extraVal}")
                      diff --git a/MP-TAB-SERV/Components/OdlMan.razor.cs b/MP-TAB-SERV/Components/OdlMan.razor.cs index 4edb6619..17bb44fc 100644 --- a/MP-TAB-SERV/Components/OdlMan.razor.cs +++ b/MP-TAB-SERV/Components/OdlMan.razor.cs @@ -336,7 +336,7 @@ namespace MP_TAB_SERV.Components { TimeSpan estDur = TimeSpan.FromMinutes((double)tcRichAttr * currPodl.NumPezzi); string stima = estDur.TotalHours > 1 ? $"{estDur.TotalHours:N1} ore" : $"{estDur.TotalMinutes:N1} min"; - if (!await JSRuntime.InvokeAsync("confirm", $"PODL: {currPodl.IdxPromessa}{Environment.NewLine}Art: [{currPodl.CodArticolo}] {currPodl.DescArticolo}{Environment.NewLine}Pezzi: {currPodl.NumPezzi:N0} * TCiclo: {tcRichAttr:N3}min{Environment.NewLine}Tempo stimato: {stima}{Environment.NewLine}{Environment.NewLine}Confermi la chiusura della fase di attrezzaggio?")) + if (!await JSRuntime.InvokeAsync("confirm", $"PODL: {currPodl.IdxPromessa}{Environment.NewLine}Art: [{currPodl.CodArticolo}] {currPodl.DescArticolo}{Environment.NewLine}Pezzi: {currPodl.NumPezzi} * TCiclo: {tcRichAttr:N3}min{Environment.NewLine}Tempo stimato: {stima}{Environment.NewLine}{Environment.NewLine}Confermi la chiusura della fase di attrezzaggio?")) return; // preparo gestione progress display @@ -443,7 +443,7 @@ namespace MP_TAB_SERV.Components TimeSpan estDur = TimeSpan.FromMinutes((double)tcRichAttr * currPodl.NumPezzi); string stima = estDur.TotalHours > 1 ? $"{estDur.TotalHours:N1} ore" : $"{estDur.TotalMinutes:N1} min"; - if (!await JSRuntime.InvokeAsync("confirm", $"PODL: {currPodl.IdxPromessa}{Environment.NewLine}Art: [{currPodl.CodArticolo}] {currPodl.DescArticolo}{Environment.NewLine}Pezzi: {currPodl.NumPezzi:N0} * TCiclo: {tcRichAttr:N3}min{Environment.NewLine}Tempo stimato: {stima}{Environment.NewLine}{Environment.NewLine}Confermi inizio della fase di attrezzaggio?")) + if (!await JSRuntime.InvokeAsync("confirm", $"PODL: {currPodl.IdxPromessa}{Environment.NewLine}Art: [{currPodl.CodArticolo}] {currPodl.DescArticolo}{Environment.NewLine}Pezzi: {currPodl.NumPezzi} * TCiclo: {tcRichAttr:N3}min{Environment.NewLine}Tempo stimato: {stima}{Environment.NewLine}{Environment.NewLine}Confermi inizio della fase di attrezzaggio?")) return; /*************************************************** diff --git a/MP-TAB-SERV/Components/ProdConfirm.razor b/MP-TAB-SERV/Components/ProdConfirm.razor index a57f7f52..901c20b4 100644 --- a/MP-TAB-SERV/Components/ProdConfirm.razor +++ b/MP-TAB-SERV/Components/ProdConfirm.razor @@ -90,7 +90,7 @@ } else { - @($"{numPzProdotti2Rec:N0}") + @numPzProdotti2Rec }
                      @@ -107,7 +107,7 @@ } else { - @numPzProdotti.ToString("N0") + @numPzProdotti }
                @@ -124,7 +124,7 @@ } else { - @numPzScaConf.ToString("N0") + @numPzScaConf }
                @@ -141,7 +141,7 @@ } else { - @numPzBuoniConf.ToString("N0") + @numPzBuoniConf }
                diff --git a/MP-TAB-SERV/Components/ProdConfirm.razor.cs b/MP-TAB-SERV/Components/ProdConfirm.razor.cs index 8b4a743f..17d03bed 100644 --- a/MP-TAB-SERV/Components/ProdConfirm.razor.cs +++ b/MP-TAB-SERV/Components/ProdConfirm.razor.cs @@ -179,7 +179,7 @@ namespace MP_TAB_SERV.Components RecMSE = ListMSE.Find(x => x.IdxMacchina == IdxMaccSel); } // mostro output - lblOut = $"Confermata produzione {numPzConfermati - numPzLasciati} pezzi (+{numPzLasciati} pz lasciati, +{numPzScarto2Rec:N0} pz scarto) |{dtReqUpdate:HH:mm:ss} | {dtReqUpdate:ddd yyyy.MM.dd}"; + lblOut = $"Confermata produzione {numPzConfermati - numPzLasciati} pezzi (+{numPzLasciati} pz lasciati, +{numPzScarto2Rec} pz scarto) |{dtReqUpdate:HH:mm:ss} | {dtReqUpdate:ddd yyyy.MM.dd}"; // cambio button conferma... showInnov = false; // sollevo evento! diff --git a/MP-TAB-SERV/Components/ProdPlanMan.razor b/MP-TAB-SERV/Components/ProdPlanMan.razor index cde2ec27..c2e6d0c9 100644 --- a/MP-TAB-SERV/Components/ProdPlanMan.razor +++ b/MP-TAB-SERV/Components/ProdPlanMan.razor @@ -72,7 +72,7 @@ else
                - Tot: @($"{item.NumPezzi:N0}") + Tot: @($"{item.NumPezzi}")
                @item.PzPallet pz/pal
                diff --git a/MP-TAB-SERV/Components/ProdStat.razor b/MP-TAB-SERV/Components/ProdStat.razor index e425aa5e..90b8fd52 100644 --- a/MP-TAB-SERV/Components/ProdStat.razor +++ b/MP-TAB-SERV/Components/ProdStat.razor @@ -49,7 +49,7 @@ Nr Pezzi lanciati
                - @($"{RecMSE.NumPezzi:N0}") pz. + @($"{RecMSE.NumPezzi}") pz.
                @@ -68,22 +68,6 @@
                - - - - - - - - - - - - - - - -
                @@ -91,7 +75,7 @@ Nr pezzi fatti
                - (@($"{RecMSE.PezziProd:N0}") pz.) + (@($"{RecMSE.PezziProd}") pz.)
                diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 83c15eb7..8702480f 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.2811 + 6.16.2311.2812 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 002b4788..9857f75c 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.2811

                +

                Versione: 6.16.2311.2812


                Note di rilascio:
                • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 2d0218c4..aa7bbaa8 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.2811 +6.16.2311.2812 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index c4142f97..593c59c2 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.2811 + 6.16.2311.2812 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From 4561dd873e265423ad2047ec29cb07e911345015 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Tue, 28 Nov 2023 14:36:48 +0100 Subject: [PATCH 062/100] fix grafici + mostra conferma aggiorna dati --- MP-TAB-SERV/Components/ProdConfirm.razor | 27 ++++++++++++++------- MP-TAB-SERV/Components/ProdConfirm.razor.cs | 2 +- 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 +- 6 files changed, 23 insertions(+), 14 deletions(-) diff --git a/MP-TAB-SERV/Components/ProdConfirm.razor b/MP-TAB-SERV/Components/ProdConfirm.razor index 901c20b4..bcc4e7c6 100644 --- a/MP-TAB-SERV/Components/ProdConfirm.razor +++ b/MP-TAB-SERV/Components/ProdConfirm.razor @@ -33,7 +33,7 @@
                  -
                  Pezzi confermati
                  +
                  Pz Prodotti CONFERMATI
                  @@ -41,7 +41,7 @@
                  @if (enablePzProdLasciati) { -
                  Lasciati
                  +
                  Pz Prodotti LASCIATI
                  } @@ -53,10 +53,19 @@
                  -
                  +
                  +
                  + @($"{dtReqUpdate:HH:mm:ss} | {dtReqUpdate:ddd yyyy.MM.dd}") +
                  -
                  Pz Buoni @lblPz2RecBuoni
                  -
                  Pz scarto @lblPz2RecScarto
                  +
                  + Pz Buoni + @lblPz2RecBuoni +
                  +
                  + Pz scarto + @lblPz2RecScarto +
                  @if (showConfirm) @@ -75,7 +84,7 @@
                  Dati Globali ODL
                  - +
                  @@ -149,12 +158,12 @@
                  - diff --git a/MP-TAB-SERV/Components/ProdConfirm.razor.cs b/MP-TAB-SERV/Components/ProdConfirm.razor.cs index 17d03bed..209d3142 100644 --- a/MP-TAB-SERV/Components/ProdConfirm.razor.cs +++ b/MP-TAB-SERV/Components/ProdConfirm.razor.cs @@ -214,7 +214,7 @@ namespace MP_TAB_SERV.Components { showInnov = !showInnov; dtReqUpdate = DateTime.Now; - await RefreshData(); + await DoUpdate(); StateHasChanged(); } diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 8702480f..ed61e0ca 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.2812 + 6.16.2311.2814 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 9857f75c..e747a31a 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.2812

                  +

                  Versione: 6.16.2311.2814


                  Note di rilascio:
                  • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index aa7bbaa8..c1e8a582 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.2812 +6.16.2311.2814 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index 593c59c2..ad300d94 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.2812 + 6.16.2311.2814 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From d5b425324bdff63d68df5d7312d4420e6adbb638 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Tue, 28 Nov 2023 15:38:54 +0100 Subject: [PATCH 063/100] 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:
                  • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index c1e8a582..f3af590b 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.2814 +6.16.2311.2815 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index ad300d94..cfad16c3 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.2814 + 6.16.2311.2815 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP.Data/Controllers/MpTabController.cs b/MP.Data/Controllers/MpTabController.cs index 2804c301..362694d3 100644 --- a/MP.Data/Controllers/MpTabController.cs +++ b/MP.Data/Controllers/MpTabController.cs @@ -1572,7 +1572,7 @@ namespace MP.Data.Controllers var result = await dbCtx .Database - .ExecuteSqlRawAsync("exec dbo.stp_RS_insert @idxMacchina, @DataOra, @Causale, @Qta, @Note, @MatrOpr", IdxMacchina, DataOra, Causale, Qta, Note, MatrOpr); + .ExecuteSqlRawAsync("exec dbo.stp_RS_Insert_withCheck @idxMacchina, @DataOra, @Causale, @Qta, @Note, @MatrOpr", IdxMacchina, DataOra, Causale, Qta, Note, MatrOpr); // indico eseguito! fatto = result > 0; } From 01e2502900b86b5bef76987021ade31ab0b92d13 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Wed, 29 Nov 2023 09:20:24 +0100 Subject: [PATCH 064/100] fix display scarti --- MP-TAB-SERV/Components/MachineBlock.razor | 18 +++++++++++++++--- MP-TAB-SERV/Components/MachineBlock.razor.cs | 11 ++++++++++- 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 +- 6 files changed, 29 insertions(+), 8 deletions(-) diff --git a/MP-TAB-SERV/Components/MachineBlock.razor b/MP-TAB-SERV/Components/MachineBlock.razor index ae75e5b8..ccec9133 100644 --- a/MP-TAB-SERV/Components/MachineBlock.razor +++ b/MP-TAB-SERV/Components/MachineBlock.razor @@ -61,7 +61,11 @@ else   @($" {RecMSE.PezziConf}")  
                  - +   @($" {0}") + +   + @if (datiProdAct != null) + { + @($" {datiProdAct.PzConfScarto}") + }
                  @@ -114,7 +118,11 @@ else @($"{RecMSE.PezziConf}")
                  - +   @($" {0}") + +   + @if (datiProdAct != null) + { + @($" {datiProdAct.PzConfScarto}") + }
                @@ -156,7 +164,11 @@ else @($"{RecMSE.PezziConf}")
                - +   @($" {0}") + +   + @if (datiProdAct != null) + { + @($" {datiProdAct.PzConfScarto}") + }
                diff --git a/MP-TAB-SERV/Components/MachineBlock.razor.cs b/MP-TAB-SERV/Components/MachineBlock.razor.cs index 3ede46ee..a8026fac 100644 --- a/MP-TAB-SERV/Components/MachineBlock.razor.cs +++ b/MP-TAB-SERV/Components/MachineBlock.razor.cs @@ -161,10 +161,19 @@ namespace MP_TAB_SERV.Components } } - protected override void OnParametersSet() + /// + /// Dati produzioen rilevati + /// + protected StatoProdModel? datiProdAct { get; set; } = null; + protected override async Task OnParametersSetAsync() { + DateTime adesso = DateTime.Now; isLoading = RecMSE == null; // controllo SE avessi idxMacchSub --> rileggo! + if (RecMSE != null) + { + datiProdAct = await TabDServ.StatoProdMacchina(RecMSE.IdxMacchina, adesso); + } if (!string.IsNullOrEmpty(IdxMacchSub) && RecMSE != null) { RecMSE = TabDServ.MseGetSub(RecMSE.IdxMacchina, IdxMacchSub, true); diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 4bf929a3..3c6861de 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.2815 + 6.16.2311.2909 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index cc208fb6..0d8f349d 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.2815

                +

                Versione: 6.16.2311.2909


                Note di rilascio:
                • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index f3af590b..e06a3900 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.2815 +6.16.2311.2909 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index cfad16c3..26822669 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.2815 + 6.16.2311.2909 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From 33b3aa0e2b12c7a7103322b4f879b93af5f5a201 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Wed, 29 Nov 2023 16:11:59 +0100 Subject: [PATCH 065/100] fix grafico + fix errore in scarti sempre presente --- MP-TAB-SERV/Components/FixOdl.razor | 40 ++++++++++++++------------ MP-TAB-SERV/Components/OdlMan.razor.cs | 2 +- MP-TAB-SERV/Components/ScrapMan.razor | 21 +++++++------- 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 | 3 +- 8 files changed, 39 insertions(+), 35 deletions(-) diff --git a/MP-TAB-SERV/Components/FixOdl.razor b/MP-TAB-SERV/Components/FixOdl.razor index e8998715..5da49b6c 100644 --- a/MP-TAB-SERV/Components/FixOdl.razor +++ b/MP-TAB-SERV/Components/FixOdl.razor @@ -6,6 +6,25 @@

                  Riassegnazione ODL

                  + +
                  +
                  + + +
                  + + +
                  +
                  +

                  Ultimi ODL lavorati:

                  @@ -35,7 +54,7 @@
                  -
                  +
                  @($"{item.DataFine:yyyy.MM.dd HH:mm:ss}")
                  @@ -61,24 +80,7 @@ -
                  -
                  - - -
                  - - -
                  -
                  -
                  +
                  @if (IdxOdlSel > 0) { diff --git a/MP-TAB-SERV/Components/OdlMan.razor.cs b/MP-TAB-SERV/Components/OdlMan.razor.cs index 17bb44fc..0e609a78 100644 --- a/MP-TAB-SERV/Components/OdlMan.razor.cs +++ b/MP-TAB-SERV/Components/OdlMan.razor.cs @@ -813,7 +813,7 @@ namespace MP_TAB_SERV.Components protected async Task SendFixEndSetup() { - if (!await JSRuntime.InvokeAsync("confirm", $"Confermi invio FIX chiusura atrtezzaggio ad impianto?")) + if (!await JSRuntime.InvokeAsync("confirm", $"Confermi invio FIX chiusura attrezzaggio ad impianto?")) return; string ts = string.Format("{0:yyMMdd}T{0:HHmmss.fff}Z", DateTime.Now); diff --git a/MP-TAB-SERV/Components/ScrapMan.razor b/MP-TAB-SERV/Components/ScrapMan.razor index 9d18452a..e3627b41 100644 --- a/MP-TAB-SERV/Components/ScrapMan.razor +++ b/MP-TAB-SERV/Components/ScrapMan.razor @@ -13,21 +13,22 @@
                  -@if (useOdl) -{ - -} -else -{ -
                  - -
                  -}
                  + + @if (useOdl) + { + + } + else + { +
                  + +
                  + }
                  diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 3c6861de..0637c48d 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.2909 + 6.16.2311.2916 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 0d8f349d..73b25e01 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.2909

                  +

                  Versione: 6.16.2311.2916


                  Note di rilascio:
                  • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index e06a3900..b1553713 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.2909 +6.16.2311.2916 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index 26822669..151379be 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.2909 + 6.16.2311.2916 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP.Data/Controllers/MpTabController.cs b/MP.Data/Controllers/MpTabController.cs index 362694d3..27878bcb 100644 --- a/MP.Data/Controllers/MpTabController.cs +++ b/MP.Data/Controllers/MpTabController.cs @@ -1574,7 +1574,8 @@ namespace MP.Data.Controllers .Database .ExecuteSqlRawAsync("exec dbo.stp_RS_Insert_withCheck @idxMacchina, @DataOra, @Causale, @Qta, @Note, @MatrOpr", IdxMacchina, DataOra, Causale, Qta, Note, MatrOpr); // indico eseguito! - fatto = result > 0; + // -1 = restituisce una select + fatto = result != 0; } return fatto; } From 0ae5d4f10dab5320664493ad051d995b5fd8ea30 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 30 Nov 2023 11:07:31 +0100 Subject: [PATCH 066/100] aggiunto auto logout --- MP-TAB-SERV/Components/CmpFooter.razor.cs | 35 ++++++++++++++++++++--- 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-TAB-SERV/Shared/MainLayout.razor | 3 +- MP-TAB-SERV/Shared/MainLayout.razor.cs | 10 +++++++ MP.Data/Services/MessageService.cs | 28 ++++++++++++++++++ 8 files changed, 74 insertions(+), 10 deletions(-) diff --git a/MP-TAB-SERV/Components/CmpFooter.razor.cs b/MP-TAB-SERV/Components/CmpFooter.razor.cs index 89ea2480..e90e41e6 100644 --- a/MP-TAB-SERV/Components/CmpFooter.razor.cs +++ b/MP-TAB-SERV/Components/CmpFooter.razor.cs @@ -1,9 +1,18 @@ +using Microsoft.AspNetCore.Components; +using MP.Data.Services; using NLog; namespace MP_TAB_SERV.Components { public partial class CmpFooter : IDisposable { + [Inject] + protected SharedMemService SMServ { get; set; } = null!; + [Inject] + protected MessageService MsgServ { get; set; } = null!; + [Inject] + protected NavigationManager NavMan { get; set; } = null!; + #region Public Methods public void Dispose() @@ -18,10 +27,16 @@ namespace MP_TAB_SERV.Components public void ElapsedTimer(object? source, System.Timers.ElapsedEventArgs e) { + var diffOfTime = DateTime.Now - MsgServ.dtLastAction; + var pUpd = Task.Run(async () => { await Task.Delay(1); await InvokeAsync(() => StateHasChanged()); + if(diffOfTime.Minutes > dtTimerScadenzaLogin) + { + NavMan.NavigateTo("logout"); + } //Log.Trace("CmpFooter Timer elapsed"); }); pUpd.Wait(); @@ -29,7 +44,7 @@ namespace MP_TAB_SERV.Components public void StartTimer() { - int tOutPeriod = 5000; + int tOutPeriod = dtTimerScadenzaLogin * 60000; aTimer = new System.Timers.Timer(tOutPeriod); aTimer.Elapsed += ElapsedTimer; aTimer.Enabled = true; @@ -40,12 +55,24 @@ namespace MP_TAB_SERV.Components #region Protected Methods - protected override void OnInitialized() + int dtTimerScadenzaLogin { get; set; } = 0; + + protected override async Task OnInitializedAsync() { - var rawVers = typeof(Program).Assembly.GetName().Version; ; + await Task.Delay(1); + var rawVers = typeof(Program).Assembly.GetName().Version; version = rawVers != null ? rawVers : new Version("0.0.0.0"); - StartTimer(); + dtTimerScadenzaLogin = SMServ.GetConfInt("TAB_dtTimerScadLogin"); + if (dtTimerScadenzaLogin > 0) + { + StartTimer(); + } + } + //protected override void OnInitialized() + //{ + + //} #endregion Protected Methods diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 0637c48d..3c827081 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.2916 + 6.16.2311.3010 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 73b25e01..7db84c67 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.2916

                    +

                    Versione: 6.16.2311.3010


                    Note di rilascio:
                    • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index b1553713..220ed05b 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.2916 +6.16.2311.3010 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index 151379be..e9074d8a 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.2916 + 6.16.2311.3010 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP-TAB-SERV/Shared/MainLayout.razor b/MP-TAB-SERV/Shared/MainLayout.razor index cb0b5b31..811396de 100644 --- a/MP-TAB-SERV/Shared/MainLayout.razor +++ b/MP-TAB-SERV/Shared/MainLayout.razor @@ -4,8 +4,7 @@ MP-TAB-SERV -
                      - +
                      diff --git a/MP-TAB-SERV/Shared/MainLayout.razor.cs b/MP-TAB-SERV/Shared/MainLayout.razor.cs index c102a904..6457138d 100644 --- a/MP-TAB-SERV/Shared/MainLayout.razor.cs +++ b/MP-TAB-SERV/Shared/MainLayout.razor.cs @@ -1,5 +1,6 @@ using global::Microsoft.AspNetCore.Components; using Microsoft.AspNetCore.Components.Routing; +using Microsoft.JSInterop; using MP.Data.DatabaseModels; using MP.Data.Services; using NLog; @@ -55,6 +56,9 @@ namespace MP_TAB_SERV.Shared [Inject] protected TabDataService TDataService { get; set; } = null!; + [Inject] + protected IJSRuntime JSRuntime { get; set; } = null!; + #endregion Protected Properties #region Protected Methods @@ -65,6 +69,12 @@ namespace MP_TAB_SERV.Shared } + protected async Task handleBodyClick() + { + await JSRuntime.InvokeVoidAsync("alert", "bodyClicked"); + MsgServ.dtLastAction = DateTime.Now; + } + /// /// Init struttura dati /// diff --git a/MP.Data/Services/MessageService.cs b/MP.Data/Services/MessageService.cs index d9ddde30..9dc82e94 100644 --- a/MP.Data/Services/MessageService.cs +++ b/MP.Data/Services/MessageService.cs @@ -47,10 +47,38 @@ namespace MP.Data.Services public event Action EA_PageUpdated = null!; + public event Action EA_ResetFooterTimer = null!; + #endregion Public Events #region Public Properties +#if false + protected bool _tReset { get; set; } = false; + protected bool tReset + { + get => _tReset; + set + { + if (_tReset != value) + { + _tReset = value; + resetTimer(); + } + } + } + + protected void resetTimer() + { + if (EA_ResetFooterTimer != null) + { + EA_ResetFooterTimer?.Invoke(); + } + } +#endif + + public DateTime dtLastAction { get; set; } = DateTime.Now; + public string CognomeNome { get From a1309b2c39bc14fe9473a93ce7d91784f724eed7 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 30 Nov 2023 11:57:50 +0100 Subject: [PATCH 067/100] fix redirect title --- MP-TAB-SERV/Components/CmpTop.razor | 4 ++-- MP-TAB-SERV/Components/CmpTop.razor.cs | 6 ++++++ 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-TAB-SERV/Shared/MainLayout.razor.cs | 3 ++- 7 files changed, 14 insertions(+), 7 deletions(-) diff --git a/MP-TAB-SERV/Components/CmpTop.razor b/MP-TAB-SERV/Components/CmpTop.razor index a746dc97..1ead38b5 100644 --- a/MP-TAB-SERV/Components/CmpTop.razor +++ b/MP-TAB-SERV/Components/CmpTop.razor @@ -7,12 +7,12 @@ [@MatrOpr]
                      @if (!HideMenu) diff --git a/MP-TAB-SERV/Components/CmpTop.razor.cs b/MP-TAB-SERV/Components/CmpTop.razor.cs index 19dc63c4..e97c7481 100644 --- a/MP-TAB-SERV/Components/CmpTop.razor.cs +++ b/MP-TAB-SERV/Components/CmpTop.razor.cs @@ -115,6 +115,12 @@ namespace MP_TAB_SERV.Components NavMan.NavigateTo("status-map", true); } + protected async Task backToSM() + { + await Task.Delay(1); + NavMan.NavigateTo("status-map", true); + } + protected override async Task OnInitializedAsync() { await Task.Delay(1); diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 3c827081..494c05f7 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.3010 + 6.16.2311.3011 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 7db84c67..a0014e57 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.3010

                      +

                      Versione: 6.16.2311.3011


                      Note di rilascio:
                      • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 220ed05b..1ee4d220 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.3010 +6.16.2311.3011 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index e9074d8a..fd0b5a0b 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.3010 + 6.16.2311.3011 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP-TAB-SERV/Shared/MainLayout.razor.cs b/MP-TAB-SERV/Shared/MainLayout.razor.cs index 6457138d..36188ea9 100644 --- a/MP-TAB-SERV/Shared/MainLayout.razor.cs +++ b/MP-TAB-SERV/Shared/MainLayout.razor.cs @@ -71,7 +71,8 @@ namespace MP_TAB_SERV.Shared protected async Task handleBodyClick() { - await JSRuntime.InvokeVoidAsync("alert", "bodyClicked"); + //await JSRuntime.InvokeVoidAsync("alert", "bodyClicked"); + await Task.Delay(1); MsgServ.dtLastAction = DateTime.Now; } From 8f0fd803a35b26bde2e411c1b28319e490fbb387 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 30 Nov 2023 16:23:16 +0100 Subject: [PATCH 068/100] test cambio pagina root --- MP-TAB-SERV/MP-TAB-SERV.csproj | 2 +- MP-TAB-SERV/Pages/Index.razor | 6 ++++++ MP-TAB-SERV/Pages/StatusMap.razor | 3 +-- MP-TAB-SERV/Resources/ChangeLog.html | 2 +- MP-TAB-SERV/Resources/VersNum.txt | 2 +- MP-TAB-SERV/Resources/manifest.xml | 2 +- 6 files changed, 11 insertions(+), 6 deletions(-) create mode 100644 MP-TAB-SERV/Pages/Index.razor diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 494c05f7..e64bddd9 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.3011 + 6.16.2311.3016 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Pages/Index.razor b/MP-TAB-SERV/Pages/Index.razor new file mode 100644 index 00000000..5a545bca --- /dev/null +++ b/MP-TAB-SERV/Pages/Index.razor @@ -0,0 +1,6 @@ +@page "/" + + +@code { + +} diff --git a/MP-TAB-SERV/Pages/StatusMap.razor b/MP-TAB-SERV/Pages/StatusMap.razor index 250dd569..46a97e18 100644 --- a/MP-TAB-SERV/Pages/StatusMap.razor +++ b/MP-TAB-SERV/Pages/StatusMap.razor @@ -1,5 +1,4 @@ -@page "/" -@page "/home" +@page "/home" @page "/status-map" diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index a0014e57..279486ec 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.3011

                        +

                        Versione: 6.16.2311.3016


                        Note di rilascio:
                        • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 1ee4d220..4f92cc25 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.3011 +6.16.2311.3016 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index fd0b5a0b..53c0f05d 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.3011 + 6.16.2311.3016 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From 794b11430e2c2f49f917067c442392da09d847e3 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 30 Nov 2023 16:28:17 +0100 Subject: [PATCH 069/100] fix caso in cui fare redirect --- MP-TAB-SERV/Components/CmpTop.razor.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/MP-TAB-SERV/Components/CmpTop.razor.cs b/MP-TAB-SERV/Components/CmpTop.razor.cs index e97c7481..e44336cb 100644 --- a/MP-TAB-SERV/Components/CmpTop.razor.cs +++ b/MP-TAB-SERV/Components/CmpTop.razor.cs @@ -118,7 +118,10 @@ namespace MP_TAB_SERV.Components protected async Task backToSM() { await Task.Delay(1); - NavMan.NavigateTo("status-map", true); + if (!NavMan.Uri.Contains("reg-new-device")) + { + NavMan.NavigateTo("status-map", true); + } } protected override async Task OnInitializedAsync() From b3bb9660944cddb18ba820d4feb7e37ca1aca17f Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Thu, 30 Nov 2023 18:09:40 +0100 Subject: [PATCH 070/100] modifica riqualifica --- MP-TAB-SERV/Components/LongStopList.razor | 13 ++++++++++++- MP-TAB-SERV/Components/NotesEditor.razor | 12 +----------- MP-TAB-SERV/Components/NotesEditor.razor.cs | 4 ++-- 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 +- 7 files changed, 19 insertions(+), 18 deletions(-) diff --git a/MP-TAB-SERV/Components/LongStopList.razor b/MP-TAB-SERV/Components/LongStopList.razor index c1566122..f9981a6b 100644 --- a/MP-TAB-SERV/Components/LongStopList.razor +++ b/MP-TAB-SERV/Components/LongStopList.razor @@ -51,7 +51,15 @@
                      - } + } + else + { +
                      + +
                      + }
                  @@ -66,6 +74,9 @@
                  } +
                  }
                  diff --git a/MP-TAB-SERV/Components/NotesEditor.razor b/MP-TAB-SERV/Components/NotesEditor.razor index 4e677c8a..791921d8 100644 --- a/MP-TAB-SERV/Components/NotesEditor.razor +++ b/MP-TAB-SERV/Components/NotesEditor.razor @@ -1,15 +1,5 @@ 
                  - @if (ShowBtn) - { -
                  - -
                  - } - else + @if (UserComment != "") {
                  diff --git a/MP-TAB-SERV/Components/NotesEditor.razor.cs b/MP-TAB-SERV/Components/NotesEditor.razor.cs index a6af00a2..5b891c17 100644 --- a/MP-TAB-SERV/Components/NotesEditor.razor.cs +++ b/MP-TAB-SERV/Components/NotesEditor.razor.cs @@ -155,7 +155,7 @@ namespace MP_TAB_SERV.Components { await Task.Delay(1); ShowBtn = false; - UserComment = await MServ.CommentoValGet(true); + //UserComment = await MServ.CommentoValGet(true); DateSel = await MServ.CommentoDtRifGet(true); await InvokeAsync(StateHasChanged); } @@ -245,7 +245,7 @@ namespace MP_TAB_SERV.Components { UserComment = ""; DateSel = DateTime.Now; - ShowBtn = true; + CurrComm = null; //StateHasChanged(); } diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index e64bddd9..da386b70 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.3016 + 6.16.2311.3018 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 279486ec..38abd60d 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.3016

                  +

                  Versione: 6.16.2311.3018


                  Note di rilascio:
                  • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 4f92cc25..2fa44d88 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.3016 +6.16.2311.3018 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index 53c0f05d..29a2b035 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.3016 + 6.16.2311.3018 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From df0dfcec2061819028bb869ffe9cc186604363c8 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Fri, 1 Dec 2023 11:42:15 +0100 Subject: [PATCH 071/100] fix grafici + fix logout con timeout --- MP-TAB-SERV/Components/CmpFooter.razor.cs | 2 +- MP-TAB-SERV/Components/NotesEditor.razor | 2 +- MP-TAB-SERV/Components/NotesEditor.razor.cs | 5 ++- MP-TAB-SERV/Components/ProdConfirm.razor | 49 ++++++++++----------- 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 +- 8 files changed, 33 insertions(+), 33 deletions(-) diff --git a/MP-TAB-SERV/Components/CmpFooter.razor.cs b/MP-TAB-SERV/Components/CmpFooter.razor.cs index e90e41e6..9d669395 100644 --- a/MP-TAB-SERV/Components/CmpFooter.razor.cs +++ b/MP-TAB-SERV/Components/CmpFooter.razor.cs @@ -33,7 +33,7 @@ namespace MP_TAB_SERV.Components { await Task.Delay(1); await InvokeAsync(() => StateHasChanged()); - if(diffOfTime.Minutes > dtTimerScadenzaLogin) + if(diffOfTime.Minutes >= dtTimerScadenzaLogin) { NavMan.NavigateTo("logout"); } diff --git a/MP-TAB-SERV/Components/NotesEditor.razor b/MP-TAB-SERV/Components/NotesEditor.razor index 791921d8..1958a1b7 100644 --- a/MP-TAB-SERV/Components/NotesEditor.razor +++ b/MP-TAB-SERV/Components/NotesEditor.razor @@ -1,5 +1,5 @@ 
                    - @if (UserComment != "") + @if (!ShowBtn) {
                    diff --git a/MP-TAB-SERV/Components/NotesEditor.razor.cs b/MP-TAB-SERV/Components/NotesEditor.razor.cs index 5b891c17..20bd31e4 100644 --- a/MP-TAB-SERV/Components/NotesEditor.razor.cs +++ b/MP-TAB-SERV/Components/NotesEditor.razor.cs @@ -155,7 +155,7 @@ namespace MP_TAB_SERV.Components { await Task.Delay(1); ShowBtn = false; - //UserComment = await MServ.CommentoValGet(true); + UserComment = await MServ.CommentoValGet(true); DateSel = await MServ.CommentoDtRifGet(true); await InvokeAsync(StateHasChanged); } @@ -245,7 +245,8 @@ namespace MP_TAB_SERV.Components { UserComment = ""; DateSel = DateTime.Now; - CurrComm = null; + //CurrComm = null; + ShowBtn = true; //StateHasChanged(); } diff --git a/MP-TAB-SERV/Components/ProdConfirm.razor b/MP-TAB-SERV/Components/ProdConfirm.razor index bcc4e7c6..001916b4 100644 --- a/MP-TAB-SERV/Components/ProdConfirm.razor +++ b/MP-TAB-SERV/Components/ProdConfirm.razor @@ -1,17 +1,17 @@  +
                    + +
                    -
                    - -
                    -
                    -
                    +
                    +
                    @if (odlOk) { -
                    +
                    @@ -32,32 +32,28 @@
                    -
                    -
                    Pz Prodotti CONFERMATI
                    - +
                    Pz Prodotti CONFERMATI
                    +
                    +
                    -
                    - @if (enablePzProdLasciati) - { -
                    Pz Prodotti LASCIATI
                    - - - } - else - { - - } -
                    + @if (enablePzProdLasciati) + { +
                    Pz Prodotti LASCIATI
                    +
                    + +
                    + } + else + { + + }
                    -
                    - @($"{dtReqUpdate:HH:mm:ss} | {dtReqUpdate:ddd yyyy.MM.dd}") -
                    -
                    +
                    Pz Buoni @lblPz2RecBuoni @@ -67,6 +63,9 @@ @lblPz2RecScarto
                    +
                    + @($"{dtReqUpdate:HH:mm:ss} | {dtReqUpdate:ddd yyyy.MM.dd}") +
                    @if (showConfirm) { diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index da386b70..bfde8a91 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.3018 + 6.16.2312.110 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 38abd60d..e5541a35 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.3018

                    +

                    Versione: 6.16.2312.110


                    Note di rilascio:
                    • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 2fa44d88..259fa006 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2311.3018 +6.16.2312.110 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index 29a2b035..73b7d034 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2311.3018 + 6.16.2312.110 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From 07de159dd1de7871de2f2416bd0c72fff785fbf8 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Fri, 1 Dec 2023 12:06:10 +0100 Subject: [PATCH 072/100] fix reload --- MP-TAB-SERV/Components/CmpTop.razor.cs | 3 +++ MP-TAB-SERV/Components/MachineBlock.razor.cs | 5 ++++- MP-TAB-SERV/MP-TAB-SERV.csproj | 2 +- MP-TAB-SERV/Pages/StatusMap.razor.cs | 12 +++++++++++- MP-TAB-SERV/Resources/ChangeLog.html | 2 +- MP-TAB-SERV/Resources/VersNum.txt | 2 +- MP-TAB-SERV/Resources/manifest.xml | 2 +- MP.Data/Services/MessageService.cs | 4 ++-- 8 files changed, 24 insertions(+), 8 deletions(-) diff --git a/MP-TAB-SERV/Components/CmpTop.razor.cs b/MP-TAB-SERV/Components/CmpTop.razor.cs index e44336cb..281e7f8a 100644 --- a/MP-TAB-SERV/Components/CmpTop.razor.cs +++ b/MP-TAB-SERV/Components/CmpTop.razor.cs @@ -2,6 +2,7 @@ using Microsoft.AspNetCore.Components; using MP.Data.DatabaseModels; using MP.Data.DTO; using MP.Data.Services; +using MP_TAB_SERV.Pages; using Newtonsoft.Json; using NLog; using System.Diagnostics; @@ -120,6 +121,8 @@ namespace MP_TAB_SERV.Components await Task.Delay(1); if (!NavMan.Uri.Contains("reg-new-device")) { + + await MsgServ.IdxMaccSet(""); NavMan.NavigateTo("status-map", true); } } diff --git a/MP-TAB-SERV/Components/MachineBlock.razor.cs b/MP-TAB-SERV/Components/MachineBlock.razor.cs index a8026fac..f71fe744 100644 --- a/MP-TAB-SERV/Components/MachineBlock.razor.cs +++ b/MP-TAB-SERV/Components/MachineBlock.razor.cs @@ -146,7 +146,7 @@ namespace MP_TAB_SERV.Components //return base.OnAfterRenderAsync(firstRender); } - protected override void OnInitialized() + protected override async Task OnInitializedAsync() { isLoading = true; // se configurata uso cartella virtuale... altrimenti cartella processo @@ -159,6 +159,9 @@ namespace MP_TAB_SERV.Components { imgBasePath = $"{Environment.CurrentDirectory}/images/"; } + + + } /// diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index bfde8a91..f1008c3a 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.2312.110 + 6.16.2312.112 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Pages/StatusMap.razor.cs b/MP-TAB-SERV/Pages/StatusMap.razor.cs index 13543c8b..73667e1c 100644 --- a/MP-TAB-SERV/Pages/StatusMap.razor.cs +++ b/MP-TAB-SERV/Pages/StatusMap.razor.cs @@ -3,6 +3,7 @@ using Microsoft.JSInterop; using MP.Data.Conf; using MP.Data.DatabaseModels; using MP.Data.Services; +using MP_TAB_SERV.Shared; using NLog; using System.Runtime.ExceptionServices; @@ -51,6 +52,8 @@ namespace MP_TAB_SERV.Pages [Inject] protected MessageService MsgServ { get; set; } = null!; + [Inject] + protected NavigationManager NavMan { get; set; } = null!; protected bool ShowCard { @@ -94,11 +97,18 @@ namespace MP_TAB_SERV.Pages } } - protected override void OnInitialized() + protected override async Task OnInitializedAsync() { setDefaults(); ListMSE = null; SetupConf(); + var currMacc = await MsgServ.IdxMaccGet(); + if (currMacc != "" && currMacc != null) + { + await MsgServ.IdxMaccSet(currMacc); + + NavMan.NavigateTo($"machine-detail"); + } } protected void SaveData(List newList) diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index e5541a35..ac37bc1c 100644 --- a/MP-TAB-SERV/Resources/ChangeLog.html +++ b/MP-TAB-SERV/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

                      Versione: 6.16.2312.110

                      +

                      Versione: 6.16.2312.112


                      Note di rilascio:
                      • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 259fa006..d4a86301 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2312.110 +6.16.2312.112 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index 73b7d034..08935e81 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2312.110 + 6.16.2312.112 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false diff --git a/MP.Data/Services/MessageService.cs b/MP.Data/Services/MessageService.cs index 9dc82e94..c7e7838b 100644 --- a/MP.Data/Services/MessageService.cs +++ b/MP.Data/Services/MessageService.cs @@ -332,7 +332,7 @@ namespace MP.Data.Services ///
                      public async Task IdxMaccGet() { - return await sessionStore.GetItemAsync("CurrMach"); + return await localStorage.GetItemAsync("CurrMach"); } /// @@ -340,7 +340,7 @@ namespace MP.Data.Services /// public async Task IdxMaccSet(string machSel) { - await sessionStore.SetItemAsync("CurrMach", machSel); + await localStorage.SetItemAsync("CurrMach", machSel); } /// From d0385462cf10f7a8ab0c3c1622b5445413282da5 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Fri, 1 Dec 2023 16:07:33 +0100 Subject: [PATCH 073/100] sistemata posizione selettori periodo --- MP-TAB-SERV/Components/ControlsMan.razor | 18 +++++++++--------- MP-TAB-SERV/Components/DeclarMan.razor | 19 ++++++++++--------- 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 +- 6 files changed, 23 insertions(+), 22 deletions(-) diff --git a/MP-TAB-SERV/Components/ControlsMan.razor b/MP-TAB-SERV/Components/ControlsMan.razor index 96861d63..2ee4169c 100644 --- a/MP-TAB-SERV/Components/ControlsMan.razor +++ b/MP-TAB-SERV/Components/ControlsMan.razor @@ -12,20 +12,20 @@
                    -@if (useOdl) -{ - -} -else -{ - -}
                    - + @if (useOdl) + { + + } + else + { + + } @if (showInsert) { @if (showNote) diff --git a/MP-TAB-SERV/Components/DeclarMan.razor b/MP-TAB-SERV/Components/DeclarMan.razor index e1dfd528..7b9327dc 100644 --- a/MP-TAB-SERV/Components/DeclarMan.razor +++ b/MP-TAB-SERV/Components/DeclarMan.razor @@ -11,19 +11,20 @@
                    -@if (useOdl) -{ - -} -else -{ - -} +
                    -
                    +
                    + @if (useOdl) + { + + } + else + { + + }
                    diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index f1008c3a..400686d0 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.2312.112 + 6.16.2312.116 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index ac37bc1c..e3a24107 100644 --- a/MP-TAB-SERV/Resources/ChangeLog.html +++ b/MP-TAB-SERV/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

                    Versione: 6.16.2312.112

                    +

                    Versione: 6.16.2312.116


                    Note di rilascio:
                    • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index d4a86301..26030c28 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2312.112 +6.16.2312.116 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index 08935e81..c3a775c6 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2312.112 + 6.16.2312.116 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From 2fb2ab72057b0efe39d0f887d3b1d14d8d82b62c Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Fri, 1 Dec 2023 17:59:21 +0100 Subject: [PATCH 074/100] fix grafixo --- MP-TAB-SERV/Components/ControlsMan.razor | 23 ++++++++++++----------- MP-TAB-SERV/Components/DeclarMan.razor | 23 ++++++++++++----------- MP-TAB-SERV/Components/ScrapMan.razor | 24 ++++++++++++------------ 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 +- 7 files changed, 40 insertions(+), 38 deletions(-) diff --git a/MP-TAB-SERV/Components/ControlsMan.razor b/MP-TAB-SERV/Components/ControlsMan.razor index 2ee4169c..1c9ae31a 100644 --- a/MP-TAB-SERV/Components/ControlsMan.razor +++ b/MP-TAB-SERV/Components/ControlsMan.razor @@ -1,16 +1,6 @@  -
                      -
                      -

                      Tipo Selezione

                      -
                      -
                      -
                      - - -
                      -
                      -
                      +
                      @@ -18,6 +8,17 @@ +
                      +
                      +

                      Tipo Selezione

                      +
                      +
                      +
                      + + +
                      +
                      +
                      @if (useOdl) { diff --git a/MP-TAB-SERV/Components/DeclarMan.razor b/MP-TAB-SERV/Components/DeclarMan.razor index 7b9327dc..53ff08ca 100644 --- a/MP-TAB-SERV/Components/DeclarMan.razor +++ b/MP-TAB-SERV/Components/DeclarMan.razor @@ -1,15 +1,5 @@  -
                      -
                      -

                      Tipo Selezione

                      -
                      -
                      -
                      - - -
                      -
                      -
                      + @@ -17,6 +7,17 @@
                      +
                      +
                      +

                      Tipo Selezione

                      +
                      +
                      +
                      + + +
                      +
                      +
                      @if (useOdl) { diff --git a/MP-TAB-SERV/Components/ScrapMan.razor b/MP-TAB-SERV/Components/ScrapMan.razor index e3627b41..ae11fec1 100644 --- a/MP-TAB-SERV/Components/ScrapMan.razor +++ b/MP-TAB-SERV/Components/ScrapMan.razor @@ -1,24 +1,24 @@  -
                      -
                      -

                      Tipo Selezione

                      -
                      -
                      -
                      - - -
                      -
                      -
                      +
                      - +
                      +
                      +

                      Tipo Selezione

                      +
                      +
                      +
                      + + +
                      +
                      +
                      @if (useOdl) { diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 400686d0..f0a5c3d4 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.2312.116 + 6.16.2312.117 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index e3a24107..4aadb66e 100644 --- a/MP-TAB-SERV/Resources/ChangeLog.html +++ b/MP-TAB-SERV/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

                      Versione: 6.16.2312.116

                      +

                      Versione: 6.16.2312.117


                      Note di rilascio:
                      • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 26030c28..0e7ac90c 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2312.116 +6.16.2312.117 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index c3a775c6..b8bab96a 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2312.116 + 6.16.2312.117 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From 9bed5a42203aa58b5f6ea9205816f5a5b94a9fa9 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Mon, 4 Dec 2023 11:55:27 +0100 Subject: [PATCH 075/100] fix registrazione scarti con errore --- MP-TAB-SERV/Components/ScrapEditor.razor.cs | 3 ++- MP.Data/Controllers/MpTabController.cs | 11 +++++++---- MP.Data/DatabaseModels/RegCheckModel.cs | 20 ++++++++++++++++++++ MP.Data/MoonProContext.cs | 1 + 4 files changed, 30 insertions(+), 5 deletions(-) create mode 100644 MP.Data/DatabaseModels/RegCheckModel.cs diff --git a/MP-TAB-SERV/Components/ScrapEditor.razor.cs b/MP-TAB-SERV/Components/ScrapEditor.razor.cs index 037e187b..c21c933c 100644 --- a/MP-TAB-SERV/Components/ScrapEditor.razor.cs +++ b/MP-TAB-SERV/Components/ScrapEditor.razor.cs @@ -89,7 +89,8 @@ namespace MP_TAB_SERV.Components errMsg = ""; //ToggleCtrl(); await E_Updated.InvokeAsync(true); - StateHasChanged(); + await ReloadData(); + StateHasChanged(); } else { diff --git a/MP.Data/Controllers/MpTabController.cs b/MP.Data/Controllers/MpTabController.cs index 27878bcb..e7311b81 100644 --- a/MP.Data/Controllers/MpTabController.cs +++ b/MP.Data/Controllers/MpTabController.cs @@ -1560,6 +1560,7 @@ namespace MP.Data.Controllers /// public async Task RegScartiInsert(RegistroScartiModel newRec) { + await Task.Delay(1); bool fatto = false; using (var dbCtx = new MoonProContext(_configuration)) { @@ -1570,12 +1571,14 @@ namespace MP.Data.Controllers var Note = new SqlParameter("@Note", newRec.Note); var MatrOpr = new SqlParameter("@MatrOpr", newRec.MatrOpr); - var result = await dbCtx - .Database - .ExecuteSqlRawAsync("exec dbo.stp_RS_Insert_withCheck @idxMacchina, @DataOra, @Causale, @Qta, @Note, @MatrOpr", IdxMacchina, DataOra, Causale, Qta, Note, MatrOpr); + var result = dbCtx + .DbSetRegWithCheck + .FromSqlRaw("exec dbo.stp_RS_Insert_withCheck @idxMacchina, @DataOra, @Causale, @Qta, @Note, @MatrOpr", IdxMacchina, DataOra, Causale, Qta, Note, MatrOpr) + .AsNoTracking() + .ToList(); // indico eseguito! // -1 = restituisce una select - fatto = result != 0; + fatto = result.Count > 0; } return fatto; } diff --git a/MP.Data/DatabaseModels/RegCheckModel.cs b/MP.Data/DatabaseModels/RegCheckModel.cs new file mode 100644 index 00000000..1c18a6ed --- /dev/null +++ b/MP.Data/DatabaseModels/RegCheckModel.cs @@ -0,0 +1,20 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; + +#nullable disable +// +// This is here so CodeMaid doesn't reorganize this document +// +namespace MP.Data.DatabaseModels +{ + public partial class RegCheckModel + { + #region Public Properties + [Key] + public string IdxMacchina { get; set; } + + #endregion Public Properties + } +} \ No newline at end of file diff --git a/MP.Data/MoonProContext.cs b/MP.Data/MoonProContext.cs index 43503dc5..b36b607f 100644 --- a/MP.Data/MoonProContext.cs +++ b/MP.Data/MoonProContext.cs @@ -78,6 +78,7 @@ namespace MP.Data public virtual DbSet DbSetRegControlli { get; set; } public virtual DbSet DbSetRegScarti { get; set; } public virtual DbSet DbSetRegDich { get; set; } + public virtual DbSet DbSetRegWithCheck { get; set; } public virtual DbSet DbSetStAct { get; set; } From 66f77eacfcc839ecaec060fb68164902e610a456 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Mon, 4 Dec 2023 11:55:37 +0100 Subject: [PATCH 076/100] fix grafico --- MP-TAB-SERV/Components/ProdConfirm.razor | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MP-TAB-SERV/Components/ProdConfirm.razor b/MP-TAB-SERV/Components/ProdConfirm.razor index 001916b4..843d42d7 100644 --- a/MP-TAB-SERV/Components/ProdConfirm.razor +++ b/MP-TAB-SERV/Components/ProdConfirm.razor @@ -19,7 +19,7 @@ } else { -
                        MANCA ODL: conferma NON permessa
                        +
                        MANCA ODL: conferma NON permessa
                        }
                      @@ -67,7 +67,7 @@ @($"{dtReqUpdate:HH:mm:ss} | {dtReqUpdate:ddd yyyy.MM.dd}")
                    - @if (showConfirm) + @if (showConfirm && numPzProdotti2Rec >= 0) { } From 79dbe857dad3688295fbb04473944e61a3ae6bf1 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Mon, 4 Dec 2023 11:55:46 +0100 Subject: [PATCH 077/100] refresh versioni --- 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 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index f0a5c3d4..61b754bc 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.2312.117 + 6.16.2312.411 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 4aadb66e..6027bf99 100644 --- a/MP-TAB-SERV/Resources/ChangeLog.html +++ b/MP-TAB-SERV/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

                    Versione: 6.16.2312.117

                    +

                    Versione: 6.16.2312.411


                    Note di rilascio:
                    • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 0e7ac90c..099b8cc1 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2312.117 +6.16.2312.411 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index b8bab96a..005abba5 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2312.117 + 6.16.2312.411 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From 91cf5806fec4f0771b0b66e2fd989cd1fc2bcef8 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Mon, 4 Dec 2023 15:21:05 +0100 Subject: [PATCH 078/100] ok aggiornamento post delete o update commento --- MP-TAB-SERV/Components/NotesEditor.razor | 2 +- MP-TAB-SERV/Components/NotesEditor.razor.cs | 10 ++++++++-- MP-TAB-SERV/Components/NotesMan.razor | 2 +- MP-TAB-SERV/Components/NotesMan.razor.cs | 3 ++- 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 +- 8 files changed, 16 insertions(+), 9 deletions(-) diff --git a/MP-TAB-SERV/Components/NotesEditor.razor b/MP-TAB-SERV/Components/NotesEditor.razor index 1958a1b7..7c93e784 100644 --- a/MP-TAB-SERV/Components/NotesEditor.razor +++ b/MP-TAB-SERV/Components/NotesEditor.razor @@ -8,7 +8,7 @@
                    - +
                    diff --git a/MP-TAB-SERV/Components/NotesEditor.razor.cs b/MP-TAB-SERV/Components/NotesEditor.razor.cs index 20bd31e4..7282f87b 100644 --- a/MP-TAB-SERV/Components/NotesEditor.razor.cs +++ b/MP-TAB-SERV/Components/NotesEditor.razor.cs @@ -30,6 +30,8 @@ namespace MP_TAB_SERV.Components [Parameter] public bool CanSave { get; set; } = false; [Parameter] + public EventCallback E_relData { get; set; } + [Parameter] public CommentiModel? CurrComm { set @@ -101,8 +103,10 @@ namespace MP_TAB_SERV.Components #region Protected Methods - protected void doCancel() + protected async Task doCancel() { + + await E_relData.InvokeAsync(true); DoReset(); } @@ -136,9 +140,11 @@ namespace MP_TAB_SERV.Components // inserisco await TabServ.EvListInsert(newRec, MP.Data.Objects.Enums.tipoInputEvento.commento); // reset + await E_relData.InvokeAsync(true); DoReset(); + //StateHasChanged(); //ToggleCtrl(); - await E_Updated.InvokeAsync(true); + } protected override void OnInitialized() diff --git a/MP-TAB-SERV/Components/NotesMan.razor b/MP-TAB-SERV/Components/NotesMan.razor index 8d43a10c..417f3357 100644 --- a/MP-TAB-SERV/Components/NotesMan.razor +++ b/MP-TAB-SERV/Components/NotesMan.razor @@ -1,5 +1,5 @@  - +
                    diff --git a/MP-TAB-SERV/Components/NotesMan.razor.cs b/MP-TAB-SERV/Components/NotesMan.razor.cs index da0df09a..8e5b22a5 100644 --- a/MP-TAB-SERV/Components/NotesMan.razor.cs +++ b/MP-TAB-SERV/Components/NotesMan.razor.cs @@ -90,7 +90,8 @@ namespace MP_TAB_SERV.Components { if (rel) { - await ReloadComments(); + await ReloadData(); + currComm = null; await InvokeAsync(StateHasChanged); } } diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj index 61b754bc..68f8a353 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.2312.411 + 6.16.2312.415 enable MP_TAB_SERV diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html index 6027bf99..c183b4d2 100644 --- a/MP-TAB-SERV/Resources/ChangeLog.html +++ b/MP-TAB-SERV/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

                    Versione: 6.16.2312.411

                    +

                    Versione: 6.16.2312.415


                    Note di rilascio:
                    • diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt index 099b8cc1..0f1b4051 100644 --- a/MP-TAB-SERV/Resources/VersNum.txt +++ b/MP-TAB-SERV/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2312.411 +6.16.2312.415 diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml index 005abba5..a8c6f52e 100644 --- a/MP-TAB-SERV/Resources/manifest.xml +++ b/MP-TAB-SERV/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2312.411 + 6.16.2312.415 https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html false From e72bf038b3797b3040b3826af4fb80f6d59d45c0 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Mon, 4 Dec 2023 15:47:05 +0100 Subject: [PATCH 079/100] fix controlli solo se con odl --- MP-TAB-SERV/Components/ControlsMan.razor | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/MP-TAB-SERV/Components/ControlsMan.razor b/MP-TAB-SERV/Components/ControlsMan.razor index 1c9ae31a..4d8e9281 100644 --- a/MP-TAB-SERV/Components/ControlsMan.razor +++ b/MP-TAB-SERV/Components/ControlsMan.razor @@ -5,9 +5,13 @@
                      - + @if (RecMSE.IdxOdl > 0) + { + + + }

                      Tipo Selezione

                      From de68cad13a0a81f128d2257a24d6d54316dddd63 Mon Sep 17 00:00:00 2001 From: "zaccaria.majid" Date: Tue, 5 Dec 2023 12:11:05 +0100 Subject: [PATCH 080/100] fix grafici e funzionali sulle varie pagine --- MP-TAB-SERV/Components/FixOdl.razor | 15 ++++++++------- MP-TAB-SERV/Components/OdlMan.razor | 4 ++-- MP-TAB-SERV/Components/OdlMan.razor.cs | 2 +- MP-TAB-SERV/Components/ProdConfirm.razor | 6 +++++- MP-TAB-SERV/Components/ProdConfirm.razor.cs | 2 ++ 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 +- 9 files changed, 22 insertions(+), 15 deletions(-) diff --git a/MP-TAB-SERV/Components/FixOdl.razor b/MP-TAB-SERV/Components/FixOdl.razor index 5da49b6c..f2f19fd6 100644 --- a/MP-TAB-SERV/Components/FixOdl.razor +++ b/MP-TAB-SERV/Components/FixOdl.razor @@ -7,7 +7,7 @@

                      Riassegnazione ODL

                      -
                      +
                  @@ -81,12 +87,7 @@ -
                  - @if (IdxOdlSel > 0) - { - - } -
                  + } diff --git a/MP-TAB-SERV/Components/OdlMan.razor b/MP-TAB-SERV/Components/OdlMan.razor index 1b7e773a..39eb12b4 100644 --- a/MP-TAB-SERV/Components/OdlMan.razor +++ b/MP-TAB-SERV/Components/OdlMan.razor @@ -120,7 +120,7 @@ P.ODL:
                  - @currPodl.IdxPromessa.ToString("N0") + @currPodl.IdxPromessa
                  @@ -223,7 +223,7 @@ }
                  -
                  +