Merge branch 'release/UpdateStoredAndReboot_01'

This commit is contained in:
Samuele Locatelli
2025-02-24 16:41:31 +01:00
6 changed files with 317 additions and 330 deletions
+12 -12
View File
@@ -258,7 +258,7 @@ namespace MP_IO.Controllers
{
if (memLayer.ML.CRI("_logLevel") > 6)
{
logger.lg.scriviLog($"Valori letti: idxMacchina: {id} | valore: {item.valore}", tipoLog.INFO);
logger.lg.scriviLog($"Valori letti: id: {id} | valore: {item.valore}", tipoLog.INFO);
}
// formato datetime come yyyyMMddHHmmssfff -->es: 20181223180600000
@@ -455,7 +455,7 @@ namespace MP_IO.Controllers
DateTime dataOraEvento = DateTime.Now;
if (memLayer.ML.CRI("_logLevel") > 6)
{
logger.lg.scriviLog($"Valori letti: idxMacchina: {id} | flux: {flux} valore: {valore}", tipoLog.INFO);
logger.lg.scriviLog($"Valori letti: id: {id} | flux: {flux} valore: {valore}", tipoLog.INFO);
}
try
{
@@ -1589,7 +1589,7 @@ namespace MP_IO.Controllers
DateTime dataOraEvento = DateTime.Now;
if (memLayer.ML.CRI("_logLevel") > 6)
{
logger.lg.scriviLog($"Valori letti: idxMacchina: {id} | valore: {valore}", tipoLog.INFO);
logger.lg.scriviLog($"Valori letti: id: {id} | valore: {valore}", tipoLog.INFO);
}
try
{
@@ -1652,7 +1652,7 @@ namespace MP_IO.Controllers
DateTime dataOraEvento = DateTime.Now;
if (memLayer.ML.CRI("_logLevel") > 6)
{
logger.lg.scriviLog($"Valori Live:{Environment.NewLine}idxMacchina: {id}{Environment.NewLine}liveData: {liveData}", tipoLog.INFO);
logger.lg.scriviLog($"Valori Live:{Environment.NewLine}id: {id}{Environment.NewLine}liveData: {liveData}", tipoLog.INFO);
}
try
{
@@ -2008,7 +2008,7 @@ namespace MP_IO.Controllers
string answ = "";
DateTime dataOraEvento = DateTime.Now;
// salvo SEMPRE log x questo tipo di dati!
logger.lg.scriviLog($"Salvataggio incremento contapezzi | idxMacchina: {id} | pezzi: {qty}", tipoLog.INFO);
logger.lg.scriviLog($"Salvataggio incremento contapezzi | id: {id} | pezzi: {qty}", tipoLog.INFO);
try
{
DataLayer DataLayerObj = new DataLayer();
@@ -2041,7 +2041,7 @@ namespace MP_IO.Controllers
string answ = "";
DateTime dataOraEvento = DateTime.Now;
// salvo SEMPRE log x questo tipo di dati!
logger.lg.scriviLog($"Salvataggio incremento contapezzi | idxMacchina: {id} | pezzi: {qty}", tipoLog.INFO);
logger.lg.scriviLog($"Salvataggio incremento contapezzi | id: {id} | pezzi: {qty}", tipoLog.INFO);
try
{
DataLayer DataLayerObj = new DataLayer();
@@ -2114,9 +2114,9 @@ namespace MP_IO.Controllers
}
/// <summary> Salva MAC adress + IP dopo il reboot
/// GET: IOB/sendReboot?idxMacchina=5&mac=18:C0:4D:37:3C:8C </summary> <param name="GWIP">IP
/// GET: IOB/sendReboot/SIMUL_05?mac=18:C0:4D:37:3C:8C </summary> <param name="GWIP">IP
/// del Gateway</param> <returns></returns>
public string sendReboot(string idxMacchina, string mac)
public string sendReboot(string id, string mac)
{
string answ = "NO";
string IPv4 = "";
@@ -2133,7 +2133,7 @@ namespace MP_IO.Controllers
{
// ora salvo che la macchina è stata (ri)avviata...
MapoDb.MapoDb MapoDbObj = new MapoDb.MapoDb();
MapoDbObj.registraStartup(idxMacchina, IPv4, agent, mac);
MapoDbObj.registraStartup(id, IPv4, agent, mac);
answ = "OK";
}
catch (Exception exc)
@@ -2179,7 +2179,7 @@ namespace MP_IO.Controllers
DateTime dataOraEvento = DateTime.Now;
if (memLayer.ML.CRI("_logLevel") > 6)
{
logger.lg.scriviLog($"Salvataggio counter | idxMacchina: {id}", tipoLog.INFO);
logger.lg.scriviLog($"Salvataggio counter | id: {id}", tipoLog.INFO);
}
try
{
@@ -2394,7 +2394,7 @@ namespace MP_IO.Controllers
DateTime dataOraEvento = DateTime.Now;
if (memLayer.ML.CRI("_logLevel") > 6)
{
logger.lg.scriviLog($"ulog | Valori letti: idxMacchina: {id} | flux: {flux} valore: {valore} | matrOpr: {matrOpr} | label: {label} | valNum: {valNum}", tipoLog.INFO);
logger.lg.scriviLog($"ulog | Valori letti: id: {id} | flux: {flux} valore: {valore} | matrOpr: {matrOpr} | label: {label} | valNum: {valNum}", tipoLog.INFO);
}
try
{
@@ -2591,7 +2591,7 @@ namespace MP_IO.Controllers
DateTime dataOraEvento = DateTime.Now;
if (memLayer.ML.CRI("_logLevel") > 6)
{
logger.lg.scriviLog($"{caller} | Richiesta snapshot dati FluxLog macchina: idxMacchina: {id} | periodo: {dtStart} - {dtEnd}", tipoLog.INFO);
logger.lg.scriviLog($"{caller} | Richiesta snapshot dati FluxLog macchina: id: {id} | periodo: {dtStart} - {dtEnd}", tipoLog.INFO);
}
try
{
+281 -279
View File
File diff suppressed because it is too large Load Diff
+15 -15
View File
@@ -4,32 +4,32 @@
Changes to this file may cause incorrect behavior and will be lost if
the code is regenerated.
</autogenerated>-->
<DiagramLayout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" ex:showrelationlabel="False" ViewPortX="-10" ViewPortY="-10" xmlns:ex="urn:schemas-microsoft-com:xml-msdatasource-layout-extended" xmlns="urn:schemas-microsoft-com:xml-msdatasource-layout">
<DiagramLayout xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" ex:showrelationlabel="False" ViewPortX="133" ViewPortY="964" xmlns:ex="urn:schemas-microsoft-com:xml-msdatasource-layout-extended" xmlns="urn:schemas-microsoft-com:xml-msdatasource-layout">
<Shapes>
<Shape ID="DesignTable:TempiCicloRilevati" ZOrder="15" X="20" Y="81" Height="248" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="121" />
<Shape ID="DesignTable:ODL" ZOrder="2" X="588" Y="452" Height="381" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
<Shape ID="DesignTable:AnagArticoli" ZOrder="1" X="20" Y="343" Height="343" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="178" />
<Shape ID="DesignTable:ODL" ZOrder="3" X="588" Y="452" Height="381" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
<Shape ID="DesignTable:AnagArticoli" ZOrder="2" X="20" Y="343" Height="343" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="178" />
<Shape ID="DesignTable:DatiMacchine" ZOrder="21" X="949" Y="353" Height="286" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="197" />
<Shape ID="DesignTable:PostazioniMapo" ZOrder="24" X="950" Y="39" Height="248" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="140" />
<Shape ID="DesignTable:stp_PzProd_getByMacchina" ZOrder="8" X="23" Y="754" Height="229" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="102" />
<Shape ID="DesignTable:stp_PzProd_getByMacchina" ZOrder="9" X="23" Y="754" Height="229" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="102" />
<Shape ID="DesignTable:DatiConfermati" ZOrder="23" X="585" Y="50" Height="343" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
<Shape ID="DesignTable:CalendFesteFerie" ZOrder="13" X="346" Y="364" Height="115" Width="242" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="64" />
<Shape ID="DesignTable:stp_TempoByIdxMaccPeriodClass" ZOrder="5" X="31" Y="976" Height="97" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="46" SplitterPosition="46" />
<Shape ID="DesignTable:CalendFesteFerie" ZOrder="14" X="346" Y="364" Height="115" Width="242" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="64" />
<Shape ID="DesignTable:stp_TempoByIdxMaccPeriodClass" ZOrder="6" X="31" Y="976" Height="97" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="46" SplitterPosition="46" />
<Shape ID="DesignTable:DatiProduzione" ZOrder="20" X="554" Y="922" Height="381" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
<Shape ID="DesignTable:stp_repDonati_getDatiProdMacchina" ZOrder="11" X="949" Y="688" Height="305" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
<Shape ID="DesignTable:stp_repDonati_getDatiProdMacchina" ZOrder="12" X="949" Y="688" Height="305" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
<Shape ID="DesignTable:stp_repDonati_getLastStatoDurataMacchina" ZOrder="22" X="957" Y="1072" Height="115" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="64" />
<Shape ID="DesignTable:stp_repDonati_getDatiProdMacchinaPeriodo" ZOrder="12" X="26" Y="1152" Height="172" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="121" />
<Shape ID="DesignTable:stp_repDonati_getDatiProdMacchinaPeriodo" ZOrder="13" X="26" Y="1152" Height="172" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="121" />
<Shape ID="DesignTable:TurniMacchina" ZOrder="16" X="363" Y="94" Height="191" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="102" />
<Shape ID="DesignTable:MappaStatoExpl" ZOrder="10" X="950" Y="1208" Height="381" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
<Shape ID="DesignTable:ResProdDett_splitODL" ZOrder="7" X="940" Y="2192" Height="191" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="140" />
<Shape ID="DesignTable:MappaStatoExpl" ZOrder="11" X="950" Y="1208" Height="381" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
<Shape ID="DesignTable:ResProdDett_splitODL" ZOrder="8" X="940" Y="2192" Height="191" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="140" />
<Shape ID="DesignTable:ResProdDett_splitGG" ZOrder="17" X="27" Y="2218" Height="210" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="159" />
<Shape ID="DesignTable:ResProdTot" ZOrder="18" X="544" Y="2122" Height="229" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="178" />
<Shape ID="DesignTable:RegistroControlli" ZOrder="3" X="536" Y="1403" Height="305" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="197" />
<Shape ID="DesignTable:RegistroScarti" ZOrder="4" X="25" Y="1371" Height="381" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
<Shape ID="DesignTable:PromesseODL" ZOrder="9" X="946" Y="1728" Height="381" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
<Shape ID="DesignTable:RegistroControlli" ZOrder="4" X="536" Y="1403" Height="305" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="197" />
<Shape ID="DesignTable:RegistroScarti" ZOrder="5" X="25" Y="1371" Height="381" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
<Shape ID="DesignTable:PromesseODL" ZOrder="10" X="946" Y="1728" Height="381" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
<Shape ID="DesignTable:ElencoConfermeProd" ZOrder="19" X="26" Y="1839" Height="305" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="235" />
<Shape ID="DesignTable:StatoProd" ZOrder="14" X="541" Y="1777" Height="286" Width="284" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="216" />
<Shape ID="DesignTable:Macchine2Slave" ZOrder="6" X="333" Y="559" Height="153" Width="237" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="64" />
<Shape ID="DesignTable:StatoProd" ZOrder="1" X="541" Y="1777" Height="305" Width="283" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="235" />
<Shape ID="DesignTable:Macchine2Slave" ZOrder="7" X="333" Y="559" Height="153" Width="237" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="64" />
</Shapes>
<Connectors />
</DiagramLayout>
+1
View File
@@ -832,6 +832,7 @@ namespace MapoDb
Log.Info($"Eccezione in ConfermaProduzione{Environment.NewLine}{exc}", tipoLog.EXCEPTION);
}
}
// 2025.02.19 portato da 100 a 1000 ms attesa x evitare che ODL sia avviato PRIMA della conferma
// attendo 1000 msec x chiudere ODL
Thread.Sleep(1000);
// chiamo splitOdl
-1
View File
@@ -385,7 +385,6 @@
<None Include="DS_ProdTempi.xsd">
<SubType>Designer</SubType>
<Generator>MSDataSetGenerator</Generator>
<LastGenOutput>DS_ProdTempi1.Designer.cs</LastGenOutput>
</None>
<None Include="DS_ProdTempi.xss">
<DependentUpon>DS_ProdTempi.xsd</DependentUpon>
+8 -23
View File
@@ -5,29 +5,14 @@
<section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
</configSections>
<connectionStrings>
<add name="MapoDb.Properties.Settings.MoonProConnectionString"
connectionString="Data Source=SQL2016DEV;Initial Catalog=MoonPro;Persist Security Info=True;User ID=sa;Password=keyhammer16; TrustServerCertificate=True;"
providerName="System.Data.SqlClient" />
<add name="MapoDb.Properties.Settings.MoonPro_IS_ConnectionString"
connectionString="Data Source=SQL2016DEV;Initial Catalog=MoonPro_IS_Donati;Persist Security Info=True;User ID=sa;Password=keyhammer16; TrustServerCertificate=True;"
providerName="System.Data.SqlClient" />
<add name="MapoDb.Properties.Settings.C_TRACKConnectionString"
connectionString="Data Source=SQL2016DEV;Initial Catalog=C_TRACK;Persist Security Info=True;User ID=sa;Password=keyhammer16; TrustServerCertificate=True;"
providerName="System.Data.SqlClient" />
<add name="MapoDb.Properties.Settings.MoonPro_ES3ConnectionString"
connectionString="Data Source=SQL2016DEV;Initial Catalog=MoonPro_ES3;Persist Security Info=True;User ID=sa;Password=keyhammer16; TrustServerCertificate=True;"
providerName="System.Data.SqlClient" />
<add name="MapoModel" connectionString="data source=SQL2016DEV;initial catalog=MoonPro;persist security info=True;user id=sa;password=keyhammer16;MultipleActiveResultSets=True;App=EntityFramework"
providerName="System.Data.SqlClient" />
<add name="MapoDb.Properties.Settings.MoonPro_IS_ArcaConnectionString"
connectionString="Data Source=SQL2016DEV;Initial Catalog=MoonPro_IS_EdilChim;Persist Security Info=True;User ID=sa;Password=keyhammer16; TrustServerCertificate=True;"
providerName="System.Data.SqlClient" />
<add name="MapoDb.Properties.Settings.MoonPro_MAGConnectionString"
connectionString="Data Source=SQL2016DEV;Initial Catalog=MoonPro_MAG;Persist Security Info=True;User ID=sa;Password=keyhammer16; TrustServerCertificate=True;"
providerName="System.Data.SqlClient" />
<add name="MapoDb.Properties.Settings.MoonPro_FluxDataConnectionString"
connectionString="Data Source=SQL2016DEV;Initial Catalog=MoonPro_FluxData;Persist Security Info=True;User ID=sa;Password=keyhammer16;TrustServerCertificate=True"
providerName="System.Data.SqlClient" />
<add name="MapoDb.Properties.Settings.MoonProConnectionString" connectionString="Data Source=SQL2016DEV;Initial Catalog=MoonPro;Persist Security Info=True;User ID=sa;Password=keyhammer16; TrustServerCertificate=True;" providerName="System.Data.SqlClient" />
<add name="MapoDb.Properties.Settings.MoonPro_IS_ConnectionString" connectionString="Data Source=SQL2016DEV;Initial Catalog=MoonPro_IS_Donati;Persist Security Info=True;User ID=sa;Password=keyhammer16; TrustServerCertificate=True;" providerName="System.Data.SqlClient" />
<add name="MapoDb.Properties.Settings.C_TRACKConnectionString" connectionString="Data Source=SQL2016DEV;Initial Catalog=C_TRACK;Persist Security Info=True;User ID=sa;Password=keyhammer16; TrustServerCertificate=True;" providerName="System.Data.SqlClient" />
<add name="MapoDb.Properties.Settings.MoonPro_ES3ConnectionString" connectionString="Data Source=SQL2016DEV;Initial Catalog=MoonPro_ES3;Persist Security Info=True;User ID=sa;Password=keyhammer16; TrustServerCertificate=True;" providerName="System.Data.SqlClient" />
<add name="MapoModel" connectionString="data source=SQL2016DEV;initial catalog=MoonPro;persist security info=True;user id=sa; password=keyhammer16; MultipleActiveResultSets=True; App=EntityFramework; TrustServerCertificate=True;" providerName="System.Data.SqlClient" />
<add name="MapoDb.Properties.Settings.MoonPro_IS_ArcaConnectionString" connectionString="Data Source=SQL2016DEV;Initial Catalog=MoonPro_IS_EdilChim;Persist Security Info=True;User ID=sa;Password=keyhammer16; TrustServerCertificate=True;" providerName="System.Data.SqlClient" />
<add name="MapoDb.Properties.Settings.MoonPro_MAGConnectionString" connectionString="Data Source=SQL2016DEV;Initial Catalog=MoonPro_MAG;Persist Security Info=True;User ID=sa;Password=keyhammer16; TrustServerCertificate=True;" providerName="System.Data.SqlClient" />
<add name="MapoDb.Properties.Settings.MoonPro_FluxDataConnectionString" connectionString="Data Source=SQL2016DEV;Initial Catalog=MoonPro_FluxData;Persist Security Info=True;User ID=sa;Password=keyhammer16;TrustServerCertificate=True;" providerName="System.Data.SqlClient" />
</connectionStrings>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.2" />