Compare commits
19 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 2bb407d55c | |||
| 97dc1095b6 | |||
| a090ef9fb2 | |||
| c5c95f75ae | |||
| c95fb1806f | |||
| d12d07c99e | |||
| 3103b7bba2 | |||
| b2932d927c | |||
| 68add4e08d | |||
| 5585c11ef5 | |||
| b9caa4ac74 | |||
| cde514eed8 | |||
| fad45a5635 | |||
| 9bf2265082 | |||
| e488619ae5 | |||
| babd8b25da | |||
| 5894cd63ce | |||
| 5a19d44b34 | |||
| 577cbe5c9d |
@@ -180,7 +180,7 @@
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
|
||||
<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>
|
||||
<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'))" />
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
<ncVendor>S7NET</ncVendor>
|
||||
<!-- NO_NC/DEMO/FANUC/SIEMENS/OSAI/S7NET -->
|
||||
<showNcHMI>false</showNcHMI>
|
||||
<!--<ncIpAddress>192.168.139.1</ncIpAddress>-->
|
||||
<ncIpAddress>192.168.0.102</ncIpAddress>
|
||||
<ncPort>102</ncPort>
|
||||
<machineModel>Thermo 2020</machineModel>
|
||||
@@ -140,7 +141,7 @@
|
||||
<thread name="expMan" value="30000" />
|
||||
<thread name="functionEnab" value="300" />
|
||||
<thread name="gauges" value="500" />
|
||||
<thread name="m154" value="500" />
|
||||
<thread name="m154" value="1000" />
|
||||
<thread name="mCommands" value="250" />
|
||||
<thread name="powerOn" value="500" />
|
||||
<thread name="prodCycle" value="1000" />
|
||||
|
||||
@@ -38,10 +38,6 @@
|
||||
<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" />
|
||||
</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>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -57,10 +57,6 @@
|
||||
<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" />
|
||||
</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>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -37,8 +37,10 @@ namespace Thermo.Active.Database.Controllers
|
||||
private const string machineMessagePath = "Events:Messages";
|
||||
|
||||
|
||||
private const string thermoSemRecipe = "Thermo:Semaphore:Recipe";
|
||||
private const string thermoSemWarmers = "Thermo:Semaphore:Warmers";
|
||||
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)
|
||||
{
|
||||
|
||||
@@ -475,10 +475,16 @@ namespace Thermo.Active.NC
|
||||
// solo x S7...
|
||||
if (NcConfig.NcVendor == NC_VENDOR.S7NET)
|
||||
{
|
||||
// registro in redis blocco x lettura ricetta...
|
||||
RedisController.setRecipeReadSem(true);
|
||||
|
||||
// call NC for update
|
||||
CmsError libraryError = numericalControl.PLC_WRecipeEdit(confirmUpdate);
|
||||
if (libraryError.IsError())
|
||||
return libraryError;
|
||||
|
||||
// tolgo blocco x lettura ricetta...
|
||||
RedisController.setRecipeReadSem(false);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -1764,10 +1770,16 @@ namespace Thermo.Active.NC
|
||||
{
|
||||
if (NcFileAdapter.RecipeLiveData.ChannelSetpoints != null)
|
||||
{
|
||||
// registro in redis blocco x lettura ricetta...
|
||||
RedisController.setRecipeReadSem(true);
|
||||
|
||||
// se si in questo caso scrivo configurazione...
|
||||
WriteRecipeWarmConfig();
|
||||
// Ack !
|
||||
libraryError = numericalControl.PLC_WAckConfRiskRequest();
|
||||
|
||||
// tolgo in redis blocco x lettura ricetta...
|
||||
RedisController.setRecipeReadSem(false);
|
||||
}
|
||||
}
|
||||
if (ThermoReqConfRecipeStr)
|
||||
@@ -1795,8 +1807,12 @@ namespace Thermo.Active.NC
|
||||
return NOT_FOUND_ERROR;
|
||||
}
|
||||
}
|
||||
// registro in redis blocco x lettura ricetta...
|
||||
RedisController.setRecipeReadSem(true);
|
||||
// se si in questo caso scrivo configurazione attuale...
|
||||
WriteRecipeParams(updtRecipe, nMaxParamWrite, delayParamWrite);
|
||||
// tolgo in redis blocco x lettura ricetta...
|
||||
RedisController.setRecipeReadSem(false);
|
||||
|
||||
using (UserSoftkeysController controller = new UserSoftkeysController())
|
||||
{
|
||||
@@ -1813,6 +1829,9 @@ namespace Thermo.Active.NC
|
||||
newRisk.Add(item.Key, item.Value);
|
||||
}
|
||||
|
||||
// registro in redis blocco x lettura ricetta...
|
||||
RedisController.setRecipeReadSem(true);
|
||||
|
||||
// write to PLC SetPointHMI (%)
|
||||
libraryError = WriteRecipeWarmChSetpHMI(newRisk);
|
||||
if (libraryError.IsError())
|
||||
@@ -1827,6 +1846,9 @@ namespace Thermo.Active.NC
|
||||
libraryError = ConfirmRecipeData(true);
|
||||
if (libraryError.IsError())
|
||||
return libraryError;
|
||||
|
||||
// tolgo in redis blocco x lettura ricetta...
|
||||
RedisController.setRecipeReadSem(true);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -2577,7 +2599,7 @@ namespace Thermo.Active.NC
|
||||
|
||||
using (HistorySheetsController HSC = new HistorySheetsController())
|
||||
{
|
||||
HSC.Create(NcFileAdapter.RecipeLiveData.RecipeName, prodInfoData.NumDone, (float) sheetRaw.Value1, (float) sheetRaw.Value2, (float) sheetRaw.Value3,sheetRaw.TypeVal);
|
||||
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();
|
||||
@@ -3421,8 +3443,14 @@ namespace Thermo.Active.NC
|
||||
/// <returns></returns>
|
||||
public CmsError SetTCamActiv(bool enableTCam)
|
||||
{
|
||||
// registro in redis blocco x lettura ricetta...
|
||||
RedisController.setWarmersReadSem(true);
|
||||
|
||||
CmsError libraryError = numericalControl.PLC_WTCamActiv(enableTCam);
|
||||
|
||||
// tolgo in redis blocco x lettura ricetta...
|
||||
RedisController.setWarmersReadSem(false);
|
||||
|
||||
return libraryError;
|
||||
}
|
||||
|
||||
@@ -3433,8 +3461,14 @@ namespace Thermo.Active.NC
|
||||
/// <returns></returns>
|
||||
public CmsError SetTCamMode(bool enableTCam)
|
||||
{
|
||||
// registro in redis blocco x lettura ricetta...
|
||||
RedisController.setWarmersReadSem(true);
|
||||
|
||||
CmsError libraryError = numericalControl.PLC_WTCamMode(enableTCam);
|
||||
|
||||
// tolgo in redis blocco x lettura ricetta...
|
||||
RedisController.setWarmersReadSem(false);
|
||||
|
||||
return libraryError;
|
||||
}
|
||||
|
||||
|
||||
@@ -38,10 +38,6 @@
|
||||
<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" />
|
||||
</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>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -38,10 +38,6 @@
|
||||
<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" />
|
||||
</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>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -115,10 +115,6 @@
|
||||
<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" />
|
||||
</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>
|
||||
</runtime>
|
||||
<connectionStrings>
|
||||
|
||||
@@ -326,6 +326,10 @@ namespace Thermo.Active.Listeners.SignalR
|
||||
lastSetpointHmiInvalid = currMessage;
|
||||
var context = GlobalHost.ConnectionManager.GetHubContext<NcHub>();
|
||||
context.Clients.Group("ncData").setpointHmiInvalid(currMessage);
|
||||
|
||||
context.Clients.Group("ncData").recipeFullDataInvalidSetpoint(LastRecipeFullData);
|
||||
context.Clients.Group("ncData").warmersData(LastWarmersData);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -686,7 +690,7 @@ namespace Thermo.Active.Listeners.SignalR
|
||||
// Send THERMO Recipe data
|
||||
group.recipeFullData(LastRecipeFullData);
|
||||
group.recipeOverData(LastRecipeOverData);
|
||||
group.setpointHmiInvalid();
|
||||
|
||||
// Send THERMO Modules data
|
||||
group.modulesData(LastModulesData);
|
||||
// Send THERMO Warmers data
|
||||
@@ -696,6 +700,8 @@ namespace Thermo.Active.Listeners.SignalR
|
||||
group.gaugeData(LastLiveProdData);
|
||||
// THERMO prod info data
|
||||
group.prodInfoData(LastProdInfoData);
|
||||
|
||||
group.prodPanelData(LastProdPanelData);
|
||||
// THERMO prod cycle data
|
||||
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
|
||||
// by using the '*' as shown below:
|
||||
[assembly: AssemblyVersion("1.1.187")]
|
||||
[assembly: AssemblyVersion("1.1.192")]
|
||||
|
||||
@@ -3578,11 +3578,14 @@
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
&:active{
|
||||
background-image: linear-gradient(to bottom,#002680, #1756ad);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
button:disabled {
|
||||
background-color: #002680 !important;
|
||||
;
|
||||
filter: grayscale(100%);
|
||||
}
|
||||
|
||||
|
||||
@@ -3758,6 +3758,9 @@ article .box .body {
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
.imageViewerZoom button:active {
|
||||
background-image: linear-gradient(to bottom, #002680, #1756ad);
|
||||
}
|
||||
.imageViewerZoom button:disabled {
|
||||
background-color: #002680 !important;
|
||||
filter: grayscale(100%);
|
||||
|
||||
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 * as iziToast from "izitoast";
|
||||
import { underTheHoodService } from "./services/underTheHoodService";
|
||||
import { warmersService } from "./services/warmersService";
|
||||
|
||||
// import { UsersService } from "./services/usersService";
|
||||
|
||||
@@ -60,7 +61,6 @@ async function loadMachineConfig() {
|
||||
|
||||
await loginService.getUserInfo();
|
||||
|
||||
|
||||
try {
|
||||
let machine = new machineService();
|
||||
let result = await machine.getAreasConfiguration();
|
||||
@@ -68,12 +68,12 @@ async function loadMachineConfig() {
|
||||
|
||||
let mcresult = await machine.getMachineConfiguration();
|
||||
machineStatusActions.setWarmersParameters(store, mcresult.additionalParameters);
|
||||
|
||||
await prodService.GetProdPanel();
|
||||
await warmersService.GetResistances();
|
||||
|
||||
await underTheHoodService.getChannels();
|
||||
await underTheHoodService.getChannelsConfig();
|
||||
|
||||
|
||||
// load default language
|
||||
if (!(store.state as AppModel).localization.currentLanguage) {
|
||||
localizationService.changeCurrentLanguage(mcresult.defaultLanguage);
|
||||
|
||||
@@ -130,8 +130,6 @@ export default class Dashboard extends Vue {
|
||||
}
|
||||
|
||||
async mounted() {
|
||||
prodService.GetProdPanel();
|
||||
|
||||
let $this = this;
|
||||
setInterval(() => {
|
||||
$this.now = moment();
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<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>
|
||||
<g>
|
||||
|
||||
+12
-6
@@ -35,6 +35,11 @@ export default class Thermocamera extends Vue {
|
||||
timeoutLastTakenImage = 0;
|
||||
timeCamDiff = " ";
|
||||
|
||||
tcamBTNStatus:{
|
||||
enabled: boolean,
|
||||
visible: boolean
|
||||
} = {enabled : false, visible: true};
|
||||
|
||||
TCamData: {
|
||||
imageSize: { x: number, y: number },
|
||||
rangeTemperature: { max: number, min: number },
|
||||
@@ -45,12 +50,10 @@ export default class Thermocamera extends Vue {
|
||||
|
||||
@Watch("warmers", { deep: true })
|
||||
async ChangedTemps() {
|
||||
|
||||
|
||||
this.btnModeEnabled = false;
|
||||
this.tcamBTNStatus.enabled = false;
|
||||
for (const ch of store.state.warmers.channels) {
|
||||
if (ch.tCamTempSet > 0) {
|
||||
this.btnModeEnabled = true;
|
||||
if (ch.tCamTempSet > 0 && ch.tCamActive) {
|
||||
this.tcamBTNStatus.enabled = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -239,7 +242,10 @@ export default class Thermocamera extends Vue {
|
||||
}
|
||||
|
||||
async openImageModal() {
|
||||
ModalHelper.modalImage.title = moment(this.TCamData.lastTakenImage).format("L") + " - " + moment(this.TCamData.lastTakenImage).format("LTS");
|
||||
|
||||
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");
|
||||
}
|
||||
|
||||
+3
-3
@@ -79,7 +79,7 @@
|
||||
|
||||
<div class="input-area grid left">
|
||||
<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 class="input-area left grid">
|
||||
@@ -125,7 +125,7 @@
|
||||
</div>
|
||||
|
||||
<div class="tm-controls">
|
||||
<button class="btn btn-info square" @click="forceTakeImage()">
|
||||
<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()">
|
||||
@@ -148,7 +148,7 @@
|
||||
</div>
|
||||
|
||||
<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>
|
||||
</button>
|
||||
<button class="btn btn-info square icon" @click="zoomReset()">
|
||||
|
||||
+1
-1
@@ -24,7 +24,7 @@ export default class LogMisurazioniTable extends Vue {
|
||||
else if (item == 1)
|
||||
return "PALLET HEIGHT"
|
||||
else if (item == 2)
|
||||
return "SHEET TICKNESS"
|
||||
return "SHEET THICKNESS"
|
||||
else if (item == 2)
|
||||
return "SHEET LENGTH"
|
||||
else
|
||||
|
||||
@@ -24,12 +24,6 @@ import "./app.business-logic";
|
||||
import "./app.modules";
|
||||
import { messageService } from "src/_base";
|
||||
|
||||
import { warmersService } from "./services/warmersService";
|
||||
warmersService.GetChannels();
|
||||
warmersService.GetResistances();
|
||||
import { prodService } from "./services/prodService";
|
||||
prodService.GetProd();
|
||||
|
||||
const App = () =>
|
||||
import("./App.vue");
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@ export default class ModalImage extends Vue {
|
||||
|
||||
content: string = "";
|
||||
title: string = "";
|
||||
|
||||
|
||||
mounted() {
|
||||
this.content = ModalHelper.modalImage.content;
|
||||
this.title = ModalHelper.modalImage.title;
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import Vue from "vue";
|
||||
import { Prop, Component } from "vue-property-decorator";
|
||||
import { warmersService } from "@/services/warmersService";
|
||||
import { store } from '@/store';
|
||||
|
||||
@Component([])
|
||||
export default class ZoomImage extends Vue {
|
||||
@@ -43,6 +44,10 @@ export default class ZoomImage extends Vue {
|
||||
}
|
||||
|
||||
|
||||
get thermocameraModeBTN(): boolean {
|
||||
return (store.state.warmers.tCamStatus.thermoCamOnOff);
|
||||
}
|
||||
|
||||
close() {
|
||||
this.$emit("close");
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<button @click="close"><i class="fa fa-chevron-left" ></i></button>
|
||||
</div>
|
||||
<div class="btngroup2" v-if="true">
|
||||
<button @click="forceTakeImage()">
|
||||
<button @click="forceTakeImage()" :disabled="thermocameraModeBTN">
|
||||
<img src="/assets/icons/png/takesnap.png" />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -113,6 +113,7 @@ export class Hub {
|
||||
|
||||
// qui i NUOVI metodi NUOVI dal server (Recipe, gauges) da completare lato HUB
|
||||
this._hub.client.recipeFullData = Hub.recipeFullData;
|
||||
this._hub.client.recipeFullDataInvalidSetpoint = Hub.recipeFullDataInvalidSetpoint;
|
||||
this._hub.client.warmersData = Hub.warmersData;
|
||||
this._hub.client.setpointHmiInvalid = Hub.setpointHmiInvalid;
|
||||
this._hub.client.recipeOverData = Hub.recipeOverData;
|
||||
@@ -139,20 +140,22 @@ export class Hub {
|
||||
|
||||
$.connection.hub.disconnected(() => {
|
||||
Hub.manageServerStatus("disconnected");
|
||||
console.log("SERVER CONNECTION: restart-connection")
|
||||
setTimeout(function () {
|
||||
$.connection.hub.start();
|
||||
// $.connection.hub.start({ transport: ['serverSentEvents'] });
|
||||
$.connection.hub.start({ transport: ['serverSentEvents'] });
|
||||
}, 5000); // Restart connection after 5 seconds.
|
||||
});
|
||||
$.connection.hub.stateChanged(async (state) => {
|
||||
if (state.newState == $.signalR.connectionState.connected) {
|
||||
try {
|
||||
await scadaService.ListScada();
|
||||
}
|
||||
catch (err)
|
||||
{ }
|
||||
Hub.manageServerStatus("connected");
|
||||
}
|
||||
})
|
||||
|
||||
$.connection.hub.start();
|
||||
// $.connection.hub.start({ transport: ['serverSentEvents'] });
|
||||
$.connection.hub.start({ transport: ['serverSentEvents'] });
|
||||
|
||||
this.checkShowAxes();
|
||||
|
||||
@@ -201,14 +204,17 @@ export class Hub {
|
||||
recipeActions.setCurrent(store, data, true);
|
||||
}
|
||||
|
||||
|
||||
public static recipeFullDataInvalidSetpoint(data) {
|
||||
recipeActions.setCurrent(store, data, false);
|
||||
}
|
||||
|
||||
public static warmersData(data) {
|
||||
warmersActions.setChannels(store, data as { [id: number]: Warmers.IChannel });
|
||||
}
|
||||
|
||||
public static async setpointHmiInvalid(data) {
|
||||
if (data) {
|
||||
await recipeService.GetCurrent();
|
||||
await warmersService.GetChannels();
|
||||
await warmersService.GetThermocameraStatus();
|
||||
// await recipeService.GetOverview();
|
||||
}
|
||||
@@ -231,6 +237,8 @@ export class Hub {
|
||||
prodActions.setProd(store, data);
|
||||
}
|
||||
|
||||
|
||||
|
||||
public updateAuthToken() {
|
||||
// Set or update authorization token
|
||||
let authData = JSON.parse(window.localStorage.getItem("authorizationData") || window.sessionStorage.getItem("authorizationData")) as AuthToken;
|
||||
@@ -243,6 +251,7 @@ export class Hub {
|
||||
$.connection.hub.qs.CmsClientId = cmsClient.getClientID;
|
||||
}
|
||||
|
||||
|
||||
private logout(e) {
|
||||
if (e)
|
||||
appModelActions.CheckLogoff(store, e.id);
|
||||
@@ -373,7 +382,6 @@ export class Hub {
|
||||
var toast = document.querySelector('#serverConnection') as any;
|
||||
(iziToast as any).hide(toast);
|
||||
Hub._serverConnectionNotificationVisible = false;
|
||||
try { await scadaService.ListScada(); } catch (err) { }
|
||||
messageService.publishToChannel("force-ui-update", null);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user