From d58aae4e619eafd4ae5a76b0c92dec6ab8dd56ea Mon Sep 17 00:00:00 2001 From: = Date: Thu, 1 Oct 2020 11:00:19 +0200 Subject: [PATCH] fix conferma ricetta --- .../setup/ciclo/components/show-ciclo-info.ts | 7 +++--- .../components/show-controstampo-info.ts | 7 +++--- .../components/show-estrazione-info.ts | 7 +++--- .../formato/components/show-formato-info.ts | 7 +++--- .../setup/imbutitura/show-imbutitura-info.ts | 7 +++--- .../setup/opzioni/show-opzioni-info.ts | 25 ++++++++++--------- .../components/show-pirometro-info.ts | 7 +++--- .../components/show-quote-velocita-info.ts | 7 +++--- .../components/show-raffreddamento-info.ts | 7 +++--- .../riscaldi/components/show-riscaldi-info.ts | 7 +++--- .../setup/vuoto/show-vuoto-info.ts | 7 +++--- 11 files changed, 53 insertions(+), 42 deletions(-) diff --git a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/ciclo/components/show-ciclo-info.ts b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/ciclo/components/show-ciclo-info.ts index b950ffef..e118e791 100644 --- a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/ciclo/components/show-ciclo-info.ts +++ b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/ciclo/components/show-ciclo-info.ts @@ -83,9 +83,10 @@ export default class ShowCicloInfo extends Vue { hasChanges() { let result = false; - for (const key in this.payload) { - const el = this.payload[key] as Recipe.IValue; - if (el.setpointHMI != el.setpointPLC) result = true; + for (const key in this.recipe) { + const el = this.recipe[key] as Recipe.IValue; + if (el.status.visible && el.status.enabled) + if (el.setpointHMI != el.setpointPLC) result = true; } for (const key in store.state.warmers.channels) { const el = store.state.warmers.channels[key]; diff --git a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/controstampo_setup/components/show-controstampo-info.ts b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/controstampo_setup/components/show-controstampo-info.ts index 42cce6eb..36df83d3 100644 --- a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/controstampo_setup/components/show-controstampo-info.ts +++ b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/controstampo_setup/components/show-controstampo-info.ts @@ -98,9 +98,10 @@ export default class ShowControstampoInfo extends Vue { hasChanges() { let result = false; - for (const key in this.payload) { - const el = this.payload[key] as Recipe.IValue; - if (el.setpointHMI != el.setpointPLC) result = true; + for (const key in this.recipe) { + const el = this.recipe[key] as Recipe.IValue; + if (el.status.visible && el.status.enabled) + if (el.setpointHMI != el.setpointPLC) result = true; } for (const key in store.state.warmers.channels) { const el = store.state.warmers.channels[key]; diff --git a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/estrazione/components/show-estrazione-info.ts b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/estrazione/components/show-estrazione-info.ts index 236b0e2c..c946062a 100644 --- a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/estrazione/components/show-estrazione-info.ts +++ b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/estrazione/components/show-estrazione-info.ts @@ -70,9 +70,10 @@ export default class ShowEstrazioneInfo extends Vue { hasChanges() { let result = false; - for (const key in this.payload) { - const el = this.payload[key] as Recipe.IValue; - if (el.setpointHMI != el.setpointPLC) result = true; + for (const key in this.recipe) { + const el = this.recipe[key] as Recipe.IValue; + if (el.status.visible && el.status.enabled) + if (el.setpointHMI != el.setpointPLC) result = true; } for (const key in store.state.warmers.channels) { const el = store.state.warmers.channels[key]; diff --git a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/formato/components/show-formato-info.ts b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/formato/components/show-formato-info.ts index 49125a92..dd99fba3 100644 --- a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/formato/components/show-formato-info.ts +++ b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/formato/components/show-formato-info.ts @@ -97,9 +97,10 @@ export default class ShowFormatoInfo extends Vue { hasChanges() { let result = false; - for (const key in this.payload) { - const el = this.payload[key] as Recipe.IValue; - if (el.setpointHMI != el.setpointPLC) result = true; + for (const key in this.recipe) { + const el = this.recipe[key] as Recipe.IValue; + if (el.status.visible && el.status.enabled) + if (el.setpointHMI != el.setpointPLC) result = true; } for (const key in store.state.warmers.channels) { const el = store.state.warmers.channels[key]; diff --git a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/imbutitura/show-imbutitura-info.ts b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/imbutitura/show-imbutitura-info.ts index 1c9f7262..4a2610e8 100644 --- a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/imbutitura/show-imbutitura-info.ts +++ b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/imbutitura/show-imbutitura-info.ts @@ -79,9 +79,10 @@ export default class ShowImbutituraInfo extends Vue { hasChanges() { let result = false; - for (const key in this.payload) { - const el = this.payload[key] as Recipe.IValue; - if (el.setpointHMI != el.setpointPLC) result = true; + for (const key in this.recipe) { + const el = this.recipe[key] as Recipe.IValue; + if (el.status.visible && el.status.enabled) + if (el.setpointHMI != el.setpointPLC) result = true; } for (const key in store.state.warmers.channels) { const el = store.state.warmers.channels[key]; diff --git a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/opzioni/show-opzioni-info.ts b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/opzioni/show-opzioni-info.ts index b87508a8..ff7637bc 100644 --- a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/opzioni/show-opzioni-info.ts +++ b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/opzioni/show-opzioni-info.ts @@ -42,25 +42,25 @@ export default class ShowOpzioniInfo extends Vue { this.debouncedRecipeSave() }; - thermoregolatoriAreVisible(){ - for(var i = 1; i<= 10; i++){ - if(this.recipe['options_thermoregulator_'+i+'_enabled'] && this.recipe['options_thermoregulator_'+i+'_enabled'].status.visible) + thermoregolatoriAreVisible() { + for (var i = 1; i <= 10; i++) { + if (this.recipe['options_thermoregulator_' + i + '_enabled'] && this.recipe['options_thermoregulator_' + i + '_enabled'].status.visible) return true; } return false; } - sottosquadraStampoAreVisible(){ - for(var i = 1; i<= 10; i++){ - if(this.recipe['options_undercutmould_'+i+'_mode'] && this.recipe['options_undercutmould_'+i+'_mode'].status.visible) + sottosquadraStampoAreVisible() { + for (var i = 1; i <= 10; i++) { + if (this.recipe['options_undercutmould_' + i + '_mode'] && this.recipe['options_undercutmould_' + i + '_mode'].status.visible) return true; } return false; } - sottosquadraControstampoAreVisible(){ - for(var i = 1; i<= 10; i++){ - if(this.recipe['options_undercutupperplate_'+i+'_mode'] && this.recipe['options_undercutupperplate_'+i+'_mode'].status.visible) + sottosquadraControstampoAreVisible() { + for (var i = 1; i <= 10; i++) { + if (this.recipe['options_undercutupperplate_' + i + '_mode'] && this.recipe['options_undercutupperplate_' + i + '_mode'].status.visible) return true; } return false; @@ -186,9 +186,10 @@ export default class ShowOpzioniInfo extends Vue { hasChanges() { let result = false; - for (const key in this.payload) { - const el = this.payload[key] as Recipe.IValue; - if (el.setpointHMI != el.setpointPLC) result = true; + for (const key in this.recipe) { + const el = this.recipe[key] as Recipe.IValue; + if (el.status.visible && el.status.enabled) + if (el.setpointHMI != el.setpointPLC) result = true; } for (const key in store.state.warmers.channels) { const el = store.state.warmers.channels[key]; diff --git a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/pirometro/components/show-pirometro-info.ts b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/pirometro/components/show-pirometro-info.ts index 65ec72b6..e6ddac73 100644 --- a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/pirometro/components/show-pirometro-info.ts +++ b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/pirometro/components/show-pirometro-info.ts @@ -79,9 +79,10 @@ export default class ShowPirometroInfo extends Vue { hasChanges() { let result = false; - for (const key in this.payload) { - const el = this.payload[key] as Recipe.IValue; - if (el.setpointHMI != el.setpointPLC) result = true; + for (const key in this.recipe) { + const el = this.recipe[key] as Recipe.IValue; + if (el.status.visible && el.status.enabled) + if (el.setpointHMI != el.setpointPLC) result = true; } for (const key in store.state.warmers.channels) { const el = store.state.warmers.channels[key]; diff --git a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/quote-velocita/components/show-quote-velocita-info.ts b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/quote-velocita/components/show-quote-velocita-info.ts index b206c5ed..bcce14a7 100644 --- a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/quote-velocita/components/show-quote-velocita-info.ts +++ b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/quote-velocita/components/show-quote-velocita-info.ts @@ -93,9 +93,10 @@ export default class ShowQuoteVelocitaInfo extends Vue { hasChanges() { let result = false; - for (const key in this.payload) { - const el = this.payload[key] as Recipe.IValue; - if (el.setpointHMI != el.setpointPLC) result = true; + for (const key in this.recipe) { + const el = this.recipe[key] as Recipe.IValue; + if (el.status.visible && el.status.enabled) + if (el.setpointHMI != el.setpointPLC) result = true; } for (const key in store.state.warmers.channels) { const el = store.state.warmers.channels[key]; diff --git a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/raffreddamento/components/show-raffreddamento-info.ts b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/raffreddamento/components/show-raffreddamento-info.ts index d85132fb..f662f581 100644 --- a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/raffreddamento/components/show-raffreddamento-info.ts +++ b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/raffreddamento/components/show-raffreddamento-info.ts @@ -102,9 +102,10 @@ export default class Raffreddamento extends Vue { hasChanges() { let result = false; - for (const key in this.payload) { - const el = this.payload[key] as Recipe.IValue; - if (el.setpointHMI != el.setpointPLC) result = true; + for (const key in this.recipe) { + const el = this.recipe[key] as Recipe.IValue; + if (el.status.visible && el.status.enabled) + if (el.setpointHMI != el.setpointPLC) result = true; } for (const key in store.state.warmers.channels) { const el = store.state.warmers.channels[key]; diff --git a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/riscaldi/components/show-riscaldi-info.ts b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/riscaldi/components/show-riscaldi-info.ts index 3f09b917..5593c076 100644 --- a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/riscaldi/components/show-riscaldi-info.ts +++ b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/riscaldi/components/show-riscaldi-info.ts @@ -76,9 +76,10 @@ export default class ShowRiscaldamentoSuperioreInfo extends Vue { hasChanges() { let result = false; - for (const key in this.payload) { - const el = this.payload[key] as Recipe.IValue; - if (el.setpointHMI != el.setpointPLC) result = true; + for (const key in this.recipe) { + const el = this.recipe[key] as Recipe.IValue; + if (el.status.visible && el.status.enabled) + if (el.setpointHMI != el.setpointPLC) result = true; } for (const key in store.state.warmers.channels) { const el = store.state.warmers.channels[key]; diff --git a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/vuoto/show-vuoto-info.ts b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/vuoto/show-vuoto-info.ts index 4586bd15..fbd1b9f5 100644 --- a/Thermo.Active/wwwroot/src/app_modules_thermo/setup/vuoto/show-vuoto-info.ts +++ b/Thermo.Active/wwwroot/src/app_modules_thermo/setup/vuoto/show-vuoto-info.ts @@ -96,9 +96,10 @@ export default class ShowVuotoInfo extends Vue { hasChanges() { let result = false; - for (const key in this.payload) { - const el = this.payload[key] as Recipe.IValue; - if (el.setpointHMI != el.setpointPLC) result = true; + for (const key in this.recipe) { + const el = this.recipe[key] as Recipe.IValue; + if (el.status.visible && el.status.enabled) + if (el.setpointHMI != el.setpointPLC) result = true; } for (const key in store.state.warmers.channels) { const el = store.state.warmers.channels[key];