From 87ceb0a1bba002dc3d0495360def68b2231b023b Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Mon, 25 Nov 2024 19:52:31 +0100 Subject: [PATCH 1/3] Aggiunto descrizione UM x parametri in TAB3 --- MP-TAB3/Components/ParamsMan.razor | 10 +++++++--- MP-TAB3/MP-TAB3.csproj | 2 +- MP-TAB3/Resources/ChangeLog.html | 2 +- MP-TAB3/Resources/VersNum.txt | 2 +- MP-TAB3/Resources/manifest.xml | 2 +- 5 files changed, 11 insertions(+), 7 deletions(-) diff --git a/MP-TAB3/Components/ParamsMan.razor b/MP-TAB3/Components/ParamsMan.razor index d641a318..f971af17 100644 --- a/MP-TAB3/Components/ParamsMan.razor +++ b/MP-TAB3/Components/ParamsMan.razor @@ -44,7 +44,7 @@
-
+
@item.description
@@ -66,8 +66,12 @@
}
-
- @item.value   +
+ @item.value + @if (!string.IsNullOrEmpty(item.UM)) + { +  (@item.UM) + }
diff --git a/MP-TAB3/MP-TAB3.csproj b/MP-TAB3/MP-TAB3.csproj index 1e25f916..534b8f3c 100644 --- a/MP-TAB3/MP-TAB3.csproj +++ b/MP-TAB3/MP-TAB3.csproj @@ -3,7 +3,7 @@ net6.0 enable - 6.16.2411.1415 + 6.16.2411.2519 enable MP_TAB3 diff --git a/MP-TAB3/Resources/ChangeLog.html b/MP-TAB3/Resources/ChangeLog.html index f5ac856b..60e11fdc 100644 --- a/MP-TAB3/Resources/ChangeLog.html +++ b/MP-TAB3/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

Versione: 6.16.2411.1415

+

Versione: 6.16.2411.2519


Note di rilascio:
  • diff --git a/MP-TAB3/Resources/VersNum.txt b/MP-TAB3/Resources/VersNum.txt index 747389b7..8e9618d7 100644 --- a/MP-TAB3/Resources/VersNum.txt +++ b/MP-TAB3/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2411.1415 +6.16.2411.2519 diff --git a/MP-TAB3/Resources/manifest.xml b/MP-TAB3/Resources/manifest.xml index 91b4ded6..ac0c3d46 100644 --- a/MP-TAB3/Resources/manifest.xml +++ b/MP-TAB3/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2411.1415 + 6.16.2411.2519 https://nexus.steamware.net/repository/SWS/MP-TAB3/stable/LAST/MP-TAB3.zip https://nexus.steamware.net/repository/SWS/MP-TAB3/stable/LAST/ChangeLog.html false From fb012082f4444eeebe6535659223d725d20b140c Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Thu, 5 Dec 2024 10:29:48 +0100 Subject: [PATCH 2/3] TAB3: - Modifica condizione visualizzazione notifica email allarmi --- MP-TAB3/Components/AlarmsMan.razor | 2 +- MP-TAB3/Components/AlarmsMan.razor.cs | 9 ++++++++- MP-TAB3/MP-TAB3.csproj | 2 +- MP-TAB3/Resources/ChangeLog.html | 2 +- MP-TAB3/Resources/VersNum.txt | 2 +- MP-TAB3/Resources/manifest.xml | 2 +- MP-TAB3/appsettings.Production.json | 4 +++- MP-TAB3/appsettings.json | 5 +++-- MP.SPEC/Pages/FluxLogStatus.razor | 2 +- 9 files changed, 20 insertions(+), 10 deletions(-) diff --git a/MP-TAB3/Components/AlarmsMan.razor b/MP-TAB3/Components/AlarmsMan.razor index 139176c8..71c0d8ef 100644 --- a/MP-TAB3/Components/AlarmsMan.razor +++ b/MP-TAB3/Components/AlarmsMan.razor @@ -49,7 +49,7 @@ else }
- @if (item.ReqNotify != 0) + @if (item.ReqNotify != 0 || item.Duration > alarmMinDuration) { } diff --git a/MP-TAB3/Components/AlarmsMan.razor.cs b/MP-TAB3/Components/AlarmsMan.razor.cs index feeb8ddb..dc36e6c3 100644 --- a/MP-TAB3/Components/AlarmsMan.razor.cs +++ b/MP-TAB3/Components/AlarmsMan.razor.cs @@ -102,7 +102,8 @@ namespace MP_TAB3.Components DateTime inizio = fine.AddDays(-8); CurrPeriodo = new Periodo(inizio, fine); } - var rawDest = config.GetValue("AlarmDest"); + // gestione conf allarmi + var rawDest = config.GetValue("OptConf:AlarmDest"); if (!string.IsNullOrEmpty(rawDest)) { AlarmsDest = rawDest.Split(",").ToList(); @@ -111,6 +112,7 @@ namespace MP_TAB3.Components { AlarmsDest = new List() { "samuele@steamware.net" }; } + alarmMinDuration = config.GetValue("OptConf:AlarmMinDuration"); } protected override async Task OnParametersSetAsync() @@ -210,6 +212,11 @@ namespace MP_TAB3.Components private static Logger Log = LogManager.GetCurrentClassLogger(); + /// + /// durata minima allarmi x abilitare invio email di notifica + /// + private decimal alarmMinDuration = 1; + #endregion Private Fields #region Private Properties diff --git a/MP-TAB3/MP-TAB3.csproj b/MP-TAB3/MP-TAB3.csproj index 534b8f3c..c76c0737 100644 --- a/MP-TAB3/MP-TAB3.csproj +++ b/MP-TAB3/MP-TAB3.csproj @@ -3,7 +3,7 @@ net6.0 enable - 6.16.2411.2519 + 6.16.2412.510 enable MP_TAB3 diff --git a/MP-TAB3/Resources/ChangeLog.html b/MP-TAB3/Resources/ChangeLog.html index 60e11fdc..f8ab57ba 100644 --- a/MP-TAB3/Resources/ChangeLog.html +++ b/MP-TAB3/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

Versione: 6.16.2411.2519

+

Versione: 6.16.2412.510


Note di rilascio:
  • diff --git a/MP-TAB3/Resources/VersNum.txt b/MP-TAB3/Resources/VersNum.txt index 8e9618d7..2dec4f35 100644 --- a/MP-TAB3/Resources/VersNum.txt +++ b/MP-TAB3/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2411.2519 +6.16.2412.510 diff --git a/MP-TAB3/Resources/manifest.xml b/MP-TAB3/Resources/manifest.xml index ac0c3d46..3c5654f7 100644 --- a/MP-TAB3/Resources/manifest.xml +++ b/MP-TAB3/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2411.2519 + 6.16.2412.510 https://nexus.steamware.net/repository/SWS/MP-TAB3/stable/LAST/MP-TAB3.zip https://nexus.steamware.net/repository/SWS/MP-TAB3/stable/LAST/ChangeLog.html false diff --git a/MP-TAB3/appsettings.Production.json b/MP-TAB3/appsettings.Production.json index e523a10d..b257de82 100644 --- a/MP-TAB3/appsettings.Production.json +++ b/MP-TAB3/appsettings.Production.json @@ -17,7 +17,9 @@ }, "OptConf": { "msRefresh": "1500", - "CodModulo": "MP-TAB3" + "CodModulo": "MP-TAB3", + "AlarmDest": "samuele.locatelli@egalware.com, ceo@steamware.net", + "AlarmMinDuration": 2 }, "ServerConf": { "BaseAddr": "https://iis04.egalware.com/MP/TAB3/", diff --git a/MP-TAB3/appsettings.json b/MP-TAB3/appsettings.json index 7635bd52..3d6347bd 100644 --- a/MP-TAB3/appsettings.json +++ b/MP-TAB3/appsettings.json @@ -58,7 +58,6 @@ } ] }, - "AlarmDest": "samuele.locatelli@egalware.com, ceo@steamware.net", "MailKitMailSettings": { "DisplayName": "MAPO EgalWare Email BOT", "From": "steamwarebot@outlook.it", @@ -70,7 +69,9 @@ "UseStartTls": true }, "OptConf": { - "msRefresh": "1001" + "msRefresh": "1001", + "AlarmDest": "samuele.locatelli@egalware.com, ceo@steamware.net", + "AlarmMinDuration": 0.45 }, "ServerConf": { "BaseAddr": "https://localhost:7295/MP/TAB3/", diff --git a/MP.SPEC/Pages/FluxLogStatus.razor b/MP.SPEC/Pages/FluxLogStatus.razor index 8a81ea96..d448e6d9 100644 --- a/MP.SPEC/Pages/FluxLogStatus.razor +++ b/MP.SPEC/Pages/FluxLogStatus.razor @@ -84,7 +84,7 @@
- +
From 24b8def4ee61950d1d333eb79f5d2c71a9d00a11 Mon Sep 17 00:00:00 2001 From: Samuele Locatelli Date: Mon, 23 Dec 2024 10:12:14 +0100 Subject: [PATCH 3/3] Update TAB3: display PODL/ODL detail sempre --- MP-TAB3/Components/CurrOdlDetail.razor | 161 ++++++++++++++++++++ MP-TAB3/Components/CurrOdlDetail.razor.cs | 93 ++++++++++++ MP-TAB3/Components/OdlMan.razor | 171 ++-------------------- MP-TAB3/Components/OdlMan.razor.cs | 35 +---- MP-TAB3/MP-TAB3.csproj | 2 +- MP-TAB3/Resources/ChangeLog.html | 2 +- MP-TAB3/Resources/VersNum.txt | 2 +- MP-TAB3/Resources/manifest.xml | 2 +- MP.Stats/MP.Stats.csproj | 4 +- MP.Stats/Resources/ChangeLog.html | 2 +- MP.Stats/Resources/VersNum.txt | 2 +- MP.Stats/Resources/manifest.xml | 2 +- 12 files changed, 280 insertions(+), 198 deletions(-) create mode 100644 MP-TAB3/Components/CurrOdlDetail.razor create mode 100644 MP-TAB3/Components/CurrOdlDetail.razor.cs diff --git a/MP-TAB3/Components/CurrOdlDetail.razor b/MP-TAB3/Components/CurrOdlDetail.razor new file mode 100644 index 00000000..0e79520b --- /dev/null +++ b/MP-TAB3/Components/CurrOdlDetail.razor @@ -0,0 +1,161 @@ + +
+
+
+
+

@titleOdlDetail

+
+ @if (IdxPOdlSel == 0) + { +
+
+ + +
+ @if (!InAttr) + { +
+ +
+ } +
+ } +
+
+
+
+
+ @if (!showPOdlData) + { + ODL: + } + else + { + P.ODL: + } +
+
+ @if (CurrOdl != null && !showPOdlData) + { + @CurrOdl.IdxOdl + } + else + { + @CurrPodl.IdxPromessa + } +
+
+
+
+ Rif: +
+
+ @CurrPodl.KeyRichiesta +
+
+
+
+ Cod: +
+
+ @CurrPodl.CodArticolo +
+
+
+
+
+
+ Articolo: +
+
+ @CurrPodl.DescArticolo +
+
+
+
+
+
+ Pezzi: +
+
+ @CurrPodl.NumPezzi.ToString("N0") +
+
+
+
+ TCiclo: +
+
+ @if (CurrOdl != null && CurrOdl.Tcassegnato > 0 && !showPOdlData) + { + @CurrOdl.Tcassegnato.ToString("N2") + } + else + { + @CurrPodl.Tcassegnato.ToString("N2") + } +
+
+
+
+ Pz/pallet: +
+
+ @if (CurrOdl != null && !showPOdlData) + { + @CurrOdl.PzPallet + } + else + { + @CurrPodl.PzPallet + } +
+
+
+
+ +
+
+ + diff --git a/MP-TAB3/Components/CurrOdlDetail.razor.cs b/MP-TAB3/Components/CurrOdlDetail.razor.cs new file mode 100644 index 00000000..5a7a4336 --- /dev/null +++ b/MP-TAB3/Components/CurrOdlDetail.razor.cs @@ -0,0 +1,93 @@ +using Microsoft.AspNetCore.Components; +using MP.Data.DatabaseModels; +using MP.Data.Services; +using System; + +namespace MP_TAB3.Components +{ + public partial class CurrOdlDetail + { + #region Public Properties + + [Parameter] + public ODLExpModel CurrOdl { get; set; } = null!; + + [Parameter] + public PODLExpModel CurrPodl { get; set; } = null!; + + [Parameter] + public EventCallback EC_ToggleOdlDetail { get; set; } + + [Parameter] + public EventCallback EC_TogglePOdl { get; set; } + + [Parameter] + public bool ForceCloseOdl { get; set; } + + [Parameter] + public int IdxPOdlSel { get; set; } + + [Parameter] + public bool InAttr { get; set; } + + [Parameter] + public bool ShowOdlDetail { get; set; } + + #endregion Public Properties + + #region Protected Properties + + [Inject] + protected MessageService MsgServ { get; set; } = null!; + + [Inject] + protected SharedMemService SMServ { get; set; } = null!; + + #endregion Protected Properties + + #region Protected Methods + + protected async Task ToggleOdlDetail() + { + await EC_ToggleOdlDetail.InvokeAsync(true); + } + + protected string Traduci(string lemma) + { + return SMServ.Traduci($"{baseLang}_{lemma}".ToUpper()); + } + + #endregion Protected Methods + + #region Private Properties + + private string baseLang + { + get => MsgServ.UserPrefGet("Lang"); + } + + private string cssDetailOdl + { + get => IdxPOdlSel > 0 ? "bg-info text-light" : "bg-warning"; + } + + private bool showPOdlData { get; set; } = true; + + private string titleOdlDetail + { + get => IdxPOdlSel > 0 ? "Verifica parametri attrezzaggio NUOVO PODL" : InAttr ? "Parametri PODL in Attrezzaggio" : "Parametri PODL Corrente"; + } + + private string txtBtnOdlDetail + { + get => ShowOdlDetail ? "Nascondi Dettaglio PODL" : "MOSTRA Dettaglio ODL Corrente"; + } + + private string txtShowXDL + { + get => showPOdlData ? "PODL" : "ODL"; + } + + #endregion Private Properties + } +} \ No newline at end of file diff --git a/MP-TAB3/Components/OdlMan.razor b/MP-TAB3/Components/OdlMan.razor index 26490fb3..ec776e85 100644 --- a/MP-TAB3/Components/OdlMan.razor +++ b/MP-TAB3/Components/OdlMan.razor @@ -65,6 +65,18 @@
} + + @if (!inAttr && !showOdlDetail) + { +
+ +
+ } + + if (showOdlDetail) + { + + } } else { @@ -104,164 +116,7 @@ @if (showOdlDetail || inAttr) { -
-
-
-
-

@titleOdlDetail

-
- @if (idxPOdlSel == 0) - { -
-
- - -
- @if (!inAttr) - { -
- -
- } -
- } -
-
-
-
-
- @if (!showPOdlData) - { - ODL: - } - else - { - P.ODL: - } -
-
- @if (currOdl != null && !showPOdlData) - { - @currOdl.IdxOdl - } - else - { - @currPodl.IdxPromessa - } -
-
-
-
- Rif: -
-
- @currPodl.KeyRichiesta -
-
-
-
- Cod: -
-
- @currPodl.CodArticolo -
-
-
-
-
-
- Articolo: -
-
- @currPodl.DescArticolo -
-
-
-
-
-
- Pezzi: -
-
- @currPodl.NumPezzi.ToString("N0") -
-
-
-
- TCiclo: -
-
- @if (currOdl != null && currOdl.Tcassegnato > 0 && !showPOdlData) - { - @currOdl.Tcassegnato.ToString("N2") - } - else - { - @currPodl.Tcassegnato.ToString("N2") - } -
-
-
-
- Pz/pallet: -
-
- @if (currOdl != null && !showPOdlData) - { - @currOdl.PzPallet - } - else - { - @currPodl.PzPallet - } -
-
-
-
- -
-
+ } @if (!inAttr && !showSplitOdlRiattr) diff --git a/MP-TAB3/Components/OdlMan.razor.cs b/MP-TAB3/Components/OdlMan.razor.cs index dbb0fca1..b7a9fc56 100644 --- a/MP-TAB3/Components/OdlMan.razor.cs +++ b/MP-TAB3/Components/OdlMan.razor.cs @@ -429,7 +429,6 @@ namespace MP_TAB3.Components 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; - // prima di tutto svuoto dati prod SDService.MachProdStRem(IdxMaccSel); @@ -791,7 +790,7 @@ namespace MP_TAB3.Components } IdxMaccParent = getIdxMaccParent(); checkAll(); - // verifica stato inAttr + // verifica stato InAttr await CheckAttr(); //salvo lastRec... lastRecMSE = RecMSE; @@ -1259,15 +1258,10 @@ namespace MP_TAB3.Components private bool cancelSetupEnabled { - //get => inAttr && enableSchedaTecnica && enableAnnullaSetup; + //get => InAttr && enableSchedaTecnica && enableAnnullaSetup; get => inAttr && enableAnnullaSetup; } - private string cssDetailOdl - { - get => IdxPOdlSel > 0 ? "bg-info text-light" : "bg-warning"; - } - private ODLExpModel currOdl { get; set; } = new ODLExpModel(); private PODLExpModel currPodl { get; set; } = new PODLExpModel(); @@ -1446,11 +1440,6 @@ namespace MP_TAB3.Components private decimal tcRichAttr { get; set; } = 0; - private string titleOdlDetail - { - get => IdxPOdlSel > 0 ? "Verifica parametri attrezzaggio NUOVO PODL" : inAttr ? "Parametri PODL in Attrezzaggio" : "Parametri PODL Corrente"; - } - private string txtBtnOdlDetail { get => showOdlDetail ? "Nascondi Dettaglio PODL" : "MOSTRA Dettaglio ODL Corrente"; @@ -1461,11 +1450,6 @@ namespace MP_TAB3.Components get => forceCloseOdl ? Traduci("ForceCloseODL") : Traduci("SplitCurrODL"); } - private string txtShowXDL - { - get => showPOdlData ? "PODL" : "ODL"; - } - #endregion Private Properties #region Private Methods @@ -1527,14 +1511,9 @@ namespace MP_TAB3.Components { // recupero pz da confermare datiProdAct = await TabDServ.StatoProdMacchina(IdxMaccSel, adesso); -#if false - var rawData = await TabDServ.PezziProdMacchina(IdxMaccSel); - prodMacchina = rawData.FirstOrDefault() ?? new PzProdModel(); -#endif + checkConfProd(); -#if false - if (prodMacchina.pezziNonConfermati > 0) -#endif + if (datiProdAct.Pz2RecTot > 0) { // confermo produzione ZERO pezzi (in setup) @@ -1542,16 +1521,10 @@ namespace MP_TAB3.Components { // confermo al netto dei pezzi lasciati... fatto = TabDServ.ConfermaProdMacchinaFull(IdxMaccSel, modoConfProd, datiProdAct.Pz2RecTot, 0, 0, adesso, MatrOpr); -#if false - fatto = TabDServ.ConfermaProdMacchinaFull(IdxMaccSel, modoConfProd, prodMacchina.pezziNonConfermati, 0, 0, adesso, MatrOpr); -#endif } else { fatto = TabDServ.ConfermaProdMacchina(IdxMaccSel, modoConfProd, datiProdAct.Pz2RecTot, 0, adesso, MatrOpr); -#if false - fatto = TabDServ.ConfermaProdMacchina(IdxMaccSel, modoConfProd, prodMacchina.pezziNonConfermati, 0, adesso, MatrOpr); -#endif } } } diff --git a/MP-TAB3/MP-TAB3.csproj b/MP-TAB3/MP-TAB3.csproj index c76c0737..524e7c03 100644 --- a/MP-TAB3/MP-TAB3.csproj +++ b/MP-TAB3/MP-TAB3.csproj @@ -3,7 +3,7 @@ net6.0 enable - 6.16.2412.510 + 6.16.2412.2310 enable MP_TAB3 diff --git a/MP-TAB3/Resources/ChangeLog.html b/MP-TAB3/Resources/ChangeLog.html index f8ab57ba..24028895 100644 --- a/MP-TAB3/Resources/ChangeLog.html +++ b/MP-TAB3/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo MAPOSPEC -

Versione: 6.16.2412.510

+

Versione: 6.16.2412.2310


Note di rilascio:
  • diff --git a/MP-TAB3/Resources/VersNum.txt b/MP-TAB3/Resources/VersNum.txt index 2dec4f35..7ab0f611 100644 --- a/MP-TAB3/Resources/VersNum.txt +++ b/MP-TAB3/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2412.510 +6.16.2412.2310 diff --git a/MP-TAB3/Resources/manifest.xml b/MP-TAB3/Resources/manifest.xml index 3c5654f7..a83db78c 100644 --- a/MP-TAB3/Resources/manifest.xml +++ b/MP-TAB3/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2412.510 + 6.16.2412.2310 https://nexus.steamware.net/repository/SWS/MP-TAB3/stable/LAST/MP-TAB3.zip https://nexus.steamware.net/repository/SWS/MP-TAB3/stable/LAST/ChangeLog.html false diff --git a/MP.Stats/MP.Stats.csproj b/MP.Stats/MP.Stats.csproj index 72450d8e..b82aa5ae 100644 --- a/MP.Stats/MP.Stats.csproj +++ b/MP.Stats/MP.Stats.csproj @@ -4,8 +4,8 @@ net6.0 MP.Stats 826e877c-ba70-4253-84cb-d0b1cafd4440 - 6.16.2411.0408 - 6.16.2411.0408 + 6.16.2412.1915 + 6.16.2412.1915 true $(NoWarn);1591 en diff --git a/MP.Stats/Resources/ChangeLog.html b/MP.Stats/Resources/ChangeLog.html index 5a6d723f..db45af15 100644 --- a/MP.Stats/Resources/ChangeLog.html +++ b/MP.Stats/Resources/ChangeLog.html @@ -1,6 +1,6 @@ Modulo statistiche MAPO -

    Versione: 6.16.2411.0408

    +

    Versione: 6.16.2412.1915


    Note di rilascio:
      diff --git a/MP.Stats/Resources/VersNum.txt b/MP.Stats/Resources/VersNum.txt index 3a6d8257..f7eab35c 100644 --- a/MP.Stats/Resources/VersNum.txt +++ b/MP.Stats/Resources/VersNum.txt @@ -1 +1 @@ -6.16.2411.0408 +6.16.2412.1915 diff --git a/MP.Stats/Resources/manifest.xml b/MP.Stats/Resources/manifest.xml index cb6c5598..1797af13 100644 --- a/MP.Stats/Resources/manifest.xml +++ b/MP.Stats/Resources/manifest.xml @@ -1,6 +1,6 @@ - 6.16.2411.0408 + 6.16.2412.1915 https://nexus.steamware.net/repository/SWS/MP-STATS/stable/LAST/MP.Stats.zip https://nexus.steamware.net/repository/SWS/MP-STATS/stable/LAST/ChangeLog.html false