Compare commits
61 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 2bb407d55c | |||
| 97dc1095b6 | |||
| a090ef9fb2 | |||
| c5c95f75ae | |||
| c95fb1806f | |||
| d12d07c99e | |||
| 3103b7bba2 | |||
| b2932d927c | |||
| 68add4e08d | |||
| 5585c11ef5 | |||
| b9caa4ac74 | |||
| cde514eed8 | |||
| fad45a5635 | |||
| 9bf2265082 | |||
| e488619ae5 | |||
| babd8b25da | |||
| 5894cd63ce | |||
| 5a19d44b34 | |||
| 577cbe5c9d | |||
| e881006857 | |||
| 83fb0acfd0 | |||
| 04b3588e7f | |||
| c00e695c15 | |||
| c228c454f6 | |||
| e86495eab5 | |||
| 63e636cd36 | |||
| 1458a4cf5d | |||
| 6cf7331081 | |||
| 43402a785f | |||
| 88561778ce | |||
| 0d395fca33 | |||
| 09fea8f0e3 | |||
| 42531aac49 | |||
| bbfc3ca64d | |||
| 50e76bd30c | |||
| 6f6559ce67 | |||
| 5c2f69b8d2 | |||
| 0f7ce076f9 | |||
| 127b4ba1de | |||
| 9e2ee7d5b6 | |||
| 2a0b3f7e72 | |||
| 36dc4171e5 | |||
| 29057c5431 | |||
| a1336f9918 | |||
| 7ded45280f | |||
| ef139a2365 | |||
| fe6498f6ed | |||
| 22ad46ab8c | |||
| e098409b83 | |||
| 083be20f02 | |||
| f7ff6629ce | |||
| 2a4c0e8335 | |||
| bd1488bc02 | |||
| bab9bf504a | |||
| c7f7c4f9c8 | |||
| 36e0927bd1 | |||
| 7b132793d0 | |||
| d01fcf7578 | |||
| 539ed2508d | |||
| cacae4eebf | |||
| 34e31666cd |
@@ -180,7 +180,7 @@
|
|||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
|
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
|
<ErrorText>Questo progetto fa riferimento a uno o più pacchetti NuGet che non sono presenti in questo computer. Usare lo strumento di ripristino dei pacchetti NuGet per scaricarli. Per altre informazioni, vedere http://go.microsoft.com/fwlink/?LinkID=322105. Il file mancante è {0}.</ErrorText>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<Error Condition="!Exists('..\packages\cef.redist.x64.84.4.1\build\cef.redist.x64.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\cef.redist.x64.84.4.1\build\cef.redist.x64.props'))" />
|
<Error Condition="!Exists('..\packages\cef.redist.x64.84.4.1\build\cef.redist.x64.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\cef.redist.x64.84.4.1\build\cef.redist.x64.props'))" />
|
||||||
<Error Condition="!Exists('..\packages\cef.redist.x86.84.4.1\build\cef.redist.x86.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\cef.redist.x86.84.4.1\build\cef.redist.x86.props'))" />
|
<Error Condition="!Exists('..\packages\cef.redist.x86.84.4.1\build\cef.redist.x86.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\cef.redist.x86.84.4.1\build\cef.redist.x86.props'))" />
|
||||||
|
|||||||
@@ -4,6 +4,7 @@
|
|||||||
<ncVendor>S7NET</ncVendor>
|
<ncVendor>S7NET</ncVendor>
|
||||||
<!-- NO_NC/DEMO/FANUC/SIEMENS/OSAI/S7NET -->
|
<!-- NO_NC/DEMO/FANUC/SIEMENS/OSAI/S7NET -->
|
||||||
<showNcHMI>false</showNcHMI>
|
<showNcHMI>false</showNcHMI>
|
||||||
|
<!--<ncIpAddress>192.168.139.1</ncIpAddress>-->
|
||||||
<ncIpAddress>192.168.0.102</ncIpAddress>
|
<ncIpAddress>192.168.0.102</ncIpAddress>
|
||||||
<ncPort>102</ncPort>
|
<ncPort>102</ncPort>
|
||||||
<machineModel>Thermo 2020</machineModel>
|
<machineModel>Thermo 2020</machineModel>
|
||||||
@@ -31,6 +32,8 @@
|
|||||||
<CMSConnectReady>true</CMSConnectReady>
|
<CMSConnectReady>true</CMSConnectReady>
|
||||||
<maxAlarmsRows>50000</maxAlarmsRows>
|
<maxAlarmsRows>50000</maxAlarmsRows>
|
||||||
<alarmToDelete>5000</alarmToDelete>
|
<alarmToDelete>5000</alarmToDelete>
|
||||||
|
<maxSheetHistoryRows>10000</maxSheetHistoryRows>
|
||||||
|
<sheetHistoryToDelete>500</sheetHistoryToDelete>
|
||||||
</serverConfig>
|
</serverConfig>
|
||||||
<extSoftwares>
|
<extSoftwares>
|
||||||
<software>
|
<software>
|
||||||
@@ -138,7 +141,7 @@
|
|||||||
<thread name="expMan" value="30000" />
|
<thread name="expMan" value="30000" />
|
||||||
<thread name="functionEnab" value="300" />
|
<thread name="functionEnab" value="300" />
|
||||||
<thread name="gauges" value="500" />
|
<thread name="gauges" value="500" />
|
||||||
<thread name="m154" value="500" />
|
<thread name="m154" value="1000" />
|
||||||
<thread name="mCommands" value="250" />
|
<thread name="mCommands" value="250" />
|
||||||
<thread name="powerOn" value="500" />
|
<thread name="powerOn" value="500" />
|
||||||
<thread name="prodCycle" value="1000" />
|
<thread name="prodCycle" value="1000" />
|
||||||
|
|||||||
@@ -42,6 +42,8 @@
|
|||||||
<xs:element name="MTCApplicationName" type="xs:string" minOccurs="1" maxOccurs="1"/>
|
<xs:element name="MTCApplicationName" type="xs:string" minOccurs="1" maxOccurs="1"/>
|
||||||
<xs:element name="maxAlarmsRows" type="xs:int" minOccurs="1" maxOccurs="1"/>
|
<xs:element name="maxAlarmsRows" type="xs:int" minOccurs="1" maxOccurs="1"/>
|
||||||
<xs:element name="alarmToDelete" type="xs:int" minOccurs="1" maxOccurs="1"/>
|
<xs:element name="alarmToDelete" type="xs:int" minOccurs="1" maxOccurs="1"/>
|
||||||
|
<xs:element name="maxSheetHistoryRows" type="xs:int" minOccurs="1" maxOccurs="1"/>
|
||||||
|
<xs:element name="sheetHistoryToDelete" type="xs:int" minOccurs="1" maxOccurs="1"/>
|
||||||
<xs:element name="CMSConnectReady" type="xs:boolean" minOccurs="1" maxOccurs="1"/>
|
<xs:element name="CMSConnectReady" type="xs:boolean" minOccurs="1" maxOccurs="1"/>
|
||||||
</xs:all>
|
</xs:all>
|
||||||
</xs:complexType>
|
</xs:complexType>
|
||||||
|
|||||||
@@ -1033,6 +1033,8 @@ namespace Thermo.Active.Config
|
|||||||
MTCApplicationName = x.Element("MTCApplicationName").Value,
|
MTCApplicationName = x.Element("MTCApplicationName").Value,
|
||||||
MaxAlarmsRows = Convert.ToInt32(x.Element("maxAlarmsRows").Value),
|
MaxAlarmsRows = Convert.ToInt32(x.Element("maxAlarmsRows").Value),
|
||||||
AlarmToDelete = Convert.ToInt32(x.Element("alarmToDelete").Value),
|
AlarmToDelete = Convert.ToInt32(x.Element("alarmToDelete").Value),
|
||||||
|
MaxSheetHistoryRows = Convert.ToInt32(x.Element("maxSheetHistoryRows").Value),
|
||||||
|
SheetHistoryToDelete = Convert.ToInt32(x.Element("sheetHistoryToDelete").Value),
|
||||||
CmsConnectReady = Convert.ToBoolean(x.Element("CMSConnectReady").Value)
|
CmsConnectReady = Convert.ToBoolean(x.Element("CMSConnectReady").Value)
|
||||||
}).FirstOrDefault();
|
}).FirstOrDefault();
|
||||||
|
|
||||||
|
|||||||
@@ -49,6 +49,7 @@ public static class ThreadsFunctions
|
|||||||
public static int modulesRtCounter = 0;
|
public static int modulesRtCounter = 0;
|
||||||
public static int recipeRtCounter = 0;
|
public static int recipeRtCounter = 0;
|
||||||
public static bool reconnectionIsRunning = false;
|
public static bool reconnectionIsRunning = false;
|
||||||
|
public static bool forcetakeSnapshot = false;
|
||||||
|
|
||||||
#endregion Public Fields
|
#endregion Public Fields
|
||||||
|
|
||||||
@@ -193,34 +194,45 @@ public static class ThreadsFunctions
|
|||||||
StatReset();
|
StatReset();
|
||||||
NcAdapter ncAdapter = new NcAdapter();
|
NcAdapter ncAdapter = new NcAdapter();
|
||||||
CmsError libraryError = NO_ERROR;
|
CmsError libraryError = NO_ERROR;
|
||||||
// Run loop until NC is connected
|
try
|
||||||
while (!ncAdapter.numericalControl.NC_IsConnected())
|
|
||||||
{
|
{
|
||||||
// Try reconnection
|
// Run loop until NC is connected
|
||||||
libraryError = ncAdapter.Connect();
|
while (!ncAdapter.numericalControl.NC_IsConnected())
|
||||||
if (libraryError.errorCode == CMS_ERROR_CODES.SIEMENS_ENVIRONMENT_NOT_FOUND || libraryError.errorCode == CMS_ERROR_CODES.SIEMENS_HMI_NOT_RUNNING || libraryError.errorCode == CMS_ERROR_CODES.OSAI_TT_FOLDER_NOT_FOUND)
|
|
||||||
ManageLibraryError(libraryError);
|
|
||||||
else if (libraryError.errorCode != CMS_ERROR_CODES.OK)
|
|
||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
// Try reconnection
|
||||||
|
libraryError = ncAdapter.Connect();
|
||||||
|
if (libraryError.errorCode == CMS_ERROR_CODES.SIEMENS_ENVIRONMENT_NOT_FOUND || libraryError.errorCode == CMS_ERROR_CODES.SIEMENS_HMI_NOT_RUNNING || libraryError.errorCode == CMS_ERROR_CODES.OSAI_TT_FOLDER_NOT_FOUND)
|
||||||
|
ManageLibraryError(libraryError);
|
||||||
|
else if (libraryError.errorCode != CMS_ERROR_CODES.OK)
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
|
|
||||||
|
// Send status to UI
|
||||||
|
MessageServices.Current.Publish(SEND_NC_STATUS_UI, null, ncAdapter.numericalControl.NC_IsConnected());
|
||||||
|
// Send status to signalr
|
||||||
|
MessageServices.Current.Publish(SEND_NC_STATUS, null, ncAdapter.numericalControl.NC_IsConnected());
|
||||||
|
|
||||||
|
Thread.Sleep(1000);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Send status to UI
|
if (!libraryError.IsError())
|
||||||
MessageServices.Current.Publish(SEND_NC_STATUS_UI, null, ncAdapter.numericalControl.NC_IsConnected());
|
{
|
||||||
// Send status to signalr
|
if (ServerStartupConfig.AutoOpenCmsClient)
|
||||||
MessageServices.Current.Publish(SEND_NC_STATUS, null, ncAdapter.numericalControl.NC_IsConnected());
|
StartCMSClient();
|
||||||
|
|
||||||
Thread.Sleep(1000);
|
// Start/Restart NC threads
|
||||||
|
ThreadsHandler.StartWorkers();
|
||||||
|
reconnectionIsRunning = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
catch (ThreadAbortException ex)
|
||||||
if (!libraryError.IsError())
|
|
||||||
{
|
{
|
||||||
if (ServerStartupConfig.AutoOpenCmsClient)
|
ncAdapter.Dispose();
|
||||||
StartCMSClient();
|
}
|
||||||
|
finally
|
||||||
// Start/Restart NC threads
|
{
|
||||||
ThreadsHandler.StartWorkers();
|
ncAdapter.Dispose();
|
||||||
reconnectionIsRunning = false;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -326,6 +338,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -345,6 +361,14 @@ public static class ThreadsFunctions
|
|||||||
// avvio oggetto thermocam
|
// avvio oggetto thermocam
|
||||||
ThermoCamComunicator TCCom = new ThermoCamComunicator(true);
|
ThermoCamComunicator TCCom = new ThermoCamComunicator(true);
|
||||||
Stopwatch sw = new Stopwatch();
|
Stopwatch sw = new Stopwatch();
|
||||||
|
forcetakeSnapshot = false;
|
||||||
|
|
||||||
|
|
||||||
|
RegistrationInfo takeReginfo = MessageServices.Current.Subscribe(TAKE_SNAPSHOT_THERMO, (a, b) =>
|
||||||
|
{
|
||||||
|
ThreadsFunctions.forcetakeSnapshot = true;
|
||||||
|
});
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
// Try connection
|
// Try connection
|
||||||
@@ -365,11 +389,13 @@ public static class ThreadsFunctions
|
|||||||
if (libraryError.IsError())
|
if (libraryError.IsError())
|
||||||
ManageLibraryError(libraryError);
|
ManageLibraryError(libraryError);
|
||||||
|
|
||||||
if (flirImageReq)
|
if (flirImageReq || forcetakeSnapshot)
|
||||||
{
|
{
|
||||||
|
forcetakeSnapshot = false;
|
||||||
bool done = false;
|
bool done = false;
|
||||||
// if requested --> give ack!
|
// if requested --> give ack!
|
||||||
ncAdapter.ManageFlirStrobe();
|
if (flirImageReq)
|
||||||
|
ncAdapter.ManageFlirStrobe();
|
||||||
// requesto photo from library
|
// requesto photo from library
|
||||||
NcAdapter.lastThermoImage = TCCom.takePicture();
|
NcAdapter.lastThermoImage = TCCom.takePicture();
|
||||||
done = !string.IsNullOrEmpty(NcAdapter.lastThermoImage);
|
done = !string.IsNullOrEmpty(NcAdapter.lastThermoImage);
|
||||||
@@ -390,13 +416,20 @@ public static class ThreadsFunctions
|
|||||||
}
|
}
|
||||||
// salvo dati temp sul PLC
|
// salvo dati temp sul PLC
|
||||||
ncAdapter.WriteRecipeWarmChTCamTempAct(actualTemp);
|
ncAdapter.WriteRecipeWarmChTCamTempAct(actualTemp);
|
||||||
|
NcAdapter.lastImageTaken = DateTime.Now;
|
||||||
// give PLC strobe for uploaded Actual TEMP from image
|
// give PLC strobe for uploaded Actual TEMP from image
|
||||||
ncAdapter.SendTCamImageReadyStrb();
|
if(flirImageReq)
|
||||||
|
ncAdapter.SendTCamImageReadyStrb();
|
||||||
|
|
||||||
|
|
||||||
|
MessageServices.Current.Publish(SEND_NEWTCAMIMAGE, null, NcAdapter.lastImageTaken);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// salvo status thermocam...
|
// salvo status thermocam...
|
||||||
NcAdapter.cameraIsConnected = TCCom.CameraIsConnected;
|
NcAdapter.cameraIsConnected = TCCom.CameraIsConnected;
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
RestoreConnection();
|
RestoreConnection();
|
||||||
@@ -417,7 +450,8 @@ public static class ThreadsFunctions
|
|||||||
}
|
}
|
||||||
finally
|
finally
|
||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
MessageServices.Current.UnSubscribe(takeReginfo);
|
||||||
|
ncAdapter.Dispose();
|
||||||
// chiudo thermocam
|
// chiudo thermocam
|
||||||
TCCom.Dispose();
|
TCCom.Dispose();
|
||||||
}
|
}
|
||||||
@@ -495,6 +529,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ManageWatchdog()
|
public static void ManageWatchdog()
|
||||||
@@ -541,6 +579,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadAlarms()
|
public static void ReadAlarms()
|
||||||
@@ -585,6 +627,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadAreaData()
|
public static void ReadAreaData()
|
||||||
@@ -627,6 +673,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -680,6 +730,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -729,6 +783,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadEnabledFunctionality()
|
public static void ReadEnabledFunctionality()
|
||||||
@@ -773,6 +831,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadExpiredMaintenances()
|
public static void ReadExpiredMaintenances()
|
||||||
@@ -827,6 +889,11 @@ public static class ThreadsFunctions
|
|||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -871,6 +938,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadM154Data()
|
public static void ReadM154Data()
|
||||||
@@ -1045,6 +1116,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadMComandsData()
|
public static void ReadMComandsData()
|
||||||
@@ -1091,6 +1166,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadModulesData()
|
public static void ReadModulesData()
|
||||||
@@ -1133,6 +1212,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadPowerOnData()
|
public static void ReadPowerOnData()
|
||||||
@@ -1175,6 +1258,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadProcessesPPStatus()
|
public static void ReadProcessesPPStatus()
|
||||||
@@ -1221,6 +1308,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadProdCycleData()
|
public static void ReadProdCycleData()
|
||||||
@@ -1264,6 +1355,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadProdInfoData()
|
public static void ReadProdInfoData()
|
||||||
@@ -1307,6 +1402,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadProdPanelData()
|
public static void ReadProdPanelData()
|
||||||
@@ -1350,6 +1449,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadRecipeData()
|
public static void ReadRecipeData()
|
||||||
@@ -1376,39 +1479,46 @@ public static class ThreadsFunctions
|
|||||||
// Check if client is connected
|
// Check if client is connected
|
||||||
if (ncAdapter.numericalControl.NC_IsConnected())
|
if (ncAdapter.numericalControl.NC_IsConnected())
|
||||||
{
|
{
|
||||||
// Get new data from PLC
|
// controllo su redis che NON sia bloccata lettura ricetta..
|
||||||
libraryError = ncAdapter.ReadRecipeData(onlyRt, false, out Dictionary<string, DTORecipeParam> currRecipe);
|
if (!RedisController.getRecipeReadSem)
|
||||||
if (libraryError.IsError())
|
|
||||||
ManageLibraryError(libraryError);
|
|
||||||
|
|
||||||
MessageServices.Current.Publish(SEND_THERMO_RECIPE_FULL, null, currRecipe);
|
|
||||||
|
|
||||||
// ora gestisco la overview!
|
|
||||||
libraryError = ncAdapter.GetRecipeOverview(out Dictionary<RecipeSection, RecipeCatStatus> currOverview);
|
|
||||||
if (libraryError.IsError())
|
|
||||||
ManageLibraryError(libraryError);
|
|
||||||
|
|
||||||
MessageServices.Current.Publish(SEND_THERMO_RECIPE_OVERWIEW, null, currOverview);
|
|
||||||
|
|
||||||
// ora gestisco la lettura della overview di "modificata
|
|
||||||
DTORecipeStatus message = new DTORecipeStatus()
|
|
||||||
{
|
{
|
||||||
recipeName = NcAdapter.RecipeLiveData.RecipeName,
|
// Get new data from PLC
|
||||||
hasChanged = NcAdapter.RecipeLiveData.hasChanged
|
libraryError = ncAdapter.ReadRecipeData(onlyRt, false, out Dictionary<string, DTORecipeParam> currRecipe);
|
||||||
};
|
if (libraryError.IsError())
|
||||||
|
ManageLibraryError(libraryError);
|
||||||
|
|
||||||
MessageServices.Current.Publish(SEND_THERMO_RECIPE_CHANGED, null, message);
|
MessageServices.Current.Publish(SEND_THERMO_RECIPE_FULL, null, currRecipe);
|
||||||
|
|
||||||
// verifico se dal PLC è segnalato che i setpointHMI sono invalidati, nel qual caso INVIO
|
// ora gestisco la overview!
|
||||||
bool setpointHmiInvalidated = false;
|
libraryError = ncAdapter.GetRecipeOverview(out Dictionary<RecipeSection, RecipeCatStatus> currOverview);
|
||||||
libraryError = ncAdapter.checkSetpointInvalidated(out setpointHmiInvalidated);
|
if (libraryError.IsError())
|
||||||
if (setpointHmiInvalidated)
|
ManageLibraryError(libraryError);
|
||||||
{
|
|
||||||
// ora gestisco l'ack della richiesta
|
MessageServices.Current.Publish(SEND_THERMO_RECIPE_OVERWIEW, null, currOverview);
|
||||||
libraryError = ncAdapter.doAckSetpointInvalidated();
|
|
||||||
|
// ora gestisco la lettura della overview di "modificata
|
||||||
|
DTORecipeStatus message = new DTORecipeStatus()
|
||||||
|
{
|
||||||
|
recipeName = NcAdapter.RecipeLiveData.RecipeName,
|
||||||
|
hasChanged = NcAdapter.RecipeLiveData.hasChanged
|
||||||
|
};
|
||||||
|
|
||||||
|
MessageServices.Current.Publish(SEND_THERMO_RECIPE_CHANGED, null, message);
|
||||||
|
|
||||||
|
// verifico se dal PLC è segnalato che i setpointHMI sono invalidati, nel qual caso INVIO
|
||||||
|
bool setpointHmiInvalidated = false;
|
||||||
|
libraryError = ncAdapter.checkSetpointInvalidated(out setpointHmiInvalidated);
|
||||||
|
if (setpointHmiInvalidated)
|
||||||
|
{
|
||||||
|
// ora gestisco l'ack della richiesta
|
||||||
|
libraryError = ncAdapter.doAckSetpointInvalidated();
|
||||||
|
}
|
||||||
|
// pubblico booleana dei setpointHMI invalidati
|
||||||
|
MessageServices.Current.Publish(SEND_THERMO_RECIPE_SETPOINTHMI_CHANGED, null, setpointHmiInvalidated);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
}
|
}
|
||||||
// pubblico booleana dei setpointHMI invalidati
|
|
||||||
MessageServices.Current.Publish(SEND_THERMO_RECIPE_SETPOINTHMI_CHANGED, null, setpointHmiInvalidated);
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
RestoreConnection();
|
RestoreConnection();
|
||||||
@@ -1425,6 +1535,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadScadaData()
|
public static void ReadScadaData()
|
||||||
@@ -1470,6 +1584,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadUserSoftKeysData()
|
public static void ReadUserSoftKeysData()
|
||||||
@@ -1514,6 +1632,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void ReadWarmersData()
|
public static void ReadWarmersData()
|
||||||
@@ -1531,33 +1653,38 @@ public static class ThreadsFunctions
|
|||||||
bool useCache = false;
|
bool useCache = false;
|
||||||
while (true)
|
while (true)
|
||||||
{
|
{
|
||||||
sw.Restart();
|
|
||||||
|
|
||||||
// Check if client is connected
|
// controllo su redis che NON sia bloccata lettura ricetta..
|
||||||
if (ncAdapter.numericalControl.NC_IsConnected())
|
if (!RedisController.getWarmersReadSem)
|
||||||
{
|
{
|
||||||
if (cacheWarmers)
|
sw.Restart();
|
||||||
|
|
||||||
|
// Check if client is connected
|
||||||
|
if (ncAdapter.numericalControl.NC_IsConnected())
|
||||||
{
|
{
|
||||||
// every 10 reads all data...
|
if (cacheWarmers)
|
||||||
useCache = (readCount != 0);
|
{
|
||||||
readCount++;
|
// every 10 reads all data...
|
||||||
// ciclo resettato ogni 20
|
useCache = (readCount != 0);
|
||||||
readCount = readCount % 20;
|
readCount++;
|
||||||
|
// ciclo resettato ogni 20
|
||||||
|
readCount = readCount % 20;
|
||||||
|
}
|
||||||
|
// Get new data from PLC
|
||||||
|
libraryError = ncAdapter.ReadWarmers(useCache, out Dictionary<int, DTOWarmers> currWarmers);
|
||||||
|
if (libraryError.IsError())
|
||||||
|
ManageLibraryError(libraryError);
|
||||||
|
// pubblico
|
||||||
|
MessageServices.Current.Publish(SEND_THERMO_WARMERS_DATA, null, currWarmers);
|
||||||
}
|
}
|
||||||
// Get new data from PLC
|
else
|
||||||
libraryError = ncAdapter.ReadWarmers(useCache, out Dictionary<int, DTOWarmers> currWarmers);
|
RestoreConnection();
|
||||||
if (libraryError.IsError())
|
|
||||||
ManageLibraryError(libraryError);
|
sw.Stop();
|
||||||
// pubblico
|
|
||||||
MessageServices.Current.Publish(SEND_THERMO_WARMERS_DATA, null, currWarmers);
|
// Update thread timer
|
||||||
|
UpdateStat(MethodBase.GetCurrentMethod().Name, sw.ElapsedMilliseconds);
|
||||||
}
|
}
|
||||||
else
|
|
||||||
RestoreConnection();
|
|
||||||
|
|
||||||
sw.Stop();
|
|
||||||
|
|
||||||
// Update thread timer
|
|
||||||
UpdateStat(MethodBase.GetCurrentMethod().Name, sw.ElapsedMilliseconds);
|
|
||||||
// Wait
|
// Wait
|
||||||
Thread.Sleep(CalcSleepTime(samplMsec("warmers"), (int)sw.ElapsedMilliseconds));
|
Thread.Sleep(CalcSleepTime(samplMsec("warmers"), (int)sw.ElapsedMilliseconds));
|
||||||
}
|
}
|
||||||
@@ -1566,6 +1693,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void RestoreConnection()
|
public static void RestoreConnection()
|
||||||
@@ -1659,6 +1790,10 @@ public static class ThreadsFunctions
|
|||||||
{
|
{
|
||||||
ncAdapter.Dispose();
|
ncAdapter.Dispose();
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void StartCMSClient()
|
public static void StartCMSClient()
|
||||||
|
|||||||
@@ -38,10 +38,6 @@
|
|||||||
<assemblyIdentity name="System.Runtime.InteropServices.RuntimeInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
<assemblyIdentity name="System.Runtime.InteropServices.RuntimeInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
||||||
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
|
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
|
||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
|
||||||
<assemblyIdentity name="S7.Net" publicKeyToken="d5812d469e84c693" culture="neutral" />
|
|
||||||
<bindingRedirect oldVersion="0.0.0.0-0.8.1.0" newVersion="0.8.1.0" />
|
|
||||||
</dependentAssembly>
|
|
||||||
</assemblyBinding>
|
</assemblyBinding>
|
||||||
</runtime>
|
</runtime>
|
||||||
</configuration>
|
</configuration>
|
||||||
@@ -57,10 +57,6 @@
|
|||||||
<assemblyIdentity name="System.Runtime.InteropServices.RuntimeInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
<assemblyIdentity name="System.Runtime.InteropServices.RuntimeInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
||||||
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
|
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
|
||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
|
||||||
<assemblyIdentity name="S7.Net" publicKeyToken="d5812d469e84c693" culture="neutral" />
|
|
||||||
<bindingRedirect oldVersion="0.0.0.0-0.8.1.0" newVersion="0.8.1.0" />
|
|
||||||
</dependentAssembly>
|
|
||||||
</assemblyBinding>
|
</assemblyBinding>
|
||||||
</runtime>
|
</runtime>
|
||||||
</configuration>
|
</configuration>
|
||||||
@@ -0,0 +1,83 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using Thermo.Active.Model.DatabaseModels;
|
||||||
|
using static Thermo.Active.Config.ServerConfig;
|
||||||
|
|
||||||
|
namespace Thermo.Active.Database.Controllers
|
||||||
|
{
|
||||||
|
public class HistorySheetsController : IDisposable
|
||||||
|
{
|
||||||
|
private DatabaseContext dbCtx;
|
||||||
|
|
||||||
|
public HistorySheetsController()
|
||||||
|
{
|
||||||
|
// Initialize database context
|
||||||
|
dbCtx = new DatabaseContext();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void Dispose()
|
||||||
|
{
|
||||||
|
dbCtx.Dispose();
|
||||||
|
}
|
||||||
|
|
||||||
|
public HistorySheetModel Create(string recipe, short piece, float value1, float value2, float value3, ushort typeval)
|
||||||
|
{
|
||||||
|
HistorySheetModel mod = new HistorySheetModel()
|
||||||
|
{
|
||||||
|
DtEvent = DateTime.Now,
|
||||||
|
RecipeName = recipe,
|
||||||
|
NumDone = piece,
|
||||||
|
FirstVal = value1,
|
||||||
|
SecondVal = value2,
|
||||||
|
ThirdVal = value3,
|
||||||
|
TypeVal = typeval
|
||||||
|
};
|
||||||
|
|
||||||
|
// Add to database
|
||||||
|
dbCtx.HistorySheet.Add(mod);
|
||||||
|
// Commit changes
|
||||||
|
dbCtx.SaveChanges();
|
||||||
|
|
||||||
|
return mod;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public void Clean()
|
||||||
|
{
|
||||||
|
if (this.count() >= ServerStartupConfig.MaxSheetHistoryRows)
|
||||||
|
{
|
||||||
|
dbCtx.Database.ExecuteSqlCommand("DELETE FROM historysheets LIMIT {0}", ServerStartupConfig.SheetHistoryToDelete);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<HistorySheetModel> GetData(int start, int number)
|
||||||
|
{
|
||||||
|
// Get page numbers
|
||||||
|
return dbCtx
|
||||||
|
.HistorySheet
|
||||||
|
.OrderByDescending(x => x.DtEvent).Skip(start).Take(number).ToList();
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<HistorySheetModel> GetData()
|
||||||
|
{
|
||||||
|
// Get page numbers
|
||||||
|
return dbCtx
|
||||||
|
.HistorySheet
|
||||||
|
.OrderByDescending(x => x.DtEvent).ToList();
|
||||||
|
}
|
||||||
|
public int count()
|
||||||
|
{
|
||||||
|
// Get page numbers
|
||||||
|
return dbCtx
|
||||||
|
.HistorySheet.Count();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -21,6 +21,12 @@ namespace Thermo.Active.Database.Controllers
|
|||||||
// Initialize database context
|
// Initialize database context
|
||||||
dbCtx = new DatabaseContext();
|
dbCtx = new DatabaseContext();
|
||||||
}
|
}
|
||||||
|
public void Dispose()
|
||||||
|
{
|
||||||
|
// Clear database context
|
||||||
|
dbCtx.Dispose();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
#endregion Public Constructors
|
#endregion Public Constructors
|
||||||
|
|
||||||
@@ -80,11 +86,6 @@ namespace Thermo.Active.Database.Controllers
|
|||||||
return prodData;
|
return prodData;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void Dispose()
|
|
||||||
{
|
|
||||||
// Clear database context
|
|
||||||
dbCtx.Dispose();
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Get record by NumDone
|
/// Get record by NumDone
|
||||||
|
|||||||
@@ -36,6 +36,12 @@ namespace Thermo.Active.Database.Controllers
|
|||||||
private const string machineEventKpis = "Events:Kpis";
|
private const string machineEventKpis = "Events:Kpis";
|
||||||
private const string machineMessagePath = "Events:Messages";
|
private const string machineMessagePath = "Events:Messages";
|
||||||
|
|
||||||
|
|
||||||
|
private const string thermoSemRecipe = "Thermo:Semaphore:All";
|
||||||
|
private const string thermoSemWarmers = "Thermo:Semaphore:All";
|
||||||
|
//private const string thermoSemRecipe = "Thermo:Semaphore:Recipe";
|
||||||
|
//private const string thermoSemWarmers = "Thermo:Semaphore:Warmers";
|
||||||
|
|
||||||
public static void WriteProductionNotification(uint ProductionProcess, string Notification)
|
public static void WriteProductionNotification(uint ProductionProcess, string Notification)
|
||||||
{
|
{
|
||||||
string redisHash = redUtil.man.redHash(redisNotificationAddress).Replace("%NN%", ProductionProcess.ToString("00"));
|
string redisHash = redUtil.man.redHash(redisNotificationAddress).Replace("%NN%", ProductionProcess.ToString("00"));
|
||||||
@@ -246,5 +252,89 @@ namespace Thermo.Active.Database.Controllers
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Imposta semaforo Recipe
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="doLock">true: imposto lock per 5 sec, false: tolgo lock (stringa vuota)</param>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static bool setRecipeReadSem(bool doLock)
|
||||||
|
{
|
||||||
|
return setSemaphore(doLock, redUtil.man.redHash(thermoSemRecipe));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Restituisce semaforo Recipe
|
||||||
|
/// </summary>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static bool getRecipeReadSem
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
return getSemaphore(redUtil.man.redHash(thermoSemRecipe));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/// <summary>
|
||||||
|
/// Imposta semaforo Warmers
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="doLock">true: imposto lock per 5 sec, false: tolgo lock (stringa vuota)</param>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static bool setWarmersReadSem(bool doLock)
|
||||||
|
{
|
||||||
|
return setSemaphore(doLock, redUtil.man.redHash(thermoSemWarmers));
|
||||||
|
}
|
||||||
|
/// <summary>
|
||||||
|
/// Restituisce semaforo Warmers
|
||||||
|
/// </summary>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static bool getWarmersReadSem
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
return getSemaphore(redUtil.man.redHash(thermoSemWarmers));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Gestione generica SET semaforo
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="doLock"></param>
|
||||||
|
/// <param name="redisHash"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
private static bool setSemaphore(bool doLock, string redisHash)
|
||||||
|
{
|
||||||
|
bool answ = true;
|
||||||
|
int ttlSec = 5;
|
||||||
|
string rawData = $"{DateTime.Now}";
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (doLock)
|
||||||
|
{
|
||||||
|
// imposto lock
|
||||||
|
answ = redUtil.man.setRSV(redisHash, rawData, ttlSec);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// metto empty string a 1 sec
|
||||||
|
answ = redUtil.man.setRSV(redisHash, "", 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch
|
||||||
|
{ }
|
||||||
|
return answ;
|
||||||
|
}
|
||||||
|
/// <summary>
|
||||||
|
/// Gestione generica GET semafoto
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="redisHash"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
private static bool getSemaphore(string redisHash)
|
||||||
|
{
|
||||||
|
bool answ = true;
|
||||||
|
string rawData = redUtil.man.getRSV(redisHash);
|
||||||
|
// se non nulla --> ho semaforo!
|
||||||
|
answ = !string.IsNullOrEmpty(rawData);
|
||||||
|
return answ;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -44,7 +44,7 @@ namespace Thermo.Active.Database
|
|||||||
|
|
||||||
// thermo!
|
// thermo!
|
||||||
public DbSet<ProdInfoModel> ProdInfo { get; set; }
|
public DbSet<ProdInfoModel> ProdInfo { get; set; }
|
||||||
|
public DbSet<HistorySheetModel> HistorySheet { get; set; }
|
||||||
|
|
||||||
// Create migration string
|
// Create migration string
|
||||||
public static string CONNECTION_STRING = "Server = " + "localhost" + "; Database=" + DATABASE_NAME + ";Uid=" + DATABASE_USER + ";Pwd=" + DATABASE_PWD + ";";
|
public static string CONNECTION_STRING = "Server = " + "localhost" + "; Database=" + DATABASE_NAME + ";Uid=" + DATABASE_USER + ";Pwd=" + DATABASE_PWD + ";";
|
||||||
|
|||||||
@@ -0,0 +1,29 @@
|
|||||||
|
// <auto-generated />
|
||||||
|
namespace Thermo.Active.Database.Migrations
|
||||||
|
{
|
||||||
|
using System.CodeDom.Compiler;
|
||||||
|
using System.Data.Entity.Migrations;
|
||||||
|
using System.Data.Entity.Migrations.Infrastructure;
|
||||||
|
using System.Resources;
|
||||||
|
|
||||||
|
[GeneratedCode("EntityFramework.Migrations", "6.2.0-61023")]
|
||||||
|
public sealed partial class HistorySheets : IMigrationMetadata
|
||||||
|
{
|
||||||
|
private readonly ResourceManager Resources = new ResourceManager(typeof(HistorySheets));
|
||||||
|
|
||||||
|
string IMigrationMetadata.Id
|
||||||
|
{
|
||||||
|
get { return "202103191608500_HistorySheets"; }
|
||||||
|
}
|
||||||
|
|
||||||
|
string IMigrationMetadata.Source
|
||||||
|
{
|
||||||
|
get { return null; }
|
||||||
|
}
|
||||||
|
|
||||||
|
string IMigrationMetadata.Target
|
||||||
|
{
|
||||||
|
get { return Resources.GetString("Target"); }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,29 @@
|
|||||||
|
namespace Thermo.Active.Database.Migrations
|
||||||
|
{
|
||||||
|
using System;
|
||||||
|
using System.Data.Entity.Migrations;
|
||||||
|
|
||||||
|
public partial class HistorySheets : DbMigration
|
||||||
|
{
|
||||||
|
public override void Up()
|
||||||
|
{
|
||||||
|
CreateTable(
|
||||||
|
"dbo.HistorySheets",
|
||||||
|
c => new
|
||||||
|
{
|
||||||
|
DtEvent = c.DateTime(nullable: false, precision: 0),
|
||||||
|
Recipe = c.String(unicode: false),
|
||||||
|
FirstVal = c.Single(nullable: false),
|
||||||
|
SecondVal = c.Single(nullable: false),
|
||||||
|
ThirdVal = c.Single(nullable: false),
|
||||||
|
})
|
||||||
|
.PrimaryKey(t => t.DtEvent);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void Down()
|
||||||
|
{
|
||||||
|
DropTable("dbo.HistorySheets");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
File diff suppressed because one or more lines are too long
+29
@@ -0,0 +1,29 @@
|
|||||||
|
// <auto-generated />
|
||||||
|
namespace Thermo.Active.Database.Migrations
|
||||||
|
{
|
||||||
|
using System.CodeDom.Compiler;
|
||||||
|
using System.Data.Entity.Migrations;
|
||||||
|
using System.Data.Entity.Migrations.Infrastructure;
|
||||||
|
using System.Resources;
|
||||||
|
|
||||||
|
[GeneratedCode("EntityFramework.Migrations", "6.2.0-61023")]
|
||||||
|
public sealed partial class HistorySheetsCycle : IMigrationMetadata
|
||||||
|
{
|
||||||
|
private readonly ResourceManager Resources = new ResourceManager(typeof(HistorySheetsCycle));
|
||||||
|
|
||||||
|
string IMigrationMetadata.Id
|
||||||
|
{
|
||||||
|
get { return "202103191626072_HistorySheetsCycle"; }
|
||||||
|
}
|
||||||
|
|
||||||
|
string IMigrationMetadata.Source
|
||||||
|
{
|
||||||
|
get { return null; }
|
||||||
|
}
|
||||||
|
|
||||||
|
string IMigrationMetadata.Target
|
||||||
|
{
|
||||||
|
get { return Resources.GetString("Target"); }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
namespace Thermo.Active.Database.Migrations
|
||||||
|
{
|
||||||
|
using System;
|
||||||
|
using System.Data.Entity.Migrations;
|
||||||
|
|
||||||
|
public partial class HistorySheetsCycle : DbMigration
|
||||||
|
{
|
||||||
|
public override void Up()
|
||||||
|
{
|
||||||
|
AddColumn("dbo.HistorySheets", "NumDone", c => c.Short(nullable: false));
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void Down()
|
||||||
|
{
|
||||||
|
DropColumn("dbo.HistorySheets", "NumDone");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
File diff suppressed because one or more lines are too long
+29
@@ -0,0 +1,29 @@
|
|||||||
|
// <auto-generated />
|
||||||
|
namespace Thermo.Active.Database.Migrations
|
||||||
|
{
|
||||||
|
using System.CodeDom.Compiler;
|
||||||
|
using System.Data.Entity.Migrations;
|
||||||
|
using System.Data.Entity.Migrations.Infrastructure;
|
||||||
|
using System.Resources;
|
||||||
|
|
||||||
|
[GeneratedCode("EntityFramework.Migrations", "6.2.0-61023")]
|
||||||
|
public sealed partial class addedTypeValHistory : IMigrationMetadata
|
||||||
|
{
|
||||||
|
private readonly ResourceManager Resources = new ResourceManager(typeof(addedTypeValHistory));
|
||||||
|
|
||||||
|
string IMigrationMetadata.Id
|
||||||
|
{
|
||||||
|
get { return "202103221323362_addedTypeValHistory"; }
|
||||||
|
}
|
||||||
|
|
||||||
|
string IMigrationMetadata.Source
|
||||||
|
{
|
||||||
|
get { return null; }
|
||||||
|
}
|
||||||
|
|
||||||
|
string IMigrationMetadata.Target
|
||||||
|
{
|
||||||
|
get { return Resources.GetString("Target"); }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
namespace Thermo.Active.Database.Migrations
|
||||||
|
{
|
||||||
|
using System;
|
||||||
|
using System.Data.Entity.Migrations;
|
||||||
|
|
||||||
|
public partial class addedTypeValHistory : DbMigration
|
||||||
|
{
|
||||||
|
public override void Up()
|
||||||
|
{
|
||||||
|
AddColumn("dbo.HistorySheets", "TypeVal", c => c.Int(nullable: false));
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void Down()
|
||||||
|
{
|
||||||
|
DropColumn("dbo.HistorySheets", "TypeVal");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
File diff suppressed because one or more lines are too long
@@ -124,6 +124,7 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Compile Include="Controllers\AlarmsController.cs" />
|
<Compile Include="Controllers\AlarmsController.cs" />
|
||||||
<Compile Include="Controllers\FunctionsAccessController.cs" />
|
<Compile Include="Controllers\FunctionsAccessController.cs" />
|
||||||
|
<Compile Include="Controllers\HistorySheetsController.cs" />
|
||||||
<Compile Include="Controllers\ProdInfoController.cs" />
|
<Compile Include="Controllers\ProdInfoController.cs" />
|
||||||
<Compile Include="Controllers\MachinesController.cs" />
|
<Compile Include="Controllers\MachinesController.cs" />
|
||||||
<Compile Include="Controllers\MaintenancesController.cs" />
|
<Compile Include="Controllers\MaintenancesController.cs" />
|
||||||
@@ -158,6 +159,18 @@
|
|||||||
<Compile Include="Migrations\202102171753226_Added_ThermoImage_prodInfo.Designer.cs">
|
<Compile Include="Migrations\202102171753226_Added_ThermoImage_prodInfo.Designer.cs">
|
||||||
<DependentUpon>202102171753226_Added_ThermoImage_prodInfo.cs</DependentUpon>
|
<DependentUpon>202102171753226_Added_ThermoImage_prodInfo.cs</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
<Compile Include="Migrations\202103191608500_HistorySheets.cs" />
|
||||||
|
<Compile Include="Migrations\202103191608500_HistorySheets.Designer.cs">
|
||||||
|
<DependentUpon>202103191608500_HistorySheets.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Migrations\202103191626072_HistorySheetsCycle.cs" />
|
||||||
|
<Compile Include="Migrations\202103191626072_HistorySheetsCycle.Designer.cs">
|
||||||
|
<DependentUpon>202103191626072_HistorySheetsCycle.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Migrations\202103221323362_addedTypeValHistory.cs" />
|
||||||
|
<Compile Include="Migrations\202103221323362_addedTypeValHistory.Designer.cs">
|
||||||
|
<DependentUpon>202103221323362_addedTypeValHistory.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
<Compile Include="Migrations\Configuration.cs" />
|
<Compile Include="Migrations\Configuration.cs" />
|
||||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||||
<Compile Include="Redis\redUtil.cs" />
|
<Compile Include="Redis\redUtil.cs" />
|
||||||
@@ -212,6 +225,15 @@
|
|||||||
<EmbeddedResource Include="Migrations\202102171753226_Added_ThermoImage_prodInfo.resx">
|
<EmbeddedResource Include="Migrations\202102171753226_Added_ThermoImage_prodInfo.resx">
|
||||||
<DependentUpon>202102171753226_Added_ThermoImage_prodInfo.cs</DependentUpon>
|
<DependentUpon>202102171753226_Added_ThermoImage_prodInfo.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="Migrations\202103191608500_HistorySheets.resx">
|
||||||
|
<DependentUpon>202103191608500_HistorySheets.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="Migrations\202103191626072_HistorySheetsCycle.resx">
|
||||||
|
<DependentUpon>202103191626072_HistorySheetsCycle.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="Migrations\202103221323362_addedTypeValHistory.resx">
|
||||||
|
<DependentUpon>202103221323362_addedTypeValHistory.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
</Project>
|
</Project>
|
||||||
@@ -18,5 +18,9 @@ namespace Thermo.Active.Model.ConfigModels
|
|||||||
|
|
||||||
public int MaxAlarmsRows { get; set; }
|
public int MaxAlarmsRows { get; set; }
|
||||||
public int AlarmToDelete { get; set; }
|
public int AlarmToDelete { get; set; }
|
||||||
|
|
||||||
|
|
||||||
|
public int MaxSheetHistoryRows { get; set; }
|
||||||
|
public int SheetHistoryToDelete { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -23,6 +23,7 @@ namespace Thermo.Active.Model
|
|||||||
public const string AXES_CONFIG_PATH = CONFIG_DIRECTORY + "axesConfig.xml";
|
public const string AXES_CONFIG_PATH = CONFIG_DIRECTORY + "axesConfig.xml";
|
||||||
public const string AXES_CONFIG_SCHEMA_PATH = RESOURCE_DIRECTORY + @"axesConfigValidator.xsd";
|
public const string AXES_CONFIG_SCHEMA_PATH = RESOURCE_DIRECTORY + @"axesConfigValidator.xsd";
|
||||||
public const string BROADCAST_DATA = "BROADCAST_DATA";
|
public const string BROADCAST_DATA = "BROADCAST_DATA";
|
||||||
|
public const string TAKE_SNAPSHOT_THERMO = "TAKE_SNAPSHOT_THERMO";
|
||||||
|
|
||||||
// File paths
|
// File paths
|
||||||
public const string CLIENT_EXE_NAME = @"Active_Client.exe";
|
public const string CLIENT_EXE_NAME = @"Active_Client.exe";
|
||||||
@@ -104,6 +105,7 @@ namespace Thermo.Active.Model
|
|||||||
|
|
||||||
public const string SEND_AXIS_INFO = "SEND_AXIS_INFO";
|
public const string SEND_AXIS_INFO = "SEND_AXIS_INFO";
|
||||||
public const string SEND_CHANNELS_IO_DATA = "SEND_CHANNELS_IO_DATA";
|
public const string SEND_CHANNELS_IO_DATA = "SEND_CHANNELS_IO_DATA";
|
||||||
|
public const string SEND_NEWTCAMIMAGE = "SEND_NEWTCAMIMAGE";
|
||||||
public const string SEND_CMSCONNECT_GW_REBOOT_STATUS = "SEND_CMSCONNECT_GW_REBOOT_STATUS";
|
public const string SEND_CMSCONNECT_GW_REBOOT_STATUS = "SEND_CMSCONNECT_GW_REBOOT_STATUS";
|
||||||
public const string SEND_ERROR_TO_UI = "SEND_ERROR_TO_UI";
|
public const string SEND_ERROR_TO_UI = "SEND_ERROR_TO_UI";
|
||||||
public const string SEND_EXPIRED_MAINTENANCES_DATA = "SEND_EXPIRED_MAINTENANCES_DATA";
|
public const string SEND_EXPIRED_MAINTENANCES_DATA = "SEND_EXPIRED_MAINTENANCES_DATA";
|
||||||
|
|||||||
@@ -40,6 +40,11 @@ namespace Thermo.Active.Model.DTOModels.ThWarmers
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public bool ThermoOptionActive { get; set; } = false;
|
public bool ThermoOptionActive { get; set; } = false;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Data ultima acquisizione
|
||||||
|
/// </summary>
|
||||||
|
public DateTime LastTakenImage { get; set; } = new DateTime(0);
|
||||||
|
|
||||||
#endregion Public Properties
|
#endregion Public Properties
|
||||||
|
|
||||||
#region Public Methods
|
#region Public Methods
|
||||||
@@ -64,6 +69,8 @@ namespace Thermo.Active.Model.DTOModels.ThWarmers
|
|||||||
return false;
|
return false;
|
||||||
if (RangeTemperature != item.RangeTemperature)
|
if (RangeTemperature != item.RangeTemperature)
|
||||||
return false;
|
return false;
|
||||||
|
if (LastTakenImage != item.LastTakenImage)
|
||||||
|
return false;
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,38 @@
|
|||||||
|
using System;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
|
|
||||||
|
namespace Thermo.Active.Model.DatabaseModels
|
||||||
|
{
|
||||||
|
[Table("HistorySheets")]
|
||||||
|
public class HistorySheetModel
|
||||||
|
{
|
||||||
|
#region Public Properties
|
||||||
|
|
||||||
|
[Key]
|
||||||
|
[DatabaseGenerated(DatabaseGeneratedOption.None)]
|
||||||
|
[Column("DtEvent", Order = 0)]
|
||||||
|
public DateTime DtEvent { get; set; }
|
||||||
|
|
||||||
|
[Column("Recipe")]
|
||||||
|
public string RecipeName { get; set; }
|
||||||
|
|
||||||
|
[Column("NumDone")]
|
||||||
|
public short NumDone { get; set; }
|
||||||
|
|
||||||
|
[Column("FirstVal")]
|
||||||
|
public float FirstVal { get; set; }
|
||||||
|
|
||||||
|
[Column("SecondVal")]
|
||||||
|
public float SecondVal { get; set; }
|
||||||
|
|
||||||
|
[Column("ThirdVal")]
|
||||||
|
public float ThirdVal { get; set; }
|
||||||
|
|
||||||
|
[Column("TypeVal")]
|
||||||
|
public int TypeVal { get; set; }
|
||||||
|
|
||||||
|
|
||||||
|
#endregion Public Properties
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -85,6 +85,7 @@
|
|||||||
<Compile Include="DatabaseModels\AlarmNoteModel.cs" />
|
<Compile Include="DatabaseModels\AlarmNoteModel.cs" />
|
||||||
<Compile Include="DatabaseModels\AlarmOccurrencesModel.cs" />
|
<Compile Include="DatabaseModels\AlarmOccurrencesModel.cs" />
|
||||||
<Compile Include="DatabaseModels\AlarmUserModel.cs" />
|
<Compile Include="DatabaseModels\AlarmUserModel.cs" />
|
||||||
|
<Compile Include="DatabaseModels\HistorySheetModel.cs" />
|
||||||
<Compile Include="DatabaseModels\FavoriteUserSoftKeyModel.cs" />
|
<Compile Include="DatabaseModels\FavoriteUserSoftKeyModel.cs" />
|
||||||
<Compile Include="DatabaseModels\FunctionAccessModel.cs" />
|
<Compile Include="DatabaseModels\FunctionAccessModel.cs" />
|
||||||
<Compile Include="ConfigModels\MessageModel.cs" />
|
<Compile Include="ConfigModels\MessageModel.cs" />
|
||||||
|
|||||||
@@ -140,6 +140,11 @@ namespace Thermo.Active.NC
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public static bool cameraIsConnected = false;
|
public static bool cameraIsConnected = false;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Indica se la FLIR camera è connessa
|
||||||
|
/// </summary>
|
||||||
|
public static DateTime lastImageTaken = new DateTime(0);
|
||||||
|
|
||||||
#endregion Public Fields
|
#endregion Public Fields
|
||||||
|
|
||||||
#region Public Constructors
|
#region Public Constructors
|
||||||
@@ -470,10 +475,16 @@ namespace Thermo.Active.NC
|
|||||||
// solo x S7...
|
// solo x S7...
|
||||||
if (NcConfig.NcVendor == NC_VENDOR.S7NET)
|
if (NcConfig.NcVendor == NC_VENDOR.S7NET)
|
||||||
{
|
{
|
||||||
|
// registro in redis blocco x lettura ricetta...
|
||||||
|
RedisController.setRecipeReadSem(true);
|
||||||
|
|
||||||
// call NC for update
|
// call NC for update
|
||||||
CmsError libraryError = numericalControl.PLC_WRecipeEdit(confirmUpdate);
|
CmsError libraryError = numericalControl.PLC_WRecipeEdit(confirmUpdate);
|
||||||
if (libraryError.IsError())
|
if (libraryError.IsError())
|
||||||
return libraryError;
|
return libraryError;
|
||||||
|
|
||||||
|
// tolgo blocco x lettura ricetta...
|
||||||
|
RedisController.setRecipeReadSem(false);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -1759,10 +1770,16 @@ namespace Thermo.Active.NC
|
|||||||
{
|
{
|
||||||
if (NcFileAdapter.RecipeLiveData.ChannelSetpoints != null)
|
if (NcFileAdapter.RecipeLiveData.ChannelSetpoints != null)
|
||||||
{
|
{
|
||||||
|
// registro in redis blocco x lettura ricetta...
|
||||||
|
RedisController.setRecipeReadSem(true);
|
||||||
|
|
||||||
// se si in questo caso scrivo configurazione...
|
// se si in questo caso scrivo configurazione...
|
||||||
WriteRecipeWarmConfig();
|
WriteRecipeWarmConfig();
|
||||||
// Ack !
|
// Ack !
|
||||||
libraryError = numericalControl.PLC_WAckConfRiskRequest();
|
libraryError = numericalControl.PLC_WAckConfRiskRequest();
|
||||||
|
|
||||||
|
// tolgo in redis blocco x lettura ricetta...
|
||||||
|
RedisController.setRecipeReadSem(false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (ThermoReqConfRecipeStr)
|
if (ThermoReqConfRecipeStr)
|
||||||
@@ -1790,8 +1807,12 @@ namespace Thermo.Active.NC
|
|||||||
return NOT_FOUND_ERROR;
|
return NOT_FOUND_ERROR;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// registro in redis blocco x lettura ricetta...
|
||||||
|
RedisController.setRecipeReadSem(true);
|
||||||
// se si in questo caso scrivo configurazione attuale...
|
// se si in questo caso scrivo configurazione attuale...
|
||||||
WriteRecipeParams(updtRecipe, nMaxParamWrite, delayParamWrite);
|
WriteRecipeParams(updtRecipe, nMaxParamWrite, delayParamWrite);
|
||||||
|
// tolgo in redis blocco x lettura ricetta...
|
||||||
|
RedisController.setRecipeReadSem(false);
|
||||||
|
|
||||||
using (UserSoftkeysController controller = new UserSoftkeysController())
|
using (UserSoftkeysController controller = new UserSoftkeysController())
|
||||||
{
|
{
|
||||||
@@ -1808,6 +1829,9 @@ namespace Thermo.Active.NC
|
|||||||
newRisk.Add(item.Key, item.Value);
|
newRisk.Add(item.Key, item.Value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// registro in redis blocco x lettura ricetta...
|
||||||
|
RedisController.setRecipeReadSem(true);
|
||||||
|
|
||||||
// write to PLC SetPointHMI (%)
|
// write to PLC SetPointHMI (%)
|
||||||
libraryError = WriteRecipeWarmChSetpHMI(newRisk);
|
libraryError = WriteRecipeWarmChSetpHMI(newRisk);
|
||||||
if (libraryError.IsError())
|
if (libraryError.IsError())
|
||||||
@@ -1822,6 +1846,9 @@ namespace Thermo.Active.NC
|
|||||||
libraryError = ConfirmRecipeData(true);
|
libraryError = ConfirmRecipeData(true);
|
||||||
if (libraryError.IsError())
|
if (libraryError.IsError())
|
||||||
return libraryError;
|
return libraryError;
|
||||||
|
|
||||||
|
// tolgo in redis blocco x lettura ricetta...
|
||||||
|
RedisController.setRecipeReadSem(true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -2515,7 +2542,7 @@ namespace Thermo.Active.NC
|
|||||||
{
|
{
|
||||||
imgName = "UNDEFINED";
|
imgName = "UNDEFINED";
|
||||||
}
|
}
|
||||||
prodInfoController.Create(pInfoRaw.NumTarget, pInfoRaw.NumDone, pInfoRaw.TimeWarm, pInfoRaw.TimeVent, pInfoRaw.TimeVacuum, pInfoRaw.TimeCycleGross, pInfoRaw.TimeCycleNet, pInfoRaw.MaterialTempEndWarm, pInfoRaw.MaterialTempEndVent, pInfoRaw.MoldTemp, pInfoRaw.VacuumReadVal, pInfoRaw.MouldEnergyOUT, pInfoRaw.MouldEnergyIN, false, pInfoRaw.ThermoImage);
|
prodInfoController.Create(pInfoRaw.NumTarget, pInfoRaw.NumDone, pInfoRaw.TimeWarm, pInfoRaw.TimeVent, pInfoRaw.TimeVacuum, pInfoRaw.TimeCycleGross, pInfoRaw.TimeCycleNet, pInfoRaw.MaterialTempEndWarm, pInfoRaw.MaterialTempEndVent, pInfoRaw.MoldTemp, pInfoRaw.VacuumReadVal, pInfoRaw.MouldEnergyOUT, pInfoRaw.MouldEnergyIN, false, imgName);
|
||||||
// indico di rileggere il DB...
|
// indico di rileggere il DB...
|
||||||
forceProdPanelDbReload = true;
|
forceProdPanelDbReload = true;
|
||||||
}
|
}
|
||||||
@@ -2561,6 +2588,26 @@ namespace Thermo.Active.NC
|
|||||||
lastProdStart = DateTime.Now;
|
lastProdStart = DateTime.Now;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
ThermoModels.HistorySheet sheetRaw = new ThermoModels.HistorySheet();
|
||||||
|
libraryError = numericalControl.PLC_RHistorySheets(ref sheetRaw);
|
||||||
|
if (libraryError.IsError())
|
||||||
|
return libraryError;
|
||||||
|
|
||||||
|
if (sheetRaw.newData)
|
||||||
|
{
|
||||||
|
|
||||||
|
using (HistorySheetsController HSC = new HistorySheetsController())
|
||||||
|
{
|
||||||
|
HSC.Create(NcFileAdapter.RecipeLiveData.RecipeName, sheetRaw.IdPiece, (float) sheetRaw.Value1, (float) sheetRaw.Value2, (float) sheetRaw.Value3,sheetRaw.TypeVal);
|
||||||
|
|
||||||
|
// manage strobe/ack!
|
||||||
|
libraryError = numericalControl.PLC_WAckHistorySheets();
|
||||||
|
if (libraryError.IsError())
|
||||||
|
return libraryError;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return libraryError;
|
return libraryError;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3172,6 +3219,9 @@ namespace Thermo.Active.NC
|
|||||||
};
|
};
|
||||||
// controllo se connessa
|
// controllo se connessa
|
||||||
currTCamData.ThermoCamConnected = cameraIsConnected;
|
currTCamData.ThermoCamConnected = cameraIsConnected;
|
||||||
|
|
||||||
|
// DataOra ultima immagine scattata
|
||||||
|
currTCamData.LastTakenImage = lastImageTaken;
|
||||||
}
|
}
|
||||||
return libraryError;
|
return libraryError;
|
||||||
}
|
}
|
||||||
@@ -3393,8 +3443,14 @@ namespace Thermo.Active.NC
|
|||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public CmsError SetTCamActiv(bool enableTCam)
|
public CmsError SetTCamActiv(bool enableTCam)
|
||||||
{
|
{
|
||||||
|
// registro in redis blocco x lettura ricetta...
|
||||||
|
RedisController.setWarmersReadSem(true);
|
||||||
|
|
||||||
CmsError libraryError = numericalControl.PLC_WTCamActiv(enableTCam);
|
CmsError libraryError = numericalControl.PLC_WTCamActiv(enableTCam);
|
||||||
|
|
||||||
|
// tolgo in redis blocco x lettura ricetta...
|
||||||
|
RedisController.setWarmersReadSem(false);
|
||||||
|
|
||||||
return libraryError;
|
return libraryError;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3405,8 +3461,14 @@ namespace Thermo.Active.NC
|
|||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public CmsError SetTCamMode(bool enableTCam)
|
public CmsError SetTCamMode(bool enableTCam)
|
||||||
{
|
{
|
||||||
|
// registro in redis blocco x lettura ricetta...
|
||||||
|
RedisController.setWarmersReadSem(true);
|
||||||
|
|
||||||
CmsError libraryError = numericalControl.PLC_WTCamMode(enableTCam);
|
CmsError libraryError = numericalControl.PLC_WTCamMode(enableTCam);
|
||||||
|
|
||||||
|
// tolgo in redis blocco x lettura ricetta...
|
||||||
|
RedisController.setWarmersReadSem(false);
|
||||||
|
|
||||||
return libraryError;
|
return libraryError;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3641,8 +3703,15 @@ namespace Thermo.Active.NC
|
|||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public CmsError WriteRecipeParams(Dictionary<string, DTORecipeParam> updtRecipe, int nMaxParamWrite, int delayParamWrite)
|
public CmsError WriteRecipeParams(Dictionary<string, DTORecipeParam> updtRecipe, int nMaxParamWrite, int delayParamWrite)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
// registro in redis blocco x lettura ricetta...
|
||||||
|
RedisController.setRecipeReadSem(true);
|
||||||
|
|
||||||
CmsError libraryError = WriteRecipeParametersToPLC(updtRecipe, nMaxParamWrite, delayParamWrite);
|
CmsError libraryError = WriteRecipeParametersToPLC(updtRecipe, nMaxParamWrite, delayParamWrite);
|
||||||
|
|
||||||
|
// tolgo blocco x lettura ricetta...
|
||||||
|
RedisController.setRecipeReadSem(false);
|
||||||
|
|
||||||
return libraryError;
|
return libraryError;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3653,8 +3722,15 @@ namespace Thermo.Active.NC
|
|||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public CmsError WriteRecipeWarmChSetpHMI(Dictionary<int, int> updtSetpHmi)
|
public CmsError WriteRecipeWarmChSetpHMI(Dictionary<int, int> updtSetpHmi)
|
||||||
{
|
{
|
||||||
|
// registro in redis blocco x lettura warmers...
|
||||||
|
RedisController.setWarmersReadSem(true);
|
||||||
|
|
||||||
CmsError libraryError = numericalControl.PLC_WWarmerChSetpHmi(updtSetpHmi);
|
CmsError libraryError = numericalControl.PLC_WWarmerChSetpHmi(updtSetpHmi);
|
||||||
|
|
||||||
|
// tolgo blocco x lettura warmers...
|
||||||
|
RedisController.setWarmersReadSem(false);
|
||||||
|
|
||||||
|
|
||||||
return libraryError;
|
return libraryError;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3665,8 +3741,14 @@ namespace Thermo.Active.NC
|
|||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public CmsError WriteRecipeWarmChTCamEnab(Dictionary<int, bool> actualStates)
|
public CmsError WriteRecipeWarmChTCamEnab(Dictionary<int, bool> actualStates)
|
||||||
{
|
{
|
||||||
|
// registro in redis blocco x lettura warmers...
|
||||||
|
RedisController.setWarmersReadSem(true);
|
||||||
|
|
||||||
CmsError libraryError = numericalControl.PLC_WWarmerChTCamEnab(actualStates);
|
CmsError libraryError = numericalControl.PLC_WWarmerChTCamEnab(actualStates);
|
||||||
|
|
||||||
|
// tolgo blocco x lettura warmers...
|
||||||
|
RedisController.setWarmersReadSem(false);
|
||||||
|
|
||||||
return libraryError;
|
return libraryError;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3677,8 +3759,14 @@ namespace Thermo.Active.NC
|
|||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public CmsError WriteRecipeWarmChTCamTempAct(Dictionary<int, double> actualTemp)
|
public CmsError WriteRecipeWarmChTCamTempAct(Dictionary<int, double> actualTemp)
|
||||||
{
|
{
|
||||||
|
// registro in redis blocco x lettura warmers...
|
||||||
|
RedisController.setWarmersReadSem(true);
|
||||||
|
|
||||||
CmsError libraryError = numericalControl.PLC_WWarmerChTCamTempAct(actualTemp);
|
CmsError libraryError = numericalControl.PLC_WWarmerChTCamTempAct(actualTemp);
|
||||||
|
|
||||||
|
// tolgo blocco x lettura warmers...
|
||||||
|
RedisController.setWarmersReadSem(false);
|
||||||
|
|
||||||
return libraryError;
|
return libraryError;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3689,8 +3777,14 @@ namespace Thermo.Active.NC
|
|||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public CmsError WriteRecipeWarmChTCamTempSet(Dictionary<int, double> referenceTemp)
|
public CmsError WriteRecipeWarmChTCamTempSet(Dictionary<int, double> referenceTemp)
|
||||||
{
|
{
|
||||||
|
// registro in redis blocco x lettura warmers...
|
||||||
|
RedisController.setWarmersReadSem(true);
|
||||||
|
|
||||||
CmsError libraryError = numericalControl.PLC_WWarmerChTCamTempSet(referenceTemp);
|
CmsError libraryError = numericalControl.PLC_WWarmerChTCamTempSet(referenceTemp);
|
||||||
|
|
||||||
|
// tolgo blocco x lettura warmers...
|
||||||
|
RedisController.setWarmersReadSem(false);
|
||||||
|
|
||||||
return libraryError;
|
return libraryError;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3704,6 +3798,9 @@ namespace Thermo.Active.NC
|
|||||||
Dictionary<int, int> newData = new Dictionary<int, int>();
|
Dictionary<int, int> newData = new Dictionary<int, int>();
|
||||||
CmsError libraryError = NO_ERROR;
|
CmsError libraryError = NO_ERROR;
|
||||||
|
|
||||||
|
// registro in redis blocco x lettura warmers...
|
||||||
|
RedisController.setWarmersReadSem(true);
|
||||||
|
|
||||||
// scrivo l'abilitazione dei canali...
|
// scrivo l'abilitazione dei canali...
|
||||||
foreach (var item in RiskBoardConfig)
|
foreach (var item in RiskBoardConfig)
|
||||||
{
|
{
|
||||||
@@ -3765,6 +3862,10 @@ namespace Thermo.Active.NC
|
|||||||
numericalControl.PLC_WWarmerChTCamEnab(resetTCamEnab);
|
numericalControl.PLC_WWarmerChTCamEnab(resetTCamEnab);
|
||||||
numericalControl.PLC_WWarmerChTCamTempAct(resetTCamTemp);
|
numericalControl.PLC_WWarmerChTCamTempAct(resetTCamTemp);
|
||||||
numericalControl.PLC_WWarmerChTCamTempSet(resetTCamTemp);
|
numericalControl.PLC_WWarmerChTCamTempSet(resetTCamTemp);
|
||||||
|
|
||||||
|
// tolgo blocco x lettura warmers...
|
||||||
|
RedisController.setWarmersReadSem(false);
|
||||||
|
|
||||||
// esce
|
// esce
|
||||||
return libraryError;
|
return libraryError;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -38,10 +38,6 @@
|
|||||||
<assemblyIdentity name="System.Runtime.InteropServices.RuntimeInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
<assemblyIdentity name="System.Runtime.InteropServices.RuntimeInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
||||||
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
|
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
|
||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
|
||||||
<assemblyIdentity name="S7.Net" publicKeyToken="d5812d469e84c693" culture="neutral" />
|
|
||||||
<bindingRedirect oldVersion="0.0.0.0-0.8.1.0" newVersion="0.8.1.0" />
|
|
||||||
</dependentAssembly>
|
|
||||||
</assemblyBinding>
|
</assemblyBinding>
|
||||||
</runtime>
|
</runtime>
|
||||||
</configuration>
|
</configuration>
|
||||||
@@ -38,10 +38,6 @@
|
|||||||
<assemblyIdentity name="System.Runtime.InteropServices.RuntimeInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
<assemblyIdentity name="System.Runtime.InteropServices.RuntimeInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
||||||
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
|
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
|
||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
|
||||||
<assemblyIdentity name="S7.Net" publicKeyToken="d5812d469e84c693" culture="neutral" />
|
|
||||||
<bindingRedirect oldVersion="0.0.0.0-0.8.1.0" newVersion="0.8.1.0" />
|
|
||||||
</dependentAssembly>
|
|
||||||
</assemblyBinding>
|
</assemblyBinding>
|
||||||
</runtime>
|
</runtime>
|
||||||
</configuration>
|
</configuration>
|
||||||
@@ -47,6 +47,10 @@ namespace Thermo.Active.Utils
|
|||||||
{
|
{
|
||||||
Log.Info(message);
|
Log.Info(message);
|
||||||
}
|
}
|
||||||
|
public static void LogDebug(string message)
|
||||||
|
{
|
||||||
|
Log.Debug(message);
|
||||||
|
}
|
||||||
|
|
||||||
public static void LogWarning(string message)
|
public static void LogWarning(string message)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -430,4 +430,6 @@
|
|||||||
<axis_info_position>In posizione:</axis_info_position>
|
<axis_info_position>In posizione:</axis_info_position>
|
||||||
<axis_info_error>In errore:</axis_info_error>
|
<axis_info_error>In errore:</axis_info_error>
|
||||||
<axis_info_brakealm>Allarme test freno:</axis_info_brakealm>
|
<axis_info_brakealm>Allarme test freno:</axis_info_brakealm>
|
||||||
|
<bitselect_select_none>Nessuno</bitselect_select_none>
|
||||||
|
<bitselect_select_all>Tutti</bitselect_select_all>
|
||||||
</root>
|
</root>
|
||||||
@@ -430,4 +430,6 @@
|
|||||||
<axis_info_position>In Position:</axis_info_position>
|
<axis_info_position>In Position:</axis_info_position>
|
||||||
<axis_info_error>In Error:</axis_info_error>
|
<axis_info_error>In Error:</axis_info_error>
|
||||||
<axis_info_brakealm>Brake Test Alarm:</axis_info_brakealm>
|
<axis_info_brakealm>Brake Test Alarm:</axis_info_brakealm>
|
||||||
|
<bitselect_select_none>None</bitselect_select_none>
|
||||||
|
<bitselect_select_all>All</bitselect_select_all>
|
||||||
</root>
|
</root>
|
||||||
@@ -15,7 +15,7 @@
|
|||||||
<add key="ClientSettingsProvider.ServiceUri" value="" />
|
<add key="ClientSettingsProvider.ServiceUri" value="" />
|
||||||
<add key="ServerServiceName" value="MariaDB" />
|
<add key="ServerServiceName" value="MariaDB" />
|
||||||
<add key="nMaxParamWrite" value="5" />
|
<add key="nMaxParamWrite" value="5" />
|
||||||
<add key="delayParamWrite" value="5" />
|
<add key="delayParamWrite" value="10" />
|
||||||
<add key="ewmaPar100" value="40" />
|
<add key="ewmaPar100" value="40" />
|
||||||
<add key="flirSwapXY" value="true" />
|
<add key="flirSwapXY" value="true" />
|
||||||
<add key="cacheWarmers" value="false" />
|
<add key="cacheWarmers" value="false" />
|
||||||
@@ -115,10 +115,6 @@
|
|||||||
<assemblyIdentity name="System.Runtime.InteropServices.RuntimeInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
<assemblyIdentity name="System.Runtime.InteropServices.RuntimeInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
||||||
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
|
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
|
||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
|
||||||
<assemblyIdentity name="S7.Net" publicKeyToken="d5812d469e84c693" culture="neutral" />
|
|
||||||
<bindingRedirect oldVersion="0.0.0.0-0.8.1.0" newVersion="0.8.1.0" />
|
|
||||||
</dependentAssembly>
|
|
||||||
</assemblyBinding>
|
</assemblyBinding>
|
||||||
</runtime>
|
</runtime>
|
||||||
<connectionStrings>
|
<connectionStrings>
|
||||||
|
|||||||
@@ -8,6 +8,7 @@ using System.Security.Principal;
|
|||||||
using Thermo.Active.Config;
|
using Thermo.Active.Config;
|
||||||
using Thermo.Active.Database.Controllers;
|
using Thermo.Active.Database.Controllers;
|
||||||
using Thermo.Active.Model.DatabaseModels;
|
using Thermo.Active.Model.DatabaseModels;
|
||||||
|
using Thermo.Active.Utils;
|
||||||
using static Thermo.Active.Config.ServerConfig;
|
using static Thermo.Active.Config.ServerConfig;
|
||||||
using static Thermo.Active.Listeners.SignalRStaticObjects;
|
using static Thermo.Active.Listeners.SignalRStaticObjects;
|
||||||
using static Thermo.Active.Model.Constants;
|
using static Thermo.Active.Model.Constants;
|
||||||
@@ -28,7 +29,11 @@ namespace Thermo.Active.Attributes
|
|||||||
// Find user session on this machine
|
// Find user session on this machine
|
||||||
SessionModel session = sessionsController.FindSessionByToken(token);
|
SessionModel session = sessionsController.FindSessionByToken(token);
|
||||||
if (session == null)
|
if (session == null)
|
||||||
|
{
|
||||||
|
ThermoActiveLogger.LogError($"SignalRAuthorizeAttribute | AuthorizeHubConnection | session == null");
|
||||||
return false;
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return base.AuthorizeHubConnection(hubDescriptor, request);
|
return base.AuthorizeHubConnection(hubDescriptor, request);
|
||||||
@@ -39,11 +44,16 @@ namespace Thermo.Active.Attributes
|
|||||||
var connectionId = hubIncomingInvokerContext.Hub.Context.ConnectionId;
|
var connectionId = hubIncomingInvokerContext.Hub.Context.ConnectionId;
|
||||||
var request = hubIncomingInvokerContext.Hub.Context.Request;
|
var request = hubIncomingInvokerContext.Hub.Context.Request;
|
||||||
var token = request.QueryString.Get("Authorization");
|
var token = request.QueryString.Get("Authorization");
|
||||||
|
|
||||||
if (!string.IsNullOrEmpty(token))
|
if (!string.IsNullOrEmpty(token))
|
||||||
{
|
{
|
||||||
// check authorization
|
// check authorization
|
||||||
if (!CheckAuthorization(FunctionAccess, token, out int machineId, out int userId))
|
if (!CheckAuthorization(FunctionAccess, token, out int machineId, out int userId))
|
||||||
|
{
|
||||||
|
ThermoActiveLogger.LogError($"SignalRAuthorizeAttribute | AuthorizeHubMethodInvocation | CheckAuthorization == false");
|
||||||
return false;
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
var claims = new ClaimsIdentity(AUTHENTICATION_TYPE);
|
var claims = new ClaimsIdentity(AUTHENTICATION_TYPE);
|
||||||
claims.AddClaim(new Claim(USER_ID_KEY, userId.ToString()));
|
claims.AddClaim(new Claim(USER_ID_KEY, userId.ToString()));
|
||||||
@@ -66,11 +76,17 @@ namespace Thermo.Active.Attributes
|
|||||||
// Find user session on this machine
|
// Find user session on this machine
|
||||||
SessionModel session = sessionsController.FindSessionByToken(token);
|
SessionModel session = sessionsController.FindSessionByToken(token);
|
||||||
if (session == null)
|
if (session == null)
|
||||||
|
{
|
||||||
|
ThermoActiveLogger.LogError($"SignalRAuthorizeAttribute | CheckAuthorization | session == null");
|
||||||
return false;
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
// Check if the machine is the same where the user logged in
|
// Check if the machine is the same where the user logged in
|
||||||
if (session.MachineUser.MachineId != MachineConfig.MachineId)
|
if (session.MachineUser.MachineId != MachineConfig.MachineId)
|
||||||
|
{
|
||||||
|
ThermoActiveLogger.LogError($"SignalRAuthorizeAttribute | CheckAuthorization | session.MachineUser.MachineId != MachineConfig.MachineId | " + session.MachineUser.MachineId + "," + MachineConfig.MachineId);
|
||||||
return false;
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
machineId = session.MachineUser.MachineId;
|
machineId = session.MachineUser.MachineId;
|
||||||
userId = session.MachineUser.UserId;
|
userId = session.MachineUser.UserId;
|
||||||
@@ -91,12 +107,18 @@ namespace Thermo.Active.Attributes
|
|||||||
if (Action == ACTIONS.READ)
|
if (Action == ACTIONS.READ)
|
||||||
{ // Check read permissions
|
{ // Check read permissions
|
||||||
if (functionAccess.ReadLevelMin > machineUser.Role.Level)
|
if (functionAccess.ReadLevelMin > machineUser.Role.Level)
|
||||||
|
{
|
||||||
|
ThermoActiveLogger.LogError($"SignalRAuthorizeAttribute | CheckAuthorization | functionAccess.ReadLevelMin > machineUser.Role.Level | " + functionAccess.ReadLevelMin + "," + machineUser.Role.Level);
|
||||||
return false; // Not authorized
|
return false; // Not authorized
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{ // Check write permissions
|
{ // Check write permissions
|
||||||
if (functionAccess.WriteLevelMin > machineUser.Role.Level)
|
if (functionAccess.WriteLevelMin > machineUser.Role.Level)
|
||||||
|
{
|
||||||
|
ThermoActiveLogger.LogError($"SignalRAuthorizeAttribute | CheckAuthorization | functionAccess.WriteLevelMin > machineUser.Role.Level | " + functionAccess.WriteLevelMin + "," + machineUser.Role.Level);
|
||||||
return false; // Not authorized
|
return false; // Not authorized
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check if PLC bit exists
|
// Check if PLC bit exists
|
||||||
@@ -105,13 +127,21 @@ namespace Thermo.Active.Attributes
|
|||||||
// Check if functionality is enabled by PLC
|
// Check if functionality is enabled by PLC
|
||||||
var functionalityIsEnabled = LastRuntimeFunctionality.Where(x => x.Name == functionName).FirstOrDefault();
|
var functionalityIsEnabled = LastRuntimeFunctionality.Where(x => x.Name == functionName).FirstOrDefault();
|
||||||
if (functionalityIsEnabled == null || functionalityIsEnabled.Enabled == false)
|
if (functionalityIsEnabled == null || functionalityIsEnabled.Enabled == false)
|
||||||
return false;
|
{
|
||||||
|
ThermoActiveLogger.LogError($"SignalRAuthorizeAttribute | CheckAuthorization | functionalityIsEnabled == null || functionalityIsEnabled.Enabled == false | " + functionalityIsEnabled + "," + functionalityIsEnabled.Enabled);
|
||||||
|
return false; // Not authorized
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
{
|
||||||
|
ThermoActiveLogger.LogError($"SignalRAuthorizeAttribute | CheckAuthorization | functionAccess != null && ServerConfigController.CheckAreaStatus(functionAccess.Area) | " + functionAccess + "," + functionAccess.Area);
|
||||||
return false;
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
// Authorized
|
// Authorized
|
||||||
|
ThermoActiveLogger.LogInfo($"SignalRAuthorizeAttribute | CheckAuthorization | Authorized | ");
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,12 +22,14 @@ using static Thermo.Active.Model.Constants;
|
|||||||
namespace Thermo.Active.Controllers.WebApi
|
namespace Thermo.Active.Controllers.WebApi
|
||||||
{
|
{
|
||||||
[RoutePrefix("api/maintenance_manager")]
|
[RoutePrefix("api/maintenance_manager")]
|
||||||
public class ApiMaintenanceController : ApiController
|
public class ApiMaintenanceController : aBaseApiController // ApiController
|
||||||
{
|
{
|
||||||
|
#if false
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Oggetto adapter condiviso da WebAPI
|
/// Oggetto adapter condiviso da WebAPI
|
||||||
/// </summary>
|
/// </summary>
|
||||||
protected static NcAdapter ncAdapter = new NcAdapter();
|
protected static NcAdapter ncAdapter = new NcAdapter();
|
||||||
|
#endif
|
||||||
|
|
||||||
[Route("maintenances"), HttpGet]
|
[Route("maintenances"), HttpGet]
|
||||||
[WebApiAuthorize(FunctionAccess = FUNCTIONALITY_NAMES.MAINTENANCE, Action = ACTIONS.READ)]
|
[WebApiAuthorize(FunctionAccess = FUNCTIONALITY_NAMES.MAINTENANCE, Action = ACTIONS.READ)]
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ using static Thermo.Active.Model.Constants;
|
|||||||
namespace Thermo.Active.Controllers.WebApi
|
namespace Thermo.Active.Controllers.WebApi
|
||||||
{
|
{
|
||||||
[RoutePrefix("api/authorization")]
|
[RoutePrefix("api/authorization")]
|
||||||
public class AuthorizationController : ApiController
|
public class AuthorizationController : ApiController
|
||||||
{
|
{
|
||||||
[Route("functions"), HttpGet]
|
[Route("functions"), HttpGet]
|
||||||
[WebApiAuthorize(FunctionAccess = FUNCTIONALITY_NAMES.GENERAL, Action = ACTIONS.READ)]
|
[WebApiAuthorize(FunctionAccess = FUNCTIONALITY_NAMES.GENERAL, Action = ACTIONS.READ)]
|
||||||
|
|||||||
@@ -13,12 +13,14 @@ using static Thermo.Active.Model.Constants;
|
|||||||
namespace Thermo.Active.Controllers.WebApi
|
namespace Thermo.Active.Controllers.WebApi
|
||||||
{
|
{
|
||||||
[RoutePrefix("api/user_softkey")]
|
[RoutePrefix("api/user_softkey")]
|
||||||
public class FavoriteUserSoftkeyController : ApiController
|
public class FavoriteUserSoftkeyController : aBaseApiController // ApiController
|
||||||
{
|
{
|
||||||
|
#if false
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Oggetto adapter condiviso da WebAPI
|
/// Oggetto adapter condiviso da WebAPI
|
||||||
/// </summary>
|
/// </summary>
|
||||||
protected static NcAdapter ncAdapter = new NcAdapter();
|
protected static NcAdapter ncAdapter = new NcAdapter();
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
[Route("favorite"), HttpGet]
|
[Route("favorite"), HttpGet]
|
||||||
|
|||||||
@@ -12,12 +12,14 @@ using static Thermo.Active.Utils.LanguageController;
|
|||||||
namespace Thermo.Active.Controllers.WebApi
|
namespace Thermo.Active.Controllers.WebApi
|
||||||
{
|
{
|
||||||
[RoutePrefix("api/language")]
|
[RoutePrefix("api/language")]
|
||||||
public class LanguageController : ApiController
|
public class LanguageController : aBaseApiController // ApiController
|
||||||
{
|
{
|
||||||
|
#if false
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Oggetto adapter condiviso da WebAPI
|
/// Oggetto adapter condiviso da WebAPI
|
||||||
/// </summary>
|
/// </summary>
|
||||||
protected static NcAdapter ncAdapter = new NcAdapter();
|
protected static NcAdapter ncAdapter = new NcAdapter();
|
||||||
|
#endif
|
||||||
|
|
||||||
[Route("languages"), HttpGet]
|
[Route("languages"), HttpGet]
|
||||||
public IHttpActionResult GetLanguageList()
|
public IHttpActionResult GetLanguageList()
|
||||||
|
|||||||
@@ -8,12 +8,14 @@ using Thermo.Active.Utils;
|
|||||||
namespace Thermo.Active.Controllers.WebApi
|
namespace Thermo.Active.Controllers.WebApi
|
||||||
{
|
{
|
||||||
[RoutePrefix("api/ModBlock")]
|
[RoutePrefix("api/ModBlock")]
|
||||||
public class ModulesController : ApiController
|
public class ModulesController : aBaseApiController // ApiController
|
||||||
{
|
{
|
||||||
|
#if false
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Oggetto adapter condiviso da WebAPI
|
/// Oggetto adapter condiviso da WebAPI
|
||||||
/// </summary>
|
/// </summary>
|
||||||
protected static NcAdapter ncAdapter = new NcAdapter();
|
protected static NcAdapter ncAdapter = new NcAdapter();
|
||||||
|
#endif
|
||||||
|
|
||||||
[Route("current"), HttpGet]
|
[Route("current"), HttpGet]
|
||||||
public IHttpActionResult GetCurrentModules()
|
public IHttpActionResult GetCurrentModules()
|
||||||
|
|||||||
@@ -8,13 +8,15 @@ using static Thermo.Active.Model.Constants;
|
|||||||
namespace Thermo.Active.Controllers.WebApi
|
namespace Thermo.Active.Controllers.WebApi
|
||||||
{
|
{
|
||||||
[RoutePrefix("api/nc")]
|
[RoutePrefix("api/nc")]
|
||||||
public class NcApiController : ApiController
|
public class NcApiController : aBaseApiController // ApiController
|
||||||
{
|
{
|
||||||
|
#if false
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Oggetto adapter condiviso da WebAPI
|
/// Oggetto adapter condiviso da WebAPI
|
||||||
/// </summary>
|
/// </summary>
|
||||||
protected static NcAdapter ncAdapter = new NcAdapter();
|
protected static NcAdapter ncAdapter = new NcAdapter();
|
||||||
|
|
||||||
|
#endif
|
||||||
[Route("generic_data"), HttpGet]
|
[Route("generic_data"), HttpGet]
|
||||||
[WebApiAuthorize(FunctionAccess = FUNCTIONALITY_NAMES.NC_DATA, Action = ACTIONS.READ)]
|
[WebApiAuthorize(FunctionAccess = FUNCTIONALITY_NAMES.NC_DATA, Action = ACTIONS.READ)]
|
||||||
public IHttpActionResult GetNcGenericData()
|
public IHttpActionResult GetNcGenericData()
|
||||||
|
|||||||
@@ -11,13 +11,16 @@ using static Thermo.Active.Model.Constants;
|
|||||||
namespace Thermo.Active.Controllers.WebApi
|
namespace Thermo.Active.Controllers.WebApi
|
||||||
{
|
{
|
||||||
[RoutePrefix("api/prod")]
|
[RoutePrefix("api/prod")]
|
||||||
public class ProdController : ApiController
|
public class ProdController : aBaseApiController //ApiController
|
||||||
{
|
{
|
||||||
|
#if false
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Oggetto adapter condiviso da WebAPI
|
/// Oggetto adapter condiviso da WebAPI
|
||||||
/// </summary>
|
/// </summary>
|
||||||
protected static NcAdapter ncAdapter = new NcAdapter();
|
protected static NcAdapter ncAdapter = new NcAdapter();
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Request mode SETUP
|
/// Request mode SETUP
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -26,12 +26,14 @@ using static Thermo.Active.Model.Constants;
|
|||||||
namespace Thermo.Active.Controllers.WebApi
|
namespace Thermo.Active.Controllers.WebApi
|
||||||
{
|
{
|
||||||
[RoutePrefix("api/recipe")]
|
[RoutePrefix("api/recipe")]
|
||||||
public class RecipeController : ApiController
|
public class RecipeController : aBaseApiController // ApiController
|
||||||
{
|
{
|
||||||
|
#if false
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Oggetto adapter condiviso da WebAPI
|
/// Oggetto adapter condiviso da WebAPI
|
||||||
/// </summary>
|
/// </summary>
|
||||||
protected static NcAdapter ncAdapter = new NcAdapter();
|
protected static NcAdapter ncAdapter = new NcAdapter();
|
||||||
|
#endif
|
||||||
|
|
||||||
[Route("overview"), HttpGet]
|
[Route("overview"), HttpGet]
|
||||||
public IHttpActionResult GetOverview()
|
public IHttpActionResult GetOverview()
|
||||||
@@ -699,6 +701,7 @@ namespace Thermo.Active.Controllers.WebApi
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// copy data to PLC
|
// copy data to PLC
|
||||||
checkError = ncAdapter.ReadFullRecipe(out Dictionary<string, DTORecipeParam> prevRecipe);
|
checkError = ncAdapter.ReadFullRecipe(out Dictionary<string, DTORecipeParam> prevRecipe);
|
||||||
if (checkError.IsError())
|
if (checkError.IsError())
|
||||||
|
|||||||
@@ -13,12 +13,14 @@ namespace Thermo.Active.Controllers.WebApi
|
|||||||
{
|
{
|
||||||
|
|
||||||
[RoutePrefix("api/scada")]
|
[RoutePrefix("api/scada")]
|
||||||
public class ScadaController : ApiController
|
public class ScadaController : aBaseApiController // ApiController
|
||||||
{
|
{
|
||||||
|
#if false
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Oggetto adapter condiviso da WebAPI
|
/// Oggetto adapter condiviso da WebAPI
|
||||||
/// </summary>
|
/// </summary>
|
||||||
protected static NcAdapter ncAdapter = new NcAdapter();
|
protected static NcAdapter ncAdapter = new NcAdapter();
|
||||||
|
#endif
|
||||||
|
|
||||||
[Route("list"), HttpGet]
|
[Route("list"), HttpGet]
|
||||||
public IHttpActionResult GetScadaList()
|
public IHttpActionResult GetScadaList()
|
||||||
|
|||||||
@@ -8,12 +8,14 @@ using Thermo.Active.Utils;
|
|||||||
namespace Thermo.Active.Controllers.WebApi
|
namespace Thermo.Active.Controllers.WebApi
|
||||||
{
|
{
|
||||||
[RoutePrefix("api/starred_softkey")]
|
[RoutePrefix("api/starred_softkey")]
|
||||||
public class StarredUserSoftKeyController : ApiController
|
public class StarredUserSoftKeyController : aBaseApiController // ApiController
|
||||||
{
|
{
|
||||||
|
#if false
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Oggetto adapter condiviso da WebAPI
|
/// Oggetto adapter condiviso da WebAPI
|
||||||
/// </summary>
|
/// </summary>
|
||||||
protected static NcAdapter ncAdapter = new NcAdapter();
|
protected static NcAdapter ncAdapter = new NcAdapter();
|
||||||
|
#endif
|
||||||
|
|
||||||
[Route("get"), HttpGet]
|
[Route("get"), HttpGet]
|
||||||
public IHttpActionResult GetStarredUserSoftkey()
|
public IHttpActionResult GetStarredUserSoftkey()
|
||||||
|
|||||||
@@ -15,6 +15,7 @@ using System.Windows.Media.Animation;
|
|||||||
using TeamDev.SDK.MVVM;
|
using TeamDev.SDK.MVVM;
|
||||||
using Thermo.Active.Config;
|
using Thermo.Active.Config;
|
||||||
using Thermo.Active.Database.Controllers;
|
using Thermo.Active.Database.Controllers;
|
||||||
|
using Thermo.Active.Model.DatabaseModels;
|
||||||
using Thermo.Active.Model.DTOModels;
|
using Thermo.Active.Model.DTOModels;
|
||||||
using Thermo.Active.Model.DTOModels.ThIO;
|
using Thermo.Active.Model.DTOModels.ThIO;
|
||||||
using Thermo.Active.Model.DTOModels.ThRecipe;
|
using Thermo.Active.Model.DTOModels.ThRecipe;
|
||||||
@@ -28,12 +29,15 @@ using static Thermo.Active.Model.Constants;
|
|||||||
namespace Thermo.Active.Controllers.WebApi
|
namespace Thermo.Active.Controllers.WebApi
|
||||||
{
|
{
|
||||||
[RoutePrefix("api/underthehood")]
|
[RoutePrefix("api/underthehood")]
|
||||||
public class UnderTheHoodController : ApiController
|
public class UnderTheHoodController : aBaseApiController // ApiController
|
||||||
{
|
{
|
||||||
|
#if false
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Oggetto adapter condiviso da WebAPI
|
/// Oggetto adapter condiviso da WebAPI
|
||||||
/// </summary>
|
/// </summary>
|
||||||
protected static NcAdapter ncAdapter = new NcAdapter();
|
protected static NcAdapter ncAdapter = new NcAdapter();
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
[ResponseType(typeof(DTOCycleLog))]
|
[ResponseType(typeof(DTOCycleLog))]
|
||||||
[Route("CycleLogRefresh"), HttpGet]
|
[Route("CycleLogRefresh"), HttpGet]
|
||||||
@@ -364,5 +368,41 @@ namespace Thermo.Active.Controllers.WebApi
|
|||||||
// ritorno solo fatto!
|
// ritorno solo fatto!
|
||||||
return Ok(expires);
|
return Ok(expires);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
[ResponseType(typeof(List<HistorySheetModel>))]
|
||||||
|
[Route("SheetHistory"), HttpGet]
|
||||||
|
public IHttpActionResult GetSheetHistory()
|
||||||
|
{
|
||||||
|
using (HistorySheetsController hsc = new HistorySheetsController())
|
||||||
|
{
|
||||||
|
List<HistorySheetModel> models = hsc.GetData();
|
||||||
|
return Ok(models);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
[ResponseType(typeof(List<HistorySheetModel>))]
|
||||||
|
[Route("SheetHistoryFiltered"), HttpGet]
|
||||||
|
public IHttpActionResult GetSheetHistoryFiltered(int start, int number)
|
||||||
|
{
|
||||||
|
using (HistorySheetsController hsc = new HistorySheetsController())
|
||||||
|
{
|
||||||
|
|
||||||
|
List<HistorySheetModel> models = hsc.GetData(start, number);
|
||||||
|
return Ok(models);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
[ResponseType(typeof(int))]
|
||||||
|
[Route("SheetHistoryCount"), HttpGet]
|
||||||
|
public IHttpActionResult GetSheetHistoryCount()
|
||||||
|
{
|
||||||
|
using (HistorySheetsController hsc = new HistorySheetsController())
|
||||||
|
{
|
||||||
|
return Ok(hsc.count());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -18,14 +18,16 @@ using System.Linq;
|
|||||||
namespace Thermo.Active.Controllers.WebApi
|
namespace Thermo.Active.Controllers.WebApi
|
||||||
{
|
{
|
||||||
[RoutePrefix("api/warmers")]
|
[RoutePrefix("api/warmers")]
|
||||||
public class WarmersController : ApiController
|
public class WarmersController : aBaseApiController // ApiController
|
||||||
{
|
{
|
||||||
#region Protected Fields
|
#region Protected Fields
|
||||||
|
|
||||||
|
#if false
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Oggetto adapter condiviso da WebAPI
|
/// Oggetto adapter condiviso da WebAPI
|
||||||
/// </summary>
|
/// </summary>
|
||||||
protected static NcAdapter ncAdapter = new NcAdapter();
|
protected static NcAdapter ncAdapter = new NcAdapter();
|
||||||
|
#endif
|
||||||
|
|
||||||
protected static Dictionary<int, ThermoPoint> MeasurePoints = new Dictionary<int, ThermoPoint>();
|
protected static Dictionary<int, ThermoPoint> MeasurePoints = new Dictionary<int, ThermoPoint>();
|
||||||
|
|
||||||
@@ -590,6 +592,19 @@ namespace Thermo.Active.Controllers.WebApi
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///Take photo Thermocam
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="channelsTemp"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
[Route("takeTcamImage"), HttpPut]
|
||||||
|
[WebApiAuthorize(FunctionAccess = FUNCTIONALITY_NAMES.RECIPE_MANAGER, Action = ACTIONS.READ)]
|
||||||
|
public IHttpActionResult TakeTcamImage()
|
||||||
|
{
|
||||||
|
MessageServices.Current.Publish(TAKE_SNAPSHOT_THERMO);
|
||||||
|
return Ok();
|
||||||
|
}
|
||||||
|
|
||||||
#endregion Public Methods
|
#endregion Public Methods
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,33 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Web.Http;
|
||||||
|
using Thermo.Active.NC;
|
||||||
|
|
||||||
|
namespace Thermo.Active.Controllers.WebApi
|
||||||
|
{
|
||||||
|
public class aBaseApiController : ApiController
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Oggetto adapter condiviso da WebAPI
|
||||||
|
/// </summary>
|
||||||
|
protected static NcAdapter ncAdapter = new NcAdapter();
|
||||||
|
|
||||||
|
#if false
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing)
|
||||||
|
{
|
||||||
|
if (ncAdapter != null)
|
||||||
|
{
|
||||||
|
ncAdapter.Dispose();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -50,7 +50,13 @@ namespace Thermo.Active.Listeners.Database
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
public static void cleanHistorySheets()
|
||||||
|
{
|
||||||
|
using (HistorySheetsController HSC = new HistorySheetsController())
|
||||||
|
{
|
||||||
|
HSC.Clean();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public static void UpdateAlarms(object alarmsObj)
|
public static void UpdateAlarms(object alarmsObj)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -68,6 +68,10 @@ namespace Thermo.Active.Listeners
|
|||||||
{
|
{
|
||||||
SignalRListener.SendThermoChannelsIoData(a);
|
SignalRListener.SendThermoChannelsIoData(a);
|
||||||
}));
|
}));
|
||||||
|
infos.Add(MessageServices.Current.Subscribe(SEND_NEWTCAMIMAGE, (a, b) =>
|
||||||
|
{
|
||||||
|
SignalRListener.SendTCamNewImage(a);
|
||||||
|
}));
|
||||||
infos.Add(MessageServices.Current.Subscribe(SEND_ACTIVE_PROGRAM_DATA, (a, b) =>
|
infos.Add(MessageServices.Current.Subscribe(SEND_ACTIVE_PROGRAM_DATA, (a, b) =>
|
||||||
{
|
{
|
||||||
SignalRListener.SendActiveProgramData(a);
|
SignalRListener.SendActiveProgramData(a);
|
||||||
@@ -130,6 +134,7 @@ namespace Thermo.Active.Listeners
|
|||||||
}));
|
}));
|
||||||
infos.Add(MessageServices.Current.Subscribe(SEND_THERMO_PROD_INFO_DATA, (a, b) =>
|
infos.Add(MessageServices.Current.Subscribe(SEND_THERMO_PROD_INFO_DATA, (a, b) =>
|
||||||
{
|
{
|
||||||
|
SignalRDatabaseHandler.cleanHistorySheets();
|
||||||
SignalRListener.SendThermoProdInfoData(a);
|
SignalRListener.SendThermoProdInfoData(a);
|
||||||
}));
|
}));
|
||||||
infos.Add(MessageServices.Current.Subscribe(SEND_THERMO_PROD_CYCLE_DATA, (a, b) =>
|
infos.Add(MessageServices.Current.Subscribe(SEND_THERMO_PROD_CYCLE_DATA, (a, b) =>
|
||||||
|
|||||||
@@ -326,6 +326,10 @@ namespace Thermo.Active.Listeners.SignalR
|
|||||||
lastSetpointHmiInvalid = currMessage;
|
lastSetpointHmiInvalid = currMessage;
|
||||||
var context = GlobalHost.ConnectionManager.GetHubContext<NcHub>();
|
var context = GlobalHost.ConnectionManager.GetHubContext<NcHub>();
|
||||||
context.Clients.Group("ncData").setpointHmiInvalid(currMessage);
|
context.Clients.Group("ncData").setpointHmiInvalid(currMessage);
|
||||||
|
|
||||||
|
context.Clients.Group("ncData").recipeFullDataInvalidSetpoint(LastRecipeFullData);
|
||||||
|
context.Clients.Group("ncData").warmersData(LastWarmersData);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -611,6 +615,13 @@ namespace Thermo.Active.Listeners.SignalR
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static void SendTCamNewImage(object newImageDate)
|
||||||
|
{
|
||||||
|
DateTime imageDate = (DateTime)newImageDate;
|
||||||
|
var context = GlobalHost.ConnectionManager.GetHubContext<NcHub>();
|
||||||
|
context.Clients.Group("ncData").newThermoCamImage(newImageDate);
|
||||||
|
}
|
||||||
|
|
||||||
public static void SetGatewayRebootStatus(object status)
|
public static void SetGatewayRebootStatus(object status)
|
||||||
{
|
{
|
||||||
string msg = status.ToString();
|
string msg = status.ToString();
|
||||||
@@ -679,7 +690,7 @@ namespace Thermo.Active.Listeners.SignalR
|
|||||||
// Send THERMO Recipe data
|
// Send THERMO Recipe data
|
||||||
group.recipeFullData(LastRecipeFullData);
|
group.recipeFullData(LastRecipeFullData);
|
||||||
group.recipeOverData(LastRecipeOverData);
|
group.recipeOverData(LastRecipeOverData);
|
||||||
group.setpointHmiInvalid();
|
|
||||||
// Send THERMO Modules data
|
// Send THERMO Modules data
|
||||||
group.modulesData(LastModulesData);
|
group.modulesData(LastModulesData);
|
||||||
// Send THERMO Warmers data
|
// Send THERMO Warmers data
|
||||||
@@ -689,6 +700,8 @@ namespace Thermo.Active.Listeners.SignalR
|
|||||||
group.gaugeData(LastLiveProdData);
|
group.gaugeData(LastLiveProdData);
|
||||||
// THERMO prod info data
|
// THERMO prod info data
|
||||||
group.prodInfoData(LastProdInfoData);
|
group.prodInfoData(LastProdInfoData);
|
||||||
|
|
||||||
|
group.prodPanelData(LastProdPanelData);
|
||||||
// THERMO prod cycle data
|
// THERMO prod cycle data
|
||||||
group.prodCycleData(LastProdCycleData);
|
group.prodCycleData(LastProdCycleData);
|
||||||
|
|
||||||
|
|||||||
@@ -30,4 +30,4 @@ using System.Runtime.InteropServices;
|
|||||||
//
|
//
|
||||||
// You can specify all the values or you can default the Revision and Build Numbers
|
// You can specify all the values or you can default the Revision and Build Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
[assembly: AssemblyVersion("1.1.184")]
|
[assembly: AssemblyVersion("1.1.192")]
|
||||||
|
|||||||
@@ -222,6 +222,7 @@
|
|||||||
<Compile Include="Attributes\WebApiAuthorizeAttribute.cs" />
|
<Compile Include="Attributes\WebApiAuthorizeAttribute.cs" />
|
||||||
<Compile Include="Attributes\SignalRAuthorizeAttribute.cs" />
|
<Compile Include="Attributes\SignalRAuthorizeAttribute.cs" />
|
||||||
<Compile Include="Controllers\SignalR\NcHub.cs" />
|
<Compile Include="Controllers\SignalR\NcHub.cs" />
|
||||||
|
<Compile Include="Controllers\WebApi\aBaseApiController.cs" />
|
||||||
<Compile Include="Controllers\WebApi\ApiAlarmController.cs" />
|
<Compile Include="Controllers\WebApi\ApiAlarmController.cs" />
|
||||||
<Compile Include="Controllers\WebApi\UnderTheHoodController.cs" />
|
<Compile Include="Controllers\WebApi\UnderTheHoodController.cs" />
|
||||||
<Compile Include="Controllers\WebApi\SchedTaskController.cs" />
|
<Compile Include="Controllers\WebApi\SchedTaskController.cs" />
|
||||||
|
|||||||
@@ -119,6 +119,9 @@ namespace Thermo.Active
|
|||||||
ListenersHandler.Stop();
|
ListenersHandler.Stop();
|
||||||
// Close WinForm
|
// Close WinForm
|
||||||
ServerControlWindow.Stop();
|
ServerControlWindow.Stop();
|
||||||
|
|
||||||
|
// force close
|
||||||
|
Environment.Exit(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
private static bool ValidateAddress(string Addr)
|
private static bool ValidateAddress(string Addr)
|
||||||
|
|||||||
Binary file not shown.
|
After Width: | Height: | Size: 14 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 16 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 16 KiB |
@@ -2092,7 +2092,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.body {
|
.body {
|
||||||
height: calc(~"100%"- 64px);
|
height: calc(~"100%" - 64px);
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
@@ -3476,7 +3476,6 @@
|
|||||||
position: absolute;
|
position: absolute;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
background: #ffffff;
|
|
||||||
top: 0;
|
top: 0;
|
||||||
display: block;
|
display: block;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
@@ -3485,6 +3484,9 @@
|
|||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
cursor: -webkit-grab;
|
cursor: -webkit-grab;
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.loading {
|
.loading {
|
||||||
@@ -3530,6 +3532,17 @@
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.btngroup2{
|
||||||
|
position: absolute;
|
||||||
|
bottom: 510px;
|
||||||
|
right: 0;
|
||||||
|
margin-right: 20px;
|
||||||
|
img{
|
||||||
|
box-shadow: none;
|
||||||
|
filter: grayscale(1)brightness(0)invert(1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.btngroup {
|
.btngroup {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
@@ -3562,11 +3575,17 @@
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
color: #FFF;
|
color: #FFF;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
&:active{
|
||||||
|
background-image: linear-gradient(to bottom,#002680, #1756ad);
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
button:disabled {
|
button:disabled {
|
||||||
background-color: #002680 !important;
|
background-color: #002680 !important;
|
||||||
;
|
|
||||||
filter: grayscale(100%);
|
filter: grayscale(100%);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -2321,7 +2321,7 @@ article .box .body {
|
|||||||
color: #fff;
|
color: #fff;
|
||||||
}
|
}
|
||||||
.modal.modal-image .body {
|
.modal.modal-image .body {
|
||||||
height: calc(100%-64px);
|
height: calc(100% - 64px);
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
@@ -3668,7 +3668,6 @@ article .box .body {
|
|||||||
position: absolute;
|
position: absolute;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
background: #ffffff;
|
|
||||||
top: 0;
|
top: 0;
|
||||||
display: block;
|
display: block;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
@@ -3677,6 +3676,9 @@ article .box .body {
|
|||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
cursor: -webkit-grab;
|
cursor: -webkit-grab;
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
}
|
}
|
||||||
.imageViewerZoom .loading {
|
.imageViewerZoom .loading {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
@@ -3715,6 +3717,16 @@ article .box .body {
|
|||||||
margin-right: 20px;
|
margin-right: 20px;
|
||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
}
|
}
|
||||||
|
.imageViewerZoom .btngroup2 {
|
||||||
|
position: absolute;
|
||||||
|
bottom: 510px;
|
||||||
|
right: 0;
|
||||||
|
margin-right: 20px;
|
||||||
|
}
|
||||||
|
.imageViewerZoom .btngroup2 img {
|
||||||
|
box-shadow: none;
|
||||||
|
filter: grayscale(1) brightness(0) invert(1);
|
||||||
|
}
|
||||||
.imageViewerZoom .btngroup {
|
.imageViewerZoom .btngroup {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
@@ -3730,8 +3742,6 @@ article .box .body {
|
|||||||
}
|
}
|
||||||
.imageViewerZoom button {
|
.imageViewerZoom button {
|
||||||
font-size: 20px;
|
font-size: 20px;
|
||||||
justify-content: center;
|
|
||||||
display: flex;
|
|
||||||
background-color: #ffffff;
|
background-color: #ffffff;
|
||||||
background-image: linear-gradient(to bottom, #1756ad, #002680);
|
background-image: linear-gradient(to bottom, #1756ad, #002680);
|
||||||
box-shadow: 0 3px 5px 0 rgba(0, 0, 0, 0.4);
|
box-shadow: 0 3px 5px 0 rgba(0, 0, 0, 0.4);
|
||||||
@@ -3744,6 +3754,12 @@ article .box .body {
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
color: #FFF;
|
color: #FFF;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
.imageViewerZoom button:active {
|
||||||
|
background-image: linear-gradient(to bottom, #002680, #1756ad);
|
||||||
}
|
}
|
||||||
.imageViewerZoom button:disabled {
|
.imageViewerZoom button:disabled {
|
||||||
background-color: #002680 !important;
|
background-color: #002680 !important;
|
||||||
|
|||||||
Generated
+18412
-18460
File diff suppressed because it is too large
Load Diff
@@ -12,6 +12,7 @@ import { loginService, machineService, localizationService } from "./services";
|
|||||||
import { prodService } from "./services/prodService";
|
import { prodService } from "./services/prodService";
|
||||||
import * as iziToast from "izitoast";
|
import * as iziToast from "izitoast";
|
||||||
import { underTheHoodService } from "./services/underTheHoodService";
|
import { underTheHoodService } from "./services/underTheHoodService";
|
||||||
|
import { warmersService } from "./services/warmersService";
|
||||||
|
|
||||||
// import { UsersService } from "./services/usersService";
|
// import { UsersService } from "./services/usersService";
|
||||||
|
|
||||||
@@ -60,7 +61,6 @@ async function loadMachineConfig() {
|
|||||||
|
|
||||||
await loginService.getUserInfo();
|
await loginService.getUserInfo();
|
||||||
|
|
||||||
|
|
||||||
try {
|
try {
|
||||||
let machine = new machineService();
|
let machine = new machineService();
|
||||||
let result = await machine.getAreasConfiguration();
|
let result = await machine.getAreasConfiguration();
|
||||||
@@ -68,12 +68,12 @@ async function loadMachineConfig() {
|
|||||||
|
|
||||||
let mcresult = await machine.getMachineConfiguration();
|
let mcresult = await machine.getMachineConfiguration();
|
||||||
machineStatusActions.setWarmersParameters(store, mcresult.additionalParameters);
|
machineStatusActions.setWarmersParameters(store, mcresult.additionalParameters);
|
||||||
|
await warmersService.GetResistances();
|
||||||
await prodService.GetProdPanel();
|
|
||||||
|
|
||||||
await underTheHoodService.getChannels();
|
await underTheHoodService.getChannels();
|
||||||
await underTheHoodService.getChannelsConfig();
|
await underTheHoodService.getChannelsConfig();
|
||||||
|
|
||||||
|
|
||||||
// load default language
|
// load default language
|
||||||
if (!(store.state as AppModel).localization.currentLanguage) {
|
if (!(store.state as AppModel).localization.currentLanguage) {
|
||||||
localizationService.changeCurrentLanguage(mcresult.defaultLanguage);
|
localizationService.changeCurrentLanguage(mcresult.defaultLanguage);
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
<label :class="{red: value.isScrap}" v-else>{{value.numDone}}</label>
|
<label :class="{red: value.isScrap}" v-else>{{value.numDone}}</label>
|
||||||
<div class="col">
|
<div class="col">
|
||||||
<small>{{'history-item_warmup' | localize("tempo riscaldo")}}</small>
|
<small>{{'history-item_warmup' | localize("tempo riscaldo")}}</small>
|
||||||
<span>{{Math.floor(value.timeWarm / 60) | round(0)}}'{{value.timeWarm % 60 | round(0)}}''</span>
|
<span>{{value.timeWarm | round(0)}}''</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="col">
|
<div class="col">
|
||||||
<small>{{'history-item_vacuum' | localize("vuoto")}}</small>
|
<small>{{'history-item_vacuum' | localize("vuoto")}}</small>
|
||||||
@@ -29,7 +29,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="col">
|
<div class="col">
|
||||||
<small>{{'history_item_venttime' | localize("tempo ventilazione")}}</small>
|
<small>{{'history_item_venttime' | localize("tempo ventilazione")}}</small>
|
||||||
<span>{{value.timeVent / 60 | round(0)}}'{{value.timeVent % 60 | round(0)}}''</span>
|
<span>{{value.timeVent | round(0)}}''</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="col">
|
<div class="col">
|
||||||
<small>{{'history_item_cycletimegross' | localize("tempo ciclo lordo")}}</small>
|
<small>{{'history_item_cycletimegross' | localize("tempo ciclo lordo")}}</small>
|
||||||
@@ -53,7 +53,7 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col">
|
<div class="col">
|
||||||
<small>{{'history_item_vacuumtime' | localize("tempo vuoto")}}</small>
|
<small>{{'history_item_vacuumtime' | localize("tempo vuoto")}}</small>
|
||||||
<span>{{Math.floor(value.timeVacuum / 60) | round(0)}}'{{value.timeVacuum % 60 | round(0)}}''</span>
|
<span>{{value.timeVacuum | round(0)}}''</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="col">
|
<div class="col">
|
||||||
<small>{{'history_item_mouldenergyin' | localize("energia utilizzata in")}}</small>
|
<small>{{'history_item_mouldenergyin' | localize("energia utilizzata in")}}</small>
|
||||||
|
|||||||
@@ -9,7 +9,6 @@ export default class stats extends Vue {
|
|||||||
value: { [id: number]: number };
|
value: { [id: number]: number };
|
||||||
|
|
||||||
get Values(): number[] {
|
get Values(): number[] {
|
||||||
console.log(this.value);
|
|
||||||
var r: number[] = [];
|
var r: number[] = [];
|
||||||
if (this.value)
|
if (this.value)
|
||||||
for (const i in this.value) {
|
for (const i in this.value) {
|
||||||
|
|||||||
@@ -10,18 +10,6 @@
|
|||||||
<line :x1="0" :x2="width" :y1="height*2/3" :y2="height*2/3" stroke="#353535" stroke-width="1" />
|
<line :x1="0" :x2="width" :y1="height*2/3" :y2="height*2/3" stroke="#353535" stroke-width="1" />
|
||||||
<line :x1="0" :x2="width" :y1="height" :y2="height" stroke="#353535" stroke-width="1" />
|
<line :x1="0" :x2="width" :y1="height" :y2="height" stroke="#353535" stroke-width="1" />
|
||||||
</g>
|
</g>
|
||||||
<!--<g chart="chart-axis">
|
|
||||||
<line
|
|
||||||
v-for="(i,idx) in Values"
|
|
||||||
:key="idx"
|
|
||||||
:x1="idx * (width / 19)"
|
|
||||||
:x2="idx * (width / 19)"
|
|
||||||
:y1="0"
|
|
||||||
:y2="height"
|
|
||||||
stroke="#35353550"
|
|
||||||
stroke-width="1"
|
|
||||||
/>
|
|
||||||
</g>-->
|
|
||||||
<g>
|
<g>
|
||||||
<polygon :points="calcPointFill" style="fill:#1791ff;stroke-width:0" fill-opacity="0.3" />
|
<polygon :points="calcPointFill" style="fill:#1791ff;stroke-width:0" fill-opacity="0.3" />
|
||||||
<path fill="none" :d="pathData" v-if="pathData" stroke="#1791ff" stroke-width="4" />
|
<path fill="none" :d="pathData" v-if="pathData" stroke="#1791ff" stroke-width="4" />
|
||||||
|
|||||||
@@ -118,8 +118,6 @@ export default class Dashboard extends Vue {
|
|||||||
this.itemsMap.set(i.numDone, i);
|
this.itemsMap.set(i.numDone, i);
|
||||||
}
|
}
|
||||||
this.items = Array.from(this.itemsMap.values()).sort((a, b) => b.numDone - a.numDone);
|
this.items = Array.from(this.itemsMap.values()).sort((a, b) => b.numDone - a.numDone);
|
||||||
|
|
||||||
console.log(this.items);
|
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -132,8 +130,6 @@ export default class Dashboard extends Vue {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async mounted() {
|
async mounted() {
|
||||||
prodService.GetProdPanel();
|
|
||||||
|
|
||||||
let $this = this;
|
let $this = this;
|
||||||
setInterval(() => {
|
setInterval(() => {
|
||||||
$this.now = moment();
|
$this.now = moment();
|
||||||
@@ -205,12 +201,32 @@ export default class Dashboard extends Vue {
|
|||||||
|
|
||||||
incrementPyr() {
|
incrementPyr() {
|
||||||
this.recipe.pyrometer_pyrometer_setpoint.setpointHMI++;
|
this.recipe.pyrometer_pyrometer_setpoint.setpointHMI++;
|
||||||
|
this.recipe.pyrometer_upperthermoregulator_start_adjustment.setpointHMI++;
|
||||||
|
this.recipe.pyrometer_upperthermoregulator_end_adjustment.setpointHMI++;
|
||||||
|
this.recipe.pyrometer_lowerthermoregulator_start_adjustment.setpointHMI++;
|
||||||
|
this.recipe.pyrometer_lowerthermoregulator_end_adjustment.setpointHMI++;
|
||||||
this.debouncedRecipeSave();
|
this.debouncedRecipeSave();
|
||||||
}
|
}
|
||||||
decrementPyr() {
|
decrementPyr() {
|
||||||
this.recipe.pyrometer_pyrometer_setpoint.setpointHMI--;
|
this.recipe.pyrometer_pyrometer_setpoint.setpointHMI--;
|
||||||
|
this.recipe.pyrometer_upperthermoregulator_start_adjustment.setpointHMI--;
|
||||||
|
this.recipe.pyrometer_upperthermoregulator_end_adjustment.setpointHMI--;
|
||||||
|
this.recipe.pyrometer_lowerthermoregulator_start_adjustment.setpointHMI--;
|
||||||
|
this.recipe.pyrometer_lowerthermoregulator_end_adjustment.setpointHMI--;
|
||||||
this.debouncedRecipeSave();
|
this.debouncedRecipeSave();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
togglePyr() {
|
||||||
|
if(this.recipe.pyrometer_pyrometer_enabled.setpointHMI == 1)
|
||||||
|
this.recipe.pyrometer_pyrometer_enabled.setpointHMI = 0;
|
||||||
|
else
|
||||||
|
this.recipe.pyrometer_pyrometer_enabled.setpointHMI = 1;
|
||||||
|
|
||||||
|
this.debouncedRecipeSave();
|
||||||
|
}
|
||||||
|
get pyrOn(){
|
||||||
|
return this.recipe.pyrometer_pyrometer_enabled.setpointHMI == 1;
|
||||||
|
}
|
||||||
debouncedRecipeSave = debounce(this.savePyr, 1000);
|
debouncedRecipeSave = debounce(this.savePyr, 1000);
|
||||||
|
|
||||||
public async savePyr(){
|
public async savePyr(){
|
||||||
@@ -229,7 +245,11 @@ export default class Dashboard extends Vue {
|
|||||||
get payload() {
|
get payload() {
|
||||||
return {
|
return {
|
||||||
pyrometer_pyrometer_enabled: this.recipe.pyrometer_pyrometer_enabled,
|
pyrometer_pyrometer_enabled: this.recipe.pyrometer_pyrometer_enabled,
|
||||||
pyrometer_pyrometer_setpoint: this.recipe.pyrometer_pyrometer_setpoint
|
pyrometer_pyrometer_setpoint: this.recipe.pyrometer_pyrometer_setpoint,
|
||||||
|
pyrometer_upperthermoregulator_start_adjustment: this.recipe.pyrometer_upperthermoregulator_start_adjustment,
|
||||||
|
pyrometer_upperthermoregulator_end_adjustment: this.recipe.pyrometer_upperthermoregulator_end_adjustment,
|
||||||
|
pyrometer_lowerthermoregulator_start_adjustment: this.recipe.pyrometer_lowerthermoregulator_start_adjustment,
|
||||||
|
pyrometer_lowerthermoregulator_end_adjustment: this.recipe.pyrometer_lowerthermoregulator_end_adjustment,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -118,9 +118,11 @@
|
|||||||
<button @click="decrementPyr()" :disabled="!recipe.pyrometer_pyrometer_setpoint.status.enabled" >
|
<button @click="decrementPyr()" :disabled="!recipe.pyrometer_pyrometer_setpoint.status.enabled" >
|
||||||
<i class="fa fa-minus"></i>
|
<i class="fa fa-minus"></i>
|
||||||
</button>
|
</button>
|
||||||
<div :class="{'notenabled': recipe.pyrometer_pyrometer_enabled.setpointHMI == 0}">
|
<div :class="{'notenabled': recipe.pyrometer_pyrometer_enabled.setpointHMI == 0}" @click="togglePyr">
|
||||||
<small>{{'dashboard-setpoint' | localize('set point')}}</small>
|
<small>{{'dashboard-setpoint' | localize('set point')}}</small>
|
||||||
<span :class="{'strike': recipe.pyrometer_pyrometer_enabled.setpointHMI == 0}">{{recipe.pyrometer_pyrometer_setpoint.setpointHMI}}{{recipe.pyrometer_pyrometer_setpoint.unitMeasure}}</span>
|
<span :class="{'strike': recipe.pyrometer_pyrometer_enabled.setpointHMI == 0}">{{recipe.pyrometer_pyrometer_setpoint.setpointHMI}}{{recipe.pyrometer_pyrometer_setpoint.unitMeasure}}</span>
|
||||||
|
<div v-if="pyrOn">ON</div>
|
||||||
|
<div v-else>OFF</div>
|
||||||
</div>
|
</div>
|
||||||
<button @click="incrementPyr()" :disabled="!recipe.pyrometer_pyrometer_setpoint.status.enabled" >
|
<button @click="incrementPyr()" :disabled="!recipe.pyrometer_pyrometer_setpoint.status.enabled" >
|
||||||
<i class="fa fa-plus"></i>
|
<i class="fa fa-plus"></i>
|
||||||
|
|||||||
+2
-2
@@ -42,8 +42,8 @@ export default class SVGCaricatore extends Vue{
|
|||||||
minoreuguale:string="<=";
|
minoreuguale:string="<=";
|
||||||
|
|
||||||
getPositionSheet(id,col){
|
getPositionSheet(id,col){
|
||||||
var vent = ((this.larghTelaioSVG + (this.dimVentose*2)) / (this.numVentose +1));
|
var vent = (this.larghTelaioSVG - (this.dimVentose*2)) / (this.numVentose -1);
|
||||||
var posX = (id*vent ) - (this.dimVentose*2);
|
var posX = (id-1)*vent;
|
||||||
if(col == 1)
|
if(col == 1)
|
||||||
return "translate(-630 -147) translate(50 25) translate(580 122) translate(0 70) translate(0 0) translate("+ posX + ")";
|
return "translate(-630 -147) translate(50 25) translate(580 122) translate(0 70) translate(0 0) translate("+ posX + ")";
|
||||||
else if(col == 2)
|
else if(col == 2)
|
||||||
|
|||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="svg-area">
|
<div class="svg-area">
|
||||||
<svg xmlns="http://www.w3.org/2000/svg" width="1057" height="707" viewBox="0 0 1100 707">
|
<svg xmlns="http://www.w3.org/2000/svg" width="1057" height="707" viewBox="-50 0 1150 707">
|
||||||
<g fill="none" fill-rule="evenodd">
|
<g fill="none" fill-rule="evenodd">
|
||||||
<g>
|
<g>
|
||||||
<g>
|
<g>
|
||||||
|
|||||||
@@ -122,10 +122,6 @@ export default class ShowCicloInfo extends Vue {
|
|||||||
if (el.status.visible && el.status.enabled)
|
if (el.status.visible && el.status.enabled)
|
||||||
if (el.setpointHMI != el.setpointPLC) result = true;
|
if (el.setpointHMI != el.setpointPLC) result = true;
|
||||||
}
|
}
|
||||||
for (const key in store.state.warmers.channels) {
|
|
||||||
const el = store.state.warmers.channels[key];
|
|
||||||
if (el.setpointHMI != el.setpointPLC) result = true;
|
|
||||||
}
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -20,6 +20,12 @@
|
|||||||
position: relative;
|
position: relative;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
.bitSelect .form.error {
|
||||||
|
outline: 2px #d0021b auto !important;
|
||||||
|
}
|
||||||
|
.bitSelect .form.disabled {
|
||||||
|
background-color: rgba(0, 0, 0, 0.15);
|
||||||
|
}
|
||||||
.bitSelect .form i {
|
.bitSelect .form i {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
right: 4px;
|
right: 4px;
|
||||||
@@ -40,6 +46,18 @@
|
|||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
height: auto !important;
|
height: auto !important;
|
||||||
width: 500px !important;
|
width: 500px !important;
|
||||||
|
border-top: 1px solid #979797;
|
||||||
|
border-left: 1px solid #979797;
|
||||||
|
}
|
||||||
|
.bitSelect > section.bitsections .selall {
|
||||||
|
grid-column-start: 1;
|
||||||
|
grid-column-end: 3;
|
||||||
|
display: flex;
|
||||||
|
justify-content: flex-end;
|
||||||
|
align-items: center;
|
||||||
|
margin: 24px 0px 0 0;
|
||||||
|
height: 64px;
|
||||||
|
border-top: 2px solid #bbbcbc;
|
||||||
}
|
}
|
||||||
.bitSelect > section.bitsections > article {
|
.bitSelect > section.bitsections > article {
|
||||||
height: 70px !important;
|
height: 70px !important;
|
||||||
@@ -47,7 +65,8 @@
|
|||||||
grid-template-columns: 68px 1fr;
|
grid-template-columns: 68px 1fr;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-items: center;
|
justify-items: center;
|
||||||
border: 1px solid #979797;
|
border-bottom: 1px solid #979797;
|
||||||
|
border-right: 1px solid #979797;
|
||||||
}
|
}
|
||||||
.bitSelect > section.bitsections > article label {
|
.bitSelect > section.bitsections > article label {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
|||||||
@@ -19,6 +19,16 @@
|
|||||||
padding-right: 25px;
|
padding-right: 25px;
|
||||||
position: relative;
|
position: relative;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
|
||||||
|
&.error{
|
||||||
|
outline: 2px #d0021b auto !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.disabled{
|
||||||
|
background-color: rgba(0, 0, 0, 0.15);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
i {
|
i {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
right: 4px;
|
right: 4px;
|
||||||
@@ -27,7 +37,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
> section.bitsections {
|
> section.bitsections {
|
||||||
position: absolute !important;
|
position: absolute !important;
|
||||||
top: 48px;
|
top: 48px;
|
||||||
right: 0;
|
right: 0;
|
||||||
@@ -42,13 +52,28 @@
|
|||||||
height: auto !important;
|
height: auto !important;
|
||||||
width: 500px !important;
|
width: 500px !important;
|
||||||
|
|
||||||
|
border-top: 1px solid #979797;
|
||||||
|
border-left: 1px solid #979797;
|
||||||
|
|
||||||
|
.selall{
|
||||||
|
grid-column-start:1;
|
||||||
|
grid-column-end:3;
|
||||||
|
display: flex;
|
||||||
|
justify-content: flex-end;
|
||||||
|
align-items: center;
|
||||||
|
margin: 24px 0px 0 0;
|
||||||
|
height: 64px;
|
||||||
|
border-top: 2px solid #bbbcbc;
|
||||||
|
}
|
||||||
|
|
||||||
> article {
|
> article {
|
||||||
height: 70px !important;
|
height: 70px !important;
|
||||||
display: grid !important;
|
display: grid !important;
|
||||||
grid-template-columns: 68px 1fr;
|
grid-template-columns: 68px 1fr;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-items: center;
|
justify-items: center;
|
||||||
border: 1px solid #979797;
|
border-bottom: 1px solid #979797;
|
||||||
|
border-right: 1px solid #979797;
|
||||||
|
|
||||||
label {
|
label {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
|||||||
@@ -23,6 +23,13 @@ export default class bitSelect extends Vue {
|
|||||||
this.value.setpointHMI = v;
|
this.value.setpointHMI = v;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
openclose(){
|
||||||
|
if(!this.value || !this.value.status || !this.value.status.enabled)
|
||||||
|
return
|
||||||
|
|
||||||
|
this.opened = !this.opened
|
||||||
|
}
|
||||||
|
|
||||||
get currentValue() {
|
get currentValue() {
|
||||||
let result = []
|
let result = []
|
||||||
for (let index = 0; index < this.bitSize; index++) {
|
for (let index = 0; index < this.bitSize; index++) {
|
||||||
@@ -66,4 +73,20 @@ export default class bitSelect extends Vue {
|
|||||||
return this.bit_test(this.value.range.max,bit-1);
|
return this.bit_test(this.value.range.max,bit-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
setAll(){
|
||||||
|
this.Value = this.value.range.max;
|
||||||
|
|
||||||
|
for (let i = 0; i < this.bitSize; i++) {
|
||||||
|
Vue.set(this.bits, i, this.bit_test(this.Value, i))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
clearAll(){
|
||||||
|
this.Value = 0;
|
||||||
|
|
||||||
|
for (let i = 0; i < this.bitSize; i++) {
|
||||||
|
Vue.set(this.bits, i, this.bit_test(this.Value, i))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -2,7 +2,7 @@
|
|||||||
<div class="bitSelect">
|
<div class="bitSelect">
|
||||||
<div
|
<div
|
||||||
class="form"
|
class="form"
|
||||||
@click="opened = !opened"
|
@click="openclose"
|
||||||
:class="{'error': value && value.status && value.status.hasError, 'disabled': value && value.status && !value.status.enabled}"
|
:class="{'error': value && value.status && value.status.hasError, 'disabled': value && value.status && !value.status.enabled}"
|
||||||
>
|
>
|
||||||
{{currentValue}}
|
{{currentValue}}
|
||||||
@@ -24,6 +24,10 @@
|
|||||||
<label :for="`cb-${b}`">{{`${key}_${b}` | localize((b).toString())}}</label>
|
<label :for="`cb-${b}`">{{`${key}_${b}` | localize((b).toString())}}</label>
|
||||||
</article>
|
</article>
|
||||||
</template>
|
</template>
|
||||||
|
<div class="selall">
|
||||||
|
<button class="btn" @click="clearAll">{{'bitselect_select_none' | localize('Nessuno')}}</button>
|
||||||
|
<button class="btn btn-success" @click="setAll">{{'bitselect_select_all' | localize('Tutti')}}</button>
|
||||||
|
</div>
|
||||||
</section>
|
</section>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
+11
-2
@@ -68,17 +68,26 @@
|
|||||||
.modal.prophetimages section .image-selector .timeseries {
|
.modal.prophetimages section .image-selector .timeseries {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
display: flex;
|
||||||
|
flex-flow: row;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
}
|
}
|
||||||
.modal.prophetimages section .image-selector .timeseries time {
|
.modal.prophetimages section .image-selector .timeseries time {
|
||||||
color: #002680;
|
color: #002680;
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
width: 200px;
|
width: 200px;
|
||||||
position: absolute;
|
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-flow: column;
|
flex-flow: column;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
.modal.prophetimages section .image-selector .timeseries time:last-child {
|
||||||
|
align-items: flex-end;
|
||||||
|
}
|
||||||
|
.modal.prophetimages section .image-selector .timeseries time:first-child {
|
||||||
|
align-items: flex-start;
|
||||||
|
}
|
||||||
.modal.prophetimages section .image-selector .selector {
|
.modal.prophetimages section .image-selector .selector {
|
||||||
color: #002680;
|
color: #002680;
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
@@ -101,7 +110,7 @@
|
|||||||
}
|
}
|
||||||
.modal.prophetimages section .color-bar .color-line {
|
.modal.prophetimages section .color-bar .color-line {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
background-image: linear-gradient(to bottom, #fff, #ffdf00 16%, #e40000 37%, #ab00a5 62%, #000ca4 86%, #000000);
|
background-image: linear-gradient(to bottom, #ffffff, #ffffcc 16%, #ff9900 48%, #ff0066 64%, #3300ff 80%, #000033);
|
||||||
}
|
}
|
||||||
.modal.prophetimages section .color-bar .legend {
|
.modal.prophetimages section .color-bar .legend {
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|||||||
+16
-7
@@ -69,17 +69,26 @@
|
|||||||
.timeseries {
|
.timeseries {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
display: flex;
|
||||||
|
flex-flow: row;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
|
||||||
time {
|
time {
|
||||||
color: #002680;
|
color: #002680;
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
width: 200px;
|
width: 200px;
|
||||||
position: absolute;
|
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-flow: column;
|
flex-flow: column;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
time:last-child{
|
||||||
|
align-items:flex-end;
|
||||||
|
}
|
||||||
|
time:first-child{
|
||||||
|
align-items:flex-start;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.selector {
|
.selector {
|
||||||
@@ -109,12 +118,12 @@
|
|||||||
height: 100%;
|
height: 100%;
|
||||||
background-image: linear-gradient(
|
background-image: linear-gradient(
|
||||||
to bottom,
|
to bottom,
|
||||||
#fff,
|
rgba(255,255,255,1),
|
||||||
#ffdf00 16%,
|
rgba(255,255,204,1) 16%,
|
||||||
#e40000 37%,
|
rgba(255,153,0,1) 48%,
|
||||||
#ab00a5 62%,
|
rgba(255,0,102,1) 64%,
|
||||||
#000ca4 86%,
|
rgba(51,0,255,1) 80%,
|
||||||
#000000
|
rgba(0,0,51,1)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+6
@@ -32,6 +32,7 @@ export default class ThermoModal extends Vue {
|
|||||||
selectedImage: number = 0;
|
selectedImage: number = 0;
|
||||||
serverPath = "/thermoprophet/colored";
|
serverPath = "/thermoprophet/colored";
|
||||||
items: Prod.IProd[] = [];
|
items: Prod.IProd[] = [];
|
||||||
|
|
||||||
get images() {
|
get images() {
|
||||||
return this.items.map(i => i.thermoImage)
|
return this.items.map(i => i.thermoImage)
|
||||||
}
|
}
|
||||||
@@ -48,6 +49,7 @@ export default class ThermoModal extends Vue {
|
|||||||
this.TCamData = await warmersService.GetTCamData();
|
this.TCamData = await warmersService.GetTCamData();
|
||||||
await warmersService.ResetMeasurePoints();
|
await warmersService.ResetMeasurePoints();
|
||||||
|
|
||||||
|
console.log(this.lastItem);
|
||||||
let min = Math.min(this.lastItem.numDone);
|
let min = Math.min(this.lastItem.numDone);
|
||||||
this.items.push(...await prodService.History(min - 1, min - 1))
|
this.items.push(...await prodService.History(min - 1, min - 1))
|
||||||
}
|
}
|
||||||
@@ -63,6 +65,10 @@ export default class ThermoModal extends Vue {
|
|||||||
this.reloadMeasuresDelayed(this.images[this.selectedImage], this.measurePoints);
|
this.reloadMeasuresDelayed(this.images[this.selectedImage], this.measurePoints);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
getImageCycle(Sel){
|
||||||
|
return this.items[Sel];
|
||||||
|
}
|
||||||
|
|
||||||
@Watch("selectedImage")
|
@Watch("selectedImage")
|
||||||
reloadMeasuresDelayed = debounce(async (image, points) => {
|
reloadMeasuresDelayed = debounce(async (image, points) => {
|
||||||
let result = await warmersService.GetMeasurePoints(image);
|
let result = await warmersService.GetMeasurePoints(image);
|
||||||
|
|||||||
+19
-5
@@ -6,10 +6,16 @@
|
|||||||
<div class="imagecontainer">
|
<div class="imagecontainer">
|
||||||
<img
|
<img
|
||||||
:src="`${serverPath}/${images[parseInt(selectedImage)]}.jpg`"
|
:src="`${serverPath}/${images[parseInt(selectedImage)]}.jpg`"
|
||||||
|
v-if="images.length && images[selectedImage]!='UNDEFINED'"
|
||||||
@click="imageclick"
|
@click="imageclick"
|
||||||
v-if="images.length"
|
|
||||||
ref="mainimage"
|
ref="mainimage"
|
||||||
/>
|
/>
|
||||||
|
<img
|
||||||
|
src="assets\icons\png\NOCamera.png"
|
||||||
|
v-if="images.length && images[selectedImage]=='UNDEFINED'"
|
||||||
|
ref="mainimage"
|
||||||
|
/>
|
||||||
|
|
||||||
<span>{{'thermo-long-tap-info' | localize("Long tap on image to add temperature inspectors")}}</span>
|
<span>{{'thermo-long-tap-info' | localize("Long tap on image to add temperature inspectors")}}</span>
|
||||||
|
|
||||||
<div
|
<div
|
||||||
@@ -29,15 +35,22 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="image-selector">
|
<div class="image-selector">
|
||||||
<div class="timeseries">
|
<div class="timeseries">
|
||||||
<!-- <time>{{'first-image' | localize("First image")}}</time>
|
<time>{{'last-image' | localize("Last image")}}</time>
|
||||||
<time>{{'last-image' | localize("Last image")}}</time>-->
|
<time class="center"> </time>
|
||||||
|
<time>{{'first-image' | localize("First image")}}</time>
|
||||||
</div>
|
</div>
|
||||||
<img
|
<img
|
||||||
:src="`${serverPath}/${images[parseInt(selectedImage)]}.jpg`"
|
:src="`${serverPath}/${images[parseInt(selectedImage)]}.jpg`"
|
||||||
v-if="showPreview"
|
v-if="showPreview && images[selectedImage]!='UNDEFINED'"
|
||||||
class="selector"
|
class="selector"
|
||||||
:style="`left:${(parseInt(selectedImage) / (images.length-1)) * 858}px`"
|
:style="`left:${(parseInt(selectedImage) / (images.length-1)) * 858}px`"
|
||||||
/>
|
/>
|
||||||
|
<img
|
||||||
|
src="assets\icons\png\NOCamera.png"
|
||||||
|
v-if="showPreview && images[selectedImage]=='UNDEFINED'"
|
||||||
|
class="selector"
|
||||||
|
:style="`left:${(parseInt(selectedImage) / (images.length-1)) * 858}px; background-color:#ffffff;`"
|
||||||
|
/>
|
||||||
<input
|
<input
|
||||||
v-if="images.length"
|
v-if="images.length"
|
||||||
type="range"
|
type="range"
|
||||||
@@ -50,8 +63,9 @@
|
|||||||
<div class="selectorarea">
|
<div class="selectorarea">
|
||||||
<span
|
<span
|
||||||
class="selector"
|
class="selector"
|
||||||
|
v-if="getImageCycle(selectedImage)"
|
||||||
:style="`left:${(parseInt(selectedImage) / (images.length-1)) * 858}px`"
|
:style="`left:${(parseInt(selectedImage) / (images.length-1)) * 858}px`"
|
||||||
>{{'thermo-cycle' | localize("Cycle")}} {{selectedImage}}</span>
|
>{{'thermo-cycle' | localize("Cycle")}} {{getImageCycle(selectedImage).numDone}}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</modal>
|
</modal>
|
||||||
|
|||||||
+70
@@ -0,0 +1,70 @@
|
|||||||
|
.warmers {
|
||||||
|
display: grid !important;
|
||||||
|
grid-template-columns: 1fr 70px;
|
||||||
|
margin-right: -14px;
|
||||||
|
}
|
||||||
|
.warmers .right-controls {
|
||||||
|
display: flex;
|
||||||
|
flex-flow: column nowrap;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
}
|
||||||
|
.warmers .right-controls .tm-controls {
|
||||||
|
display: flex;
|
||||||
|
flex-flow: column;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
height: 420px;
|
||||||
|
}
|
||||||
|
.warmers .right-controls .tm-controls input[type="range"][orient="vertical"] {
|
||||||
|
writing-mode: bt-lr;
|
||||||
|
/* IE */
|
||||||
|
-webkit-appearance: slider-vertical;
|
||||||
|
/* WebKit */
|
||||||
|
width: 6px;
|
||||||
|
height: 150px;
|
||||||
|
border: none !important;
|
||||||
|
box-shadow: inset 0 1px 3px 0 rgba(0, 0, 0, 0.5);
|
||||||
|
border-radius: 10px;
|
||||||
|
}
|
||||||
|
.warmers .right-controls .tm-controls input[type="range"][orient="vertical"]::-webkit-slider-thumb {
|
||||||
|
min-width: 30px;
|
||||||
|
min-height: 30px;
|
||||||
|
border: none;
|
||||||
|
background: none !important;
|
||||||
|
appearance: none;
|
||||||
|
}
|
||||||
|
.warmers .right-controls .tm-controls input[type="range"]::-webkit-slider-thumb {
|
||||||
|
background-color: linear-gradient(to bottom, #1756ad, #002e6e 97%) !important;
|
||||||
|
}
|
||||||
|
.warmers .right-controls .um-buttons {
|
||||||
|
background-color: #dddddd;
|
||||||
|
height: 130px;
|
||||||
|
width: 40px;
|
||||||
|
border-radius: 20px;
|
||||||
|
box-shadow: inset 0 1px 3px 0 rgba(0, 0, 0, 0.5);
|
||||||
|
display: flex;
|
||||||
|
flex-flow: column nowrap;
|
||||||
|
justify-content: space-around;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
.warmers .right-controls .um-buttons button {
|
||||||
|
width: 34px;
|
||||||
|
height: 34px;
|
||||||
|
border-radius: 50px;
|
||||||
|
border: none;
|
||||||
|
text-align: center;
|
||||||
|
line-height: 34px;
|
||||||
|
font-size: 18px;
|
||||||
|
font-weight: bold;
|
||||||
|
color: #fff;
|
||||||
|
box-shadow: inset 0 2px 2px 0 rgba(0, 0, 0, 0.19);
|
||||||
|
background-color: rgba(187, 188, 188, 0.5);
|
||||||
|
}
|
||||||
|
.warmers .right-controls .um-buttons button.selected {
|
||||||
|
box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.5);
|
||||||
|
background-image: linear-gradient(to bottom, #1756ad, #002e6e 97%);
|
||||||
|
}
|
||||||
|
.warmers .right-controls .buttons button {
|
||||||
|
margin: 8px;
|
||||||
|
}
|
||||||
+2
-2
@@ -13,13 +13,13 @@
|
|||||||
flex-flow: column;
|
flex-flow: column;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
height: 350px;
|
height: 420px;
|
||||||
|
|
||||||
input[type="range"][orient="vertical"] {
|
input[type="range"][orient="vertical"] {
|
||||||
writing-mode: bt-lr; /* IE */
|
writing-mode: bt-lr; /* IE */
|
||||||
-webkit-appearance: slider-vertical; /* WebKit */
|
-webkit-appearance: slider-vertical; /* WebKit */
|
||||||
width: 6px;
|
width: 6px;
|
||||||
height: 250px;
|
height: 150px;
|
||||||
border: none !important;
|
border: none !important;
|
||||||
box-shadow: inset 0 1px 3px 0 rgba(0, 0, 0, 0.5);
|
box-shadow: inset 0 1px 3px 0 rgba(0, 0, 0, 0.5);
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
|
|||||||
+84
-6
@@ -8,11 +8,14 @@ import { warmersService } from "@/services/warmersService";
|
|||||||
import { awaiter } from '@/_base';
|
import { awaiter } from '@/_base';
|
||||||
import termoModal from "./thermoProphet-modal.vue";
|
import termoModal from "./thermoProphet-modal.vue";
|
||||||
import { ModalHelper } from '@/components/modals';
|
import { ModalHelper } from '@/components/modals';
|
||||||
|
import moment from "moment";
|
||||||
|
import { messageService } from "src/_base";
|
||||||
|
import ModalImage from "@/modules/base-components/modal-image.vue";
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
name: "thermocamera", components: {
|
name: "thermocamera", components: {
|
||||||
|
|
||||||
warmers
|
warmers,ModalImage
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
export default class Thermocamera extends Vue {
|
export default class Thermocamera extends Vue {
|
||||||
@@ -29,19 +32,28 @@ export default class Thermocamera extends Vue {
|
|||||||
thermoImageOpacity: number = 0;
|
thermoImageOpacity: number = 0;
|
||||||
resistanceMode = 0;
|
resistanceMode = 0;
|
||||||
|
|
||||||
|
timeoutLastTakenImage = 0;
|
||||||
|
timeCamDiff = " ";
|
||||||
|
|
||||||
|
tcamBTNStatus:{
|
||||||
|
enabled: boolean,
|
||||||
|
visible: boolean
|
||||||
|
} = {enabled : false, visible: true};
|
||||||
|
|
||||||
TCamData: {
|
TCamData: {
|
||||||
imageSize: { x: number, y: number },
|
imageSize: { x: number, y: number },
|
||||||
rangeTemperature: { max: number, min: number },
|
rangeTemperature: { max: number, min: number },
|
||||||
|
thermoCamConnected: boolean,
|
||||||
|
thermoOptionActive: boolean,
|
||||||
|
lastTakenImage: Date,
|
||||||
} = null;
|
} = null;
|
||||||
|
|
||||||
@Watch("warmers", { deep: true })
|
@Watch("warmers", { deep: true })
|
||||||
async ChangedTemps() {
|
async ChangedTemps() {
|
||||||
|
this.tcamBTNStatus.enabled = false;
|
||||||
|
|
||||||
this.btnModeEnabled = false;
|
|
||||||
for (const ch of store.state.warmers.channels) {
|
for (const ch of store.state.warmers.channels) {
|
||||||
if (ch.tCamTempSet > 0) {
|
if (ch.tCamTempSet > 0 && ch.tCamActive) {
|
||||||
this.btnModeEnabled = true;
|
this.tcamBTNStatus.enabled = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -53,6 +65,13 @@ export default class Thermocamera extends Vue {
|
|||||||
async mounted() {
|
async mounted() {
|
||||||
this.ChangedTemps();
|
this.ChangedTemps();
|
||||||
this.TCamData = await warmersService.GetTCamData();
|
this.TCamData = await warmersService.GetTCamData();
|
||||||
|
|
||||||
|
messageService.subscribeToChannel("new-thermocam-image", (args)=>{
|
||||||
|
if(this.TCamData){
|
||||||
|
this.TCamData.lastTakenImage = args[0];
|
||||||
|
ModalHelper.modalImage.content = this.thermocameraOriginalUrl;
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
get selectedChannels(): Warmers.IChannel[] {
|
get selectedChannels(): Warmers.IChannel[] {
|
||||||
@@ -75,6 +94,50 @@ export default class Thermocamera extends Vue {
|
|||||||
// return (store.state.warmers.tCamStatus.thermoCamMode);
|
// return (store.state.warmers.tCamStatus.thermoCamMode);
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
get thermocameraImageUrl(){
|
||||||
|
if(!this.TCamData || moment(this.TCamData.lastTakenImage).year() <= 2000)
|
||||||
|
return "/thermoprophet/colored/_last.jpg?lastmod=NOTAVAILABLE";
|
||||||
|
return "/thermoprophet/colored/_last.jpg?lastmod=" + this.TCamData.lastTakenImage;
|
||||||
|
}
|
||||||
|
get thermocameraOriginalUrl(){
|
||||||
|
if(!this.TCamData || moment(this.TCamData.lastTakenImage).year() <= 2000)
|
||||||
|
return "/thermoprophet/original/_last.jpg?lastmod=NOTAVAILABLE";
|
||||||
|
return "/thermoprophet/original/_last.jpg?lastmod=" + this.TCamData.lastTakenImage;
|
||||||
|
}
|
||||||
|
|
||||||
|
get thermocameraImageOk(): boolean {
|
||||||
|
clearInterval(this.timeoutLastTakenImage);
|
||||||
|
this.timeCamDiff = " "
|
||||||
|
|
||||||
|
if(!this.TCamData)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
if(moment(this.TCamData.lastTakenImage).year() > 2000)
|
||||||
|
{
|
||||||
|
this.lastTakenImageFuncion();
|
||||||
|
this.timeoutLastTakenImage = setInterval(this.lastTakenImageFuncion,10000);
|
||||||
|
return true;
|
||||||
|
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
lastTakenImageFuncion(){
|
||||||
|
var today = moment(new Date());
|
||||||
|
var end = moment(this.TCamData.lastTakenImage);
|
||||||
|
var diff = (moment.duration(today.diff(end)) as any)._data;
|
||||||
|
var seconds = diff.seconds;
|
||||||
|
var minutes = diff.minutes;
|
||||||
|
var hours = diff.hours;
|
||||||
|
|
||||||
|
if(hours >0)
|
||||||
|
this.timeCamDiff = hours + "h " + minutes + "m ";
|
||||||
|
else if(minutes >0)
|
||||||
|
this.timeCamDiff = minutes + "m " + seconds + "s ";
|
||||||
|
else
|
||||||
|
this.timeCamDiff = seconds + "s";
|
||||||
|
}
|
||||||
|
|
||||||
get thermocameraModeBTN(): boolean {
|
get thermocameraModeBTN(): boolean {
|
||||||
return (store.state.warmers.tCamStatus.thermoCamOnOff);
|
return (store.state.warmers.tCamStatus.thermoCamOnOff);
|
||||||
}
|
}
|
||||||
@@ -177,4 +240,19 @@ export default class Thermocamera extends Vue {
|
|||||||
async openThermoModal() {
|
async openThermoModal() {
|
||||||
ModalHelper.ShowModal(termoModal, "modal2");
|
ModalHelper.ShowModal(termoModal, "modal2");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
async openImageModal() {
|
||||||
|
|
||||||
|
if(this.TCamData){
|
||||||
|
ModalHelper.modalImage.title = moment(this.TCamData.lastTakenImage).format("L") + " - " + moment(this.TCamData.lastTakenImage).format("LTS");
|
||||||
|
}
|
||||||
|
ModalHelper.modalImage.content = this.thermocameraOriginalUrl;
|
||||||
|
ModalHelper.ShowModal(ModalImage, "modal2");
|
||||||
|
}
|
||||||
|
|
||||||
|
async forceTakeImage() {
|
||||||
|
warmersService.TakeNewPhoto();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
+13
-6
@@ -79,7 +79,7 @@
|
|||||||
|
|
||||||
<div class="input-area grid left">
|
<div class="input-area grid left">
|
||||||
<label>{{'warmers_thermoprophet_Enabled' | localize('Thermoprophet')}}</label>
|
<label>{{'warmers_thermoprophet_Enabled' | localize('Thermoprophet')}}</label>
|
||||||
<toggle-button v-model="thermocameraModeBTN"></toggle-button>
|
<toggle-button v-model="thermocameraModeBTN" :status="tcamBTNStatus"></toggle-button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- <div class="input-area left grid">
|
<!-- <div class="input-area left grid">
|
||||||
@@ -111,8 +111,8 @@
|
|||||||
@methodChanged="m => selectionMethod = m"
|
@methodChanged="m => selectionMethod = m"
|
||||||
:recipe="recipe"
|
:recipe="recipe"
|
||||||
:resistanceMode="resistanceMode"
|
:resistanceMode="resistanceMode"
|
||||||
thermoImage="/thermoprophet/colored/_last.jpg"
|
:thermoImage="thermocameraImageUrl"
|
||||||
:thermoImageVisible="thermocameraModeBTN"
|
:thermoImageVisible="true"
|
||||||
:thermoImageOpacity="thermoImageOpacity"
|
:thermoImageOpacity="thermoImageOpacity"
|
||||||
:isThermoProphet="true"
|
:isThermoProphet="true"
|
||||||
></warmers>
|
></warmers>
|
||||||
@@ -125,11 +125,18 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="tm-controls">
|
<div class="tm-controls">
|
||||||
<button class="btn btn-info square" @click="openThermoModal()">
|
<button class="btn btn-info square" @click="forceTakeImage()" :disabled="this.thermocameraModeBTN">
|
||||||
|
<img src="/assets/icons/png/takesnap.png" />
|
||||||
|
</button>
|
||||||
|
<button class="btn btn-info square" @click="openImageModal()">
|
||||||
<img src="/assets/icons/png/ico-bt-selez-image.png" />
|
<img src="/assets/icons/png/ico-bt-selez-image.png" />
|
||||||
</button>
|
</button>
|
||||||
|
<button class="btn btn-info square" @click="openThermoModal()">
|
||||||
|
<img src="/assets/icons/png/history.png" />
|
||||||
|
</button>
|
||||||
|
<span>{{timeCamDiff}}</span>
|
||||||
<input
|
<input
|
||||||
:disabled="!thermocameraModeBTN"
|
:disabled="!thermocameraImageOk"
|
||||||
type="range"
|
type="range"
|
||||||
orient="vertical"
|
orient="vertical"
|
||||||
v-model="thermoImageOpacity"
|
v-model="thermoImageOpacity"
|
||||||
@@ -141,7 +148,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="buttons">
|
<div class="buttons">
|
||||||
<button class="btn btn-info square icon" @click="zoomIn()">
|
<button class="btn btn-info square icon" @click="zoomIn()" >
|
||||||
<i class="fa fa-search-plus"></i>
|
<i class="fa fa-search-plus"></i>
|
||||||
</button>
|
</button>
|
||||||
<button class="btn btn-info square icon" @click="zoomReset()">
|
<button class="btn btn-info square icon" @click="zoomReset()">
|
||||||
|
|||||||
-1
@@ -90,7 +90,6 @@ export default class Warmers extends Vue {
|
|||||||
|
|
||||||
// Ottengo le resistenze per ogni riga
|
// Ottengo le resistenze per ogni riga
|
||||||
resistancesPerRow(row: number) {
|
resistancesPerRow(row: number) {
|
||||||
console.log(row,this.resistances.filter(i => i.row == row))
|
|
||||||
return this.resistances.filter(i => i.row == row);
|
return this.resistances.filter(i => i.row == row);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+6
@@ -70,6 +70,9 @@ export default class VuotoPrincipale extends Vue {
|
|||||||
if(this.recipe.vacuum_main_2_chart_setpointx.setpointHMI <= 0 && this.recipe.vacuum_main_3_chart_setpointx.setpointHMI <= 0){
|
if(this.recipe.vacuum_main_2_chart_setpointx.setpointHMI <= 0 && this.recipe.vacuum_main_3_chart_setpointx.setpointHMI <= 0){
|
||||||
|
|
||||||
this.recipe.vacuum_main_1_chart_setpointx.setpointHMI = this.recipe.vacuum_main_max_time.setpointHMI;
|
this.recipe.vacuum_main_1_chart_setpointx.setpointHMI = this.recipe.vacuum_main_max_time.setpointHMI;
|
||||||
|
this.recipe.vacuum_main_2_chart_setpointx.setpointHMI = 0;
|
||||||
|
this.recipe.vacuum_main_3_chart_setpointx.setpointHMI = 0;
|
||||||
|
|
||||||
}
|
}
|
||||||
else if (this.recipe.vacuum_main_3_chart_setpointx.setpointHMI > 0){
|
else if (this.recipe.vacuum_main_3_chart_setpointx.setpointHMI > 0){
|
||||||
diff = this.recipe.vacuum_main_max_time.setpointHMI -
|
diff = this.recipe.vacuum_main_max_time.setpointHMI -
|
||||||
@@ -86,6 +89,7 @@ export default class VuotoPrincipale extends Vue {
|
|||||||
this.recipe.vacuum_main_3_chart_setpointx.setpointHMI;
|
this.recipe.vacuum_main_3_chart_setpointx.setpointHMI;
|
||||||
|
|
||||||
this.recipe.vacuum_main_2_chart_setpointx.setpointHMI = diff;
|
this.recipe.vacuum_main_2_chart_setpointx.setpointHMI = diff;
|
||||||
|
this.recipe.vacuum_main_3_chart_setpointx.setpointHMI = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
@@ -103,6 +107,7 @@ export default class VuotoPrincipale extends Vue {
|
|||||||
this.recipe.vacuum_main_3_chart_setpointx.setpointHMI;
|
this.recipe.vacuum_main_3_chart_setpointx.setpointHMI;
|
||||||
|
|
||||||
this.recipe.vacuum_main_2_chart_setpointx.setpointHMI = diff;
|
this.recipe.vacuum_main_2_chart_setpointx.setpointHMI = diff;
|
||||||
|
this.recipe.vacuum_main_3_chart_setpointx.setpointHMI = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -130,6 +135,7 @@ export default class VuotoPrincipale extends Vue {
|
|||||||
{
|
{
|
||||||
if(this.recipe.vacuum_main_3_chart_setpointx.setpointHMI <= 0){
|
if(this.recipe.vacuum_main_3_chart_setpointx.setpointHMI <= 0){
|
||||||
this.recipe.vacuum_main_2_chart_setpointx.setpointHMI = this.recipe.vacuum_main_max_time.setpointHMI - this.recipe.vacuum_main_1_chart_setpointx.setpointHMI;
|
this.recipe.vacuum_main_2_chart_setpointx.setpointHMI = this.recipe.vacuum_main_max_time.setpointHMI - this.recipe.vacuum_main_1_chart_setpointx.setpointHMI;
|
||||||
|
this.recipe.vacuum_main_3_chart_setpointx.setpointHMI = 0;
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
diff = this.recipe.vacuum_main_max_time.setpointHMI -
|
diff = this.recipe.vacuum_main_max_time.setpointHMI -
|
||||||
|
|||||||
+2
-2
@@ -27,8 +27,8 @@ export default class outputRow extends Vue {
|
|||||||
async force(value: number) {
|
async force(value: number) {
|
||||||
if(!this.item.isForced && (this.item.forcedValue === undefined || value != this.item.forcedValue))
|
if(!this.item.isForced && (this.item.forcedValue === undefined || value != this.item.forcedValue))
|
||||||
{
|
{
|
||||||
ModalHelper.AskConfirm( this.$options.filters.localize("Richiesta di conferma","modal_confirm_title"),
|
ModalHelper.AskConfirm( this.$options.filters.localize("modal_confirm_title", "Richiesta di conferma"),
|
||||||
this.$options.filters.localize("Confirm?","softkey_confirm"),
|
this.$options.filters.localize("softkey_confirm", "Confirm?"),
|
||||||
async() => {
|
async() => {
|
||||||
await underTheHoodService.forceChannel(this.group, this.item, value);
|
await underTheHoodService.forceChannel(this.group, this.item, value);
|
||||||
}, null, "modal");
|
}, null, "modal");
|
||||||
|
|||||||
+31
-2
@@ -2,8 +2,37 @@ import { Component, Vue } from "vue-property-decorator";
|
|||||||
import Header from "../../../header/my-header.vue";
|
import Header from "../../../header/my-header.vue";
|
||||||
import MenuSx from "../../../menu-sx/menu-sx.vue";
|
import MenuSx from "../../../menu-sx/menu-sx.vue";
|
||||||
import LogMisurazioniTable from "../../../LogMisurazioni/components/tables/log-misurazioni-table/log-misurazioni-table.vue";
|
import LogMisurazioniTable from "../../../LogMisurazioni/components/tables/log-misurazioni-table/log-misurazioni-table.vue";
|
||||||
|
import { awaiter, messageService } from "@/_base";
|
||||||
|
import { CustomPagination } from "@/components/pagination";
|
||||||
|
import { Watch } from "vue-property-decorator";
|
||||||
|
import { underTheHoodService } from "@/services/underTheHoodService";
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
components: { Header, MenuSx, LogMisurazioniTable }
|
components: { Header, MenuSx, LogMisurazioniTable,CustomPagination }
|
||||||
})
|
})
|
||||||
export default class LogMisurazioni extends Vue {}
|
export default class LogMisurazioni extends Vue {
|
||||||
|
|
||||||
|
currentPage: number = 0;
|
||||||
|
itemsPerPage: number = 10;
|
||||||
|
totalPages: number = 1;
|
||||||
|
|
||||||
|
rowData = [];
|
||||||
|
|
||||||
|
async mounted(){
|
||||||
|
this.reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Watch("currentPage", { deep: true })
|
||||||
|
async getLogs(){
|
||||||
|
var from = ((this.currentPage) * 10);
|
||||||
|
this.rowData = (await awaiter(underTheHoodService.GetHistorySheetsFitered(from,this.itemsPerPage)));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
async reload(){
|
||||||
|
this.currentPage = 0;
|
||||||
|
this.totalPages = await awaiter(underTheHoodService.GetHistorySheetsCount()) / this.itemsPerPage;
|
||||||
|
this.getLogs();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|||||||
+13
-1
@@ -1,6 +1,18 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="column-page-one-column">
|
<div class="column-page-one-column">
|
||||||
<LogMisurazioniTable></LogMisurazioniTable>
|
<LogMisurazioniTable :rowData="rowData"></LogMisurazioniTable>
|
||||||
|
<div class="menu">
|
||||||
|
<div class="load">
|
||||||
|
<custom-pagination
|
||||||
|
v-model="currentPage"
|
||||||
|
:items-per-page="itemsPerPage"
|
||||||
|
:total-pages="totalPages"
|
||||||
|
></custom-pagination>
|
||||||
|
</div>
|
||||||
|
<div class="toReload">
|
||||||
|
<button class="btn" @click="reload()"><i class="fa fa-refresh"></i></button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<style lang="less">
|
<style lang="less">
|
||||||
|
|||||||
+28
@@ -0,0 +1,28 @@
|
|||||||
|
.main-container th,
|
||||||
|
.main-container td {
|
||||||
|
padding: 0 5px;
|
||||||
|
}
|
||||||
|
.main-container th.left,
|
||||||
|
.main-container td.left {
|
||||||
|
text-align: end;
|
||||||
|
}
|
||||||
|
.main-container th.lastre-date,
|
||||||
|
.main-container td.lastre-date {
|
||||||
|
width: 20%;
|
||||||
|
}
|
||||||
|
.main-container th.lastre-recipe,
|
||||||
|
.main-container td.lastre-recipe {
|
||||||
|
width: 20%;
|
||||||
|
}
|
||||||
|
.main-container th.lastre-numpezzo,
|
||||||
|
.main-container td.lastre-numpezzo {
|
||||||
|
width: 10%;
|
||||||
|
}
|
||||||
|
.main-container th.lastre-type,
|
||||||
|
.main-container td.lastre-type {
|
||||||
|
width: 20%;
|
||||||
|
}
|
||||||
|
.main-container th.lastre-value,
|
||||||
|
.main-container td.lastre-value {
|
||||||
|
width: 30%;
|
||||||
|
}
|
||||||
+15
-12
@@ -3,21 +3,24 @@
|
|||||||
.main-container {
|
.main-container {
|
||||||
th,
|
th,
|
||||||
td {
|
td {
|
||||||
&.misurazioni-value {
|
padding: 0 5px;
|
||||||
width: 322px;
|
&.left{
|
||||||
max-width: 322px;
|
text-align: end;
|
||||||
}
|
}
|
||||||
&.misurazioni-recipe {
|
&.lastre-date {
|
||||||
width: 539px;
|
width: 20%;
|
||||||
max-width: 539px;
|
|
||||||
}
|
}
|
||||||
&.misurazioni-date {
|
&.lastre-recipe {
|
||||||
width: 313px;
|
width: 20%;
|
||||||
max-width: 313px;
|
|
||||||
}
|
}
|
||||||
&.misurazioni-type {
|
&.lastre-numpezzo {
|
||||||
width: 187px;
|
width: 10%;
|
||||||
max-width: 187px;
|
}
|
||||||
|
&.lastre-type {
|
||||||
|
width: 20%;
|
||||||
|
}
|
||||||
|
&.lastre-value {
|
||||||
|
width: 30%;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+25
-75
@@ -1,83 +1,33 @@
|
|||||||
import { Component, Vue } from "vue-property-decorator";
|
import { Component, Vue } from "vue-property-decorator";
|
||||||
|
import { Prop } from "vue-property-decorator";
|
||||||
|
import moment from "moment";
|
||||||
|
|
||||||
@Component({})
|
@Component({})
|
||||||
export default class LogMisurazioniTable extends Vue {
|
export default class LogMisurazioniTable extends Vue {
|
||||||
rowData = [];
|
|
||||||
|
@Prop({ default: []})
|
||||||
|
rowData:any;
|
||||||
|
|
||||||
mounted() {
|
mounted() {
|
||||||
this.rowData = [
|
}
|
||||||
{
|
|
||||||
date: "2020-09-16 00:23:20 UTC",
|
convertDate(date) {
|
||||||
recipe: "Recipe name [30]",
|
return moment(date).format('L');
|
||||||
type: "Lenght",
|
}
|
||||||
value: "568.08 mm [589.92 mm - 21.84 mm]"
|
convertDateToTime(date) {
|
||||||
},
|
return moment(date).format('LTS');
|
||||||
{
|
}
|
||||||
date: "2020-09-16 00:23:20 UTC",
|
|
||||||
recipe: "Recipe name [30]",
|
convertType(item){
|
||||||
type: "Lenght",
|
if (!item || item == 0)
|
||||||
value: "568.08 mm [589.92 mm - 21.84 mm]"
|
return "ND"
|
||||||
},
|
else if (item == 1)
|
||||||
{
|
return "PALLET HEIGHT"
|
||||||
date: "2020-09-16 00:23:20 UTC",
|
else if (item == 2)
|
||||||
recipe: "Recipe name [30]",
|
return "SHEET THICKNESS"
|
||||||
type: "Lenght",
|
else if (item == 2)
|
||||||
value: "568.08 mm [589.92 mm - 21.84 mm]"
|
return "SHEET LENGTH"
|
||||||
},
|
else
|
||||||
{
|
return "ND"
|
||||||
date: "2020-09-16 00:23:20 UTC",
|
|
||||||
recipe: "Recipe name [30]",
|
|
||||||
type: "Lenght",
|
|
||||||
value: "568.08 mm [589.92 mm - 21.84 mm]"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
date: "2020-09-16 00:23:20 UTC",
|
|
||||||
recipe: "Recipe name [30]",
|
|
||||||
type: "Lenght",
|
|
||||||
value: "568.08 mm [589.92 mm - 21.84 mm]"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
date: "2020-09-16 00:23:20 UTC",
|
|
||||||
recipe: "Recipe name [30]",
|
|
||||||
type: "Lenght",
|
|
||||||
value: "568.08 mm [589.92 mm - 21.84 mm]"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
date: "2020-09-16 00:23:20 UTC",
|
|
||||||
recipe: "Recipe name [30]",
|
|
||||||
type: "Lenght",
|
|
||||||
value: "568.08 mm [589.92 mm - 21.84 mm]"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
date: "2020-09-16 00:23:20 UTC",
|
|
||||||
recipe: "Recipe name [30]",
|
|
||||||
type: "Lenght",
|
|
||||||
value: "568.08 mm [589.92 mm - 21.84 mm]"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
date: "2020-09-16 00:23:20 UTC",
|
|
||||||
recipe: "Recipe name [30]",
|
|
||||||
type: "Lenght",
|
|
||||||
value: "568.08 mm [589.92 mm - 21.84 mm]"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
date: "2020-09-16 00:23:20 UTC",
|
|
||||||
recipe: "Recipe name [30]",
|
|
||||||
type: "Lenght",
|
|
||||||
value: "568.08 mm [589.92 mm - 21.84 mm]"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
date: "2020-09-16 00:23:20 UTC",
|
|
||||||
recipe: "Recipe name [30]",
|
|
||||||
type: "Lenght",
|
|
||||||
value: "568.08 mm [589.92 mm - 21.84 mm]"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
date: "2020-09-16 00:23:20 UTC",
|
|
||||||
recipe: "Recipe name [30]",
|
|
||||||
type: "Lenght",
|
|
||||||
value: "568.08 mm [589.92 mm - 21.84 mm]"
|
|
||||||
}
|
|
||||||
];
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+14
-26
@@ -3,35 +3,23 @@
|
|||||||
<table>
|
<table>
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th class="misurazioni-date">Date</th>
|
<th class="lastre-date ">{{'underthehood_label_date' | localize("Date")}}</th>
|
||||||
<th class="misurazioni-recipe">Recipe</th>
|
<th class="lastre-recipe">{{'underthehood_label_recipe' | localize("Ricetta")}}</th>
|
||||||
<th class="misurazioni-type">Type</th>
|
<th class="lastre-numpezzo left">{{'underthehood_label_numpiece' | localize("N. Pezzo")}}</th>
|
||||||
<th class="misurazioni-value">Value</th>
|
<th class="lastre-type left">{{'underthehood_label_type' | localize("Type")}}</th>
|
||||||
|
<th class="lastre-value left">{{'underthehood_label_value' | localize("Value")}}</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody class="autocolor">
|
<tbody class="autocolor">
|
||||||
<tr v-for="(item, i) of rowData" :key="i" class="tr-inner">
|
<template v-for="(item, idx) in rowData">
|
||||||
<td>
|
<tr :key="`c-${idx}`">
|
||||||
<span>
|
<td>{{convertDate(item.dtEvent)}} - {{convertDateToTime(item.dtEvent)}}</td>
|
||||||
{{ item.date }}
|
<td>{{item.recipeName}}</td>
|
||||||
</span>
|
<td class="left">{{item.numDone}}</td>
|
||||||
</td>
|
<td class="left">{{convertType(item.typeVal)}}</td>
|
||||||
<td>
|
<td class="left">{{item.firstVal | round(1)}} [{{item.secondVal | round(1)}}, {{item.thirdVal | round(1)}}]</td>
|
||||||
<span>
|
</tr>
|
||||||
{{ item.recipe }}
|
</template>
|
||||||
</span>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<span>
|
|
||||||
{{ item.type }}
|
|
||||||
</span>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<span>
|
|
||||||
{{ item.value }}
|
|
||||||
</span>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
-1
@@ -14,7 +14,6 @@ export default class RiscaldiTable extends Vue {
|
|||||||
}
|
}
|
||||||
|
|
||||||
getChannelInfo(id) {
|
getChannelInfo(id) {
|
||||||
console.log(store.state.warmers.channels.filter(i => i.idChannel == 5)[0]);
|
|
||||||
return store.state.warmers.channels.filter(i => i.idChannel == id)[0];
|
return store.state.warmers.channels.filter(i => i.idChannel == id)[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -10,11 +10,11 @@
|
|||||||
@click="go('log-ciclo-automatico')"
|
@click="go('log-ciclo-automatico')"
|
||||||
:class="{white: this.value == 'log-ciclo-automatico'}"
|
:class="{white: this.value == 'log-ciclo-automatico'}"
|
||||||
>{{'underthehood_label_loga' | localize("Log ciclo automatico")}}</div>
|
>{{'underthehood_label_loga' | localize("Log ciclo automatico")}}</div>
|
||||||
<!-- <div
|
<div
|
||||||
class="rettangle"
|
class="rettangle"
|
||||||
@click="go('log-misurazioni')"
|
@click="go('log-misurazioni')"
|
||||||
:class="{white: this.value == 'log-misurazioni'}"
|
:class="{white: this.value == 'log-misurazioni'}"
|
||||||
>{{'underthehood_label_logm' | localize("Log misurazioni")}}</div>-->
|
>{{'underthehood_label_logm' | localize("Log misurazioni")}}</div>
|
||||||
<div
|
<div
|
||||||
class="rettangle"
|
class="rettangle"
|
||||||
@click="go('assi')"
|
@click="go('assi')"
|
||||||
|
|||||||
@@ -49,7 +49,8 @@ export class ModalHelper {
|
|||||||
};
|
};
|
||||||
public static modalImage = {
|
public static modalImage = {
|
||||||
content: null,
|
content: null,
|
||||||
title: null
|
title: null,
|
||||||
|
lastPhoto:null
|
||||||
};
|
};
|
||||||
public static maintenanceModal = {
|
public static maintenanceModal = {
|
||||||
currentMaintenance: null,
|
currentMaintenance: null,
|
||||||
|
|||||||
@@ -24,12 +24,6 @@ import "./app.business-logic";
|
|||||||
import "./app.modules";
|
import "./app.modules";
|
||||||
import { messageService } from "src/_base";
|
import { messageService } from "src/_base";
|
||||||
|
|
||||||
import { warmersService } from "./services/warmersService";
|
|
||||||
warmersService.GetChannels();
|
|
||||||
warmersService.GetResistances();
|
|
||||||
import { prodService } from "./services/prodService";
|
|
||||||
prodService.GetProd();
|
|
||||||
|
|
||||||
const App = () =>
|
const App = () =>
|
||||||
import("./App.vue");
|
import("./App.vue");
|
||||||
|
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ import { Factory, messageService } from "../../_base";
|
|||||||
import ZoomImage from './zoom-image.vue'
|
import ZoomImage from './zoom-image.vue'
|
||||||
import Vue from "vue";
|
import Vue from "vue";
|
||||||
import Component from "vue-class-component";
|
import Component from "vue-class-component";
|
||||||
|
import moment from "moment";
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
components:{
|
components:{
|
||||||
@@ -13,19 +14,24 @@ import Component from "vue-class-component";
|
|||||||
export default class ModalImage extends Vue {
|
export default class ModalImage extends Vue {
|
||||||
|
|
||||||
|
|
||||||
content: string = "";
|
content: string = "";
|
||||||
title: string = "";
|
title: string = "";
|
||||||
|
|
||||||
|
mounted() {
|
||||||
|
this.content = ModalHelper.modalImage.content;
|
||||||
|
this.title = ModalHelper.modalImage.title;
|
||||||
|
|
||||||
mounted() {
|
messageService.subscribeToChannel("new-thermocam-image", (args)=>{
|
||||||
this.content = ModalHelper.modalImage.content;
|
this.content = "/thermoprophet/original/_last.jpg?lastmod=" + args[0];
|
||||||
this.title = ModalHelper.modalImage.title;
|
this.title = moment(args[0]).format("L") + " - " + moment(args[0]).format("LTS");
|
||||||
}
|
});
|
||||||
|
|
||||||
beforeMount() {
|
}
|
||||||
messageService.subscribeToChannel("esc_pressed", args => {
|
|
||||||
this.close();
|
beforeMount() {
|
||||||
});
|
messageService.subscribeToChannel("esc_pressed", args => {
|
||||||
|
this.close();
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
beforeDestroy() {
|
beforeDestroy() {
|
||||||
@@ -34,7 +40,7 @@ export default class ModalImage extends Vue {
|
|||||||
|
|
||||||
close() {
|
close() {
|
||||||
messageService.deleteChannel("esc_pressed");
|
messageService.deleteChannel("esc_pressed");
|
||||||
ModalHelper.HideModal();
|
ModalHelper.HideModal("modal2");
|
||||||
}
|
}
|
||||||
|
|
||||||
};
|
};
|
||||||
@@ -1,8 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<modal type="modal-image" :title="title">
|
<modal type="modal-image" :title="title">
|
||||||
<button class="close" slot="header-buttons" @click="close()"><i class="fa fa-remove"></i></button>
|
<button class="close" slot="header-buttons" @click="close()"><i class="fa fa-remove"></i></button>
|
||||||
<zoom-image :imageSrc="this.content" :showBackButton="false" />
|
<zoom-image :imageSrc="this.content" :showBackButton="false" :isTcam="true"/>
|
||||||
</modal>
|
</modal>
|
||||||
</template>
|
</template>
|
||||||
<script src="./modal-image.ts" lang="ts" />
|
<script src="./modal-image.ts" lang="ts" />
|
||||||
<!--<script src="./create-maintenance.ts" lang="ts"></script>-->
|
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
import Vue from "vue";
|
import Vue from "vue";
|
||||||
import { Prop, Component } from "vue-property-decorator";
|
import { Prop, Component } from "vue-property-decorator";
|
||||||
|
import { warmersService } from "@/services/warmersService";
|
||||||
|
import { store } from '@/store';
|
||||||
|
|
||||||
@Component([])
|
@Component([])
|
||||||
export default class ZoomImage extends Vue {
|
export default class ZoomImage extends Vue {
|
||||||
@@ -9,6 +11,8 @@ export default class ZoomImage extends Vue {
|
|||||||
imageSrc: string;
|
imageSrc: string;
|
||||||
@Prop({ default: true })
|
@Prop({ default: true })
|
||||||
showBackButton: boolean;
|
showBackButton: boolean;
|
||||||
|
@Prop({ default: false })
|
||||||
|
isTcam: boolean;
|
||||||
|
|
||||||
transImage: string = "";
|
transImage: string = "";
|
||||||
scaleImage: number = 1;
|
scaleImage: number = 1;
|
||||||
@@ -40,6 +44,10 @@ export default class ZoomImage extends Vue {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
get thermocameraModeBTN(): boolean {
|
||||||
|
return (store.state.warmers.tCamStatus.thermoCamOnOff);
|
||||||
|
}
|
||||||
|
|
||||||
close() {
|
close() {
|
||||||
this.$emit("close");
|
this.$emit("close");
|
||||||
}
|
}
|
||||||
@@ -137,4 +145,9 @@ export default class ZoomImage extends Vue {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
async forceTakeImage() {
|
||||||
|
warmersService.TakeNewPhoto();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
};
|
};
|
||||||
@@ -7,14 +7,19 @@
|
|||||||
@touchstart="dw"
|
@touchstart="dw"
|
||||||
@touchmove="move"
|
@touchmove="move"
|
||||||
@dblclick="zoomPlusAnimated">
|
@dblclick="zoomPlusAnimated">
|
||||||
|
<img ref="imageChild" :style="{'transform':transImage,'transition':animation}" :src="imageSrc" v-on:load="onImageLoaded" >
|
||||||
<svg xmlns="http://www.w3.org/2000/svg" :style="{'transform':transImage}" v-html="imageSrc" version="1.1" width="100%" height="100%" viewBox="0 0 2000 1500" v-on:load="onImageLoaded"></svg>
|
<!-- <svg xmlns="http://www.w3.org/2000/svg" :style="{'transform':transImage}" v-html="imageSrc" version="1.1" width="100%" height="100%" viewBox="0 0 2000 1500" v-on:load="onImageLoaded"></svg>-->
|
||||||
</div>
|
</div>
|
||||||
<!-- <div class="loading" v-if="!imageLoaded"><i class="fa fa-circle-o-notch fa-spin"></i></div>-->
|
<div class="loading" v-if="!imageLoaded"><i class="fa fa-circle-o-notch fa-spin"></i></div>
|
||||||
|
|
||||||
<div class="btngroup_close" v-if="showBackButton">
|
<div class="btngroup_close" v-if="showBackButton">
|
||||||
<button @click="close"><i class="fa fa-chevron-left" ></i></button>
|
<button @click="close"><i class="fa fa-chevron-left" ></i></button>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="btngroup2" v-if="true">
|
||||||
|
<button @click="forceTakeImage()" :disabled="thermocameraModeBTN">
|
||||||
|
<img src="/assets/icons/png/takesnap.png" />
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
<div class="btngroup">
|
<div class="btngroup">
|
||||||
<button @click="zoomPlusAnimated"><i class="fa fa-search-plus" ></i></button>
|
<button @click="zoomPlusAnimated"><i class="fa fa-search-plus" ></i></button>
|
||||||
<div class="rangecontainer">
|
<div class="rangecontainer">
|
||||||
|
|||||||
@@ -113,6 +113,7 @@ export class Hub {
|
|||||||
|
|
||||||
// qui i NUOVI metodi NUOVI dal server (Recipe, gauges) da completare lato HUB
|
// qui i NUOVI metodi NUOVI dal server (Recipe, gauges) da completare lato HUB
|
||||||
this._hub.client.recipeFullData = Hub.recipeFullData;
|
this._hub.client.recipeFullData = Hub.recipeFullData;
|
||||||
|
this._hub.client.recipeFullDataInvalidSetpoint = Hub.recipeFullDataInvalidSetpoint;
|
||||||
this._hub.client.warmersData = Hub.warmersData;
|
this._hub.client.warmersData = Hub.warmersData;
|
||||||
this._hub.client.setpointHmiInvalid = Hub.setpointHmiInvalid;
|
this._hub.client.setpointHmiInvalid = Hub.setpointHmiInvalid;
|
||||||
this._hub.client.recipeOverData = Hub.recipeOverData;
|
this._hub.client.recipeOverData = Hub.recipeOverData;
|
||||||
@@ -124,8 +125,7 @@ export class Hub {
|
|||||||
this._hub.client.gaugeData = Hub.gaugeData;
|
this._hub.client.gaugeData = Hub.gaugeData;
|
||||||
this._hub.client.axisInfo = Hub.axisInfoData;
|
this._hub.client.axisInfo = Hub.axisInfoData;
|
||||||
this._hub.client.channelsIoVal = Hub.channelsIOUpdate;
|
this._hub.client.channelsIoVal = Hub.channelsIOUpdate;
|
||||||
|
this._hub.client.newThermoCamImage = Hub.newThermoCamImage;
|
||||||
|
|
||||||
|
|
||||||
this._hub.client.logout = this.logout;
|
this._hub.client.logout = this.logout;
|
||||||
|
|
||||||
@@ -140,20 +140,22 @@ export class Hub {
|
|||||||
|
|
||||||
$.connection.hub.disconnected(() => {
|
$.connection.hub.disconnected(() => {
|
||||||
Hub.manageServerStatus("disconnected");
|
Hub.manageServerStatus("disconnected");
|
||||||
console.log("SERVER CONNECTION: restart-connection")
|
|
||||||
setTimeout(function () {
|
setTimeout(function () {
|
||||||
$.connection.hub.start();
|
$.connection.hub.start({ transport: ['serverSentEvents'] });
|
||||||
// $.connection.hub.start({ transport: ['serverSentEvents'] });
|
|
||||||
}, 5000); // Restart connection after 5 seconds.
|
}, 5000); // Restart connection after 5 seconds.
|
||||||
});
|
});
|
||||||
$.connection.hub.stateChanged(async (state) => {
|
$.connection.hub.stateChanged(async (state) => {
|
||||||
if (state.newState == $.signalR.connectionState.connected) {
|
if (state.newState == $.signalR.connectionState.connected) {
|
||||||
|
try {
|
||||||
|
await scadaService.ListScada();
|
||||||
|
}
|
||||||
|
catch (err)
|
||||||
|
{ }
|
||||||
Hub.manageServerStatus("connected");
|
Hub.manageServerStatus("connected");
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
$.connection.hub.start();
|
$.connection.hub.start({ transport: ['serverSentEvents'] });
|
||||||
// $.connection.hub.start({ transport: ['serverSentEvents'] });
|
|
||||||
|
|
||||||
this.checkShowAxes();
|
this.checkShowAxes();
|
||||||
|
|
||||||
@@ -202,14 +204,17 @@ export class Hub {
|
|||||||
recipeActions.setCurrent(store, data, true);
|
recipeActions.setCurrent(store, data, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public static recipeFullDataInvalidSetpoint(data) {
|
||||||
|
recipeActions.setCurrent(store, data, false);
|
||||||
|
}
|
||||||
|
|
||||||
public static warmersData(data) {
|
public static warmersData(data) {
|
||||||
warmersActions.setChannels(store, data as { [id: number]: Warmers.IChannel });
|
warmersActions.setChannels(store, data as { [id: number]: Warmers.IChannel });
|
||||||
}
|
}
|
||||||
|
|
||||||
public static async setpointHmiInvalid(data) {
|
public static async setpointHmiInvalid(data) {
|
||||||
if (data) {
|
if (data) {
|
||||||
await recipeService.GetCurrent();
|
|
||||||
await warmersService.GetChannels();
|
|
||||||
await warmersService.GetThermocameraStatus();
|
await warmersService.GetThermocameraStatus();
|
||||||
// await recipeService.GetOverview();
|
// await recipeService.GetOverview();
|
||||||
}
|
}
|
||||||
@@ -219,6 +224,11 @@ export class Hub {
|
|||||||
recipeActions.setOverview(store, data);
|
recipeActions.setOverview(store, data);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public static newThermoCamImage(data) {
|
||||||
|
messageService.publishToChannel("new-thermocam-image", data);
|
||||||
|
}
|
||||||
|
|
||||||
public static prodPanelData(data) {
|
public static prodPanelData(data) {
|
||||||
prodActions.setProdPanel(store, data);
|
prodActions.setProdPanel(store, data);
|
||||||
}
|
}
|
||||||
@@ -227,6 +237,8 @@ export class Hub {
|
|||||||
prodActions.setProd(store, data);
|
prodActions.setProd(store, data);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public updateAuthToken() {
|
public updateAuthToken() {
|
||||||
// Set or update authorization token
|
// Set or update authorization token
|
||||||
let authData = JSON.parse(window.localStorage.getItem("authorizationData") || window.sessionStorage.getItem("authorizationData")) as AuthToken;
|
let authData = JSON.parse(window.localStorage.getItem("authorizationData") || window.sessionStorage.getItem("authorizationData")) as AuthToken;
|
||||||
@@ -239,6 +251,7 @@ export class Hub {
|
|||||||
$.connection.hub.qs.CmsClientId = cmsClient.getClientID;
|
$.connection.hub.qs.CmsClientId = cmsClient.getClientID;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private logout(e) {
|
private logout(e) {
|
||||||
if (e)
|
if (e)
|
||||||
appModelActions.CheckLogoff(store, e.id);
|
appModelActions.CheckLogoff(store, e.id);
|
||||||
@@ -369,7 +382,6 @@ export class Hub {
|
|||||||
var toast = document.querySelector('#serverConnection') as any;
|
var toast = document.querySelector('#serverConnection') as any;
|
||||||
(iziToast as any).hide(toast);
|
(iziToast as any).hide(toast);
|
||||||
Hub._serverConnectionNotificationVisible = false;
|
Hub._serverConnectionNotificationVisible = false;
|
||||||
try { await scadaService.ListScada(); } catch (err) { }
|
|
||||||
messageService.publishToChannel("force-ui-update", null);
|
messageService.publishToChannel("force-ui-update", null);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -43,6 +43,17 @@ export class UnderTheHoodService extends baseRestService {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
async GetHistorySheetsCount() {
|
||||||
|
let result = await this.Get<number>((await this.BASE_URL()) + "/api/underthehood/SheetHistoryCount", true);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
async GetHistorySheetsFitered(from,num) {
|
||||||
|
let result = await this.Get<number>((await this.BASE_URL()) + `/api/underthehood/SheetHistoryFiltered?start=${from}&number=${num}`, true);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export const underTheHoodService = new UnderTheHoodService();
|
export const underTheHoodService = new UnderTheHoodService();
|
||||||
@@ -71,10 +71,14 @@ export class WarmersService extends baseRestService {
|
|||||||
let result = await this.Get<{
|
let result = await this.Get<{
|
||||||
imageSize: { x: number, y: number },
|
imageSize: { x: number, y: number },
|
||||||
rangeTemperature: { max: number, min: number },
|
rangeTemperature: { max: number, min: number },
|
||||||
|
thermoCamConnected: boolean,
|
||||||
|
thermoOptionActive: boolean,
|
||||||
|
lastTakenImage: Date,
|
||||||
}>((await this.BASE_URL()) + "TCamData", true);
|
}>((await this.BASE_URL()) + "TCamData", true);
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
async GetMeasurePoints(setname: string): Promise<any> {
|
async GetMeasurePoints(setname: string): Promise<any> {
|
||||||
return await this.Get<any>((await this.BASE_URL()) + `getMeasurePoints?setName=${setname}`, true);
|
return await this.Get<any>((await this.BASE_URL()) + `getMeasurePoints?setName=${setname}`, true);
|
||||||
}
|
}
|
||||||
@@ -86,5 +90,10 @@ export class WarmersService extends baseRestService {
|
|||||||
async ResetMeasurePoints() {
|
async ResetMeasurePoints() {
|
||||||
return this.Put((await this.BASE_URL()) + `resetMeasurePoint`, null, true);
|
return this.Put((await this.BASE_URL()) + `resetMeasurePoint`, null, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
async TakeNewPhoto() {
|
||||||
|
return this.Put((await this.BASE_URL()) + `TakeTcamImage`, null, true);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
export const warmersService = new WarmersService();
|
export const warmersService = new WarmersService();
|
||||||
Reference in New Issue
Block a user