Compare commits

...

110 Commits

Author SHA1 Message Date
Samuele Locatelli c45c81dbf7 Merge branch 'bugfix/calcoloStatus' into develop 2020-09-02 14:05:57 +02:00
Samuele Locatelli 7417c20dcc Fix gestione (si spera) status overview 2020-09-02 13:26:16 +02:00
Samuele Locatelli a98500bade Aggiunta preliminare readme.md 2020-09-02 12:22:42 +02:00
Samuele Locatelli 154897e835 start new release 2020-09-02 11:47:46 +02:00
Samuele Locatelli 587f4b3e82 new vers numb 2020-09-02 11:41:03 +02:00
Samuele Locatelli 8714898228 Eliminato dati perturbati grafico prod 2020-09-02 11:40:21 +02:00
Samuele Locatelli 49ccfe10e7 Merge remote-tracking branch 'origin/develop' into develop 2020-09-02 11:32:14 +02:00
Samuele Locatelli 1168c826c1 Eliminazione transports.log 2020-09-02 11:31:51 +02:00
= 4c5f1e975f fix 2020-09-01 16:04:20 +02:00
= 4a5d0b9770 saveas notes 2020-09-01 16:03:31 +02:00
= 1e4dc168ac save notes 2020-09-01 15:34:22 +02:00
= d2fd9675fd header menu 2020-09-01 11:15:56 +02:00
= 9440a01ff7 numeric 2020-08-31 17:00:04 +02:00
= 968dab090d fix velocità di aggiornamento slider tramite tasti. 2020-08-31 16:10:39 +02:00
= b47975c7f6 conferma annulla 2020-08-31 10:58:12 +02:00
= cc9527fbad Merge remote-tracking branch 'CMS/develop' into develop 2020-08-31 10:30:17 +02:00
= 208b2122ac toggle disabled 2020-08-31 10:24:07 +02:00
Samuele E. Locatelli 4dde0de70a fix gestione forcing rilettura status overview 2020-08-31 10:15:02 +02:00
Samuele Locatelli d3f65680e9 Merge branch 'develop' into feature/recipe 2020-08-27 16:55:00 +02:00
Samuele Locatelli 4879979ae6 fix x core library + new rel 2020-08-27 16:54:38 +02:00
= a379fc96d3 kwh 2020-08-27 16:42:25 +02:00
Samuele Locatelli a1fd3ec363 update x calcolo modifiche ed errori su parametri SEMPRE calcolati 2020-08-27 15:39:39 +02:00
Samuele Locatelli 22b5b3453b Merge remote-tracking branch 'origin/develop' into develop 2020-08-27 15:31:01 +02:00
= 06d83de1df toggle-button visibility + enabled status 2020-08-26 11:18:12 +02:00
= 828701c865 fix layout riscaldi 2020-08-26 11:11:22 +02:00
= 5dc96371ce fix packages 2020-08-26 11:11:12 +02:00
= 3ce95c81dd babel upgrade 2020-08-26 11:05:58 +02:00
NICOLA CARMINATI 1f7d34327c Fix styled parts 2020-08-25 11:51:36 +02:00
Samuele Locatelli 8aadb503ec start new rel vers 2020-08-07 17:23:48 +02:00
Samuele Locatelli e7f221376f Merge remote-tracking branch 'origin/develop' into develop 2020-08-07 15:01:12 +02:00
Samuele Locatelli d4d26408ad Fix log recipe confirm error 2020-08-07 14:59:30 +02:00
= 3e6b9390da Merge remote-tracking branch 'CMS/develop' into develop 2020-08-07 12:21:55 +02:00
= a03fe6c7c7 softkey slider 2020-08-07 12:21:22 +02:00
= 90d3e33f2b fix save recipe 2020-08-07 12:02:26 +02:00
= 3388520048 riferimento traduzioni correnti 2020-08-07 11:57:52 +02:00
= b938239572 fix quote stampo 2020-08-07 10:24:40 +02:00
Samuele Locatelli 71fb94f59b check errori divers: debug(SIM) / release(PROD) 2020-07-29 19:31:40 +02:00
Samuele Locatelli b78cbfc38a FIx calcolo errori: SOLO parametri visibili... 2020-07-29 14:17:51 +02:00
Samuele Locatelli 3403836f7e Merge branch 'develop' of https://bitbucket.org/ncarminati/cms_thermo_active into develop 2020-07-29 10:13:34 +02:00
Samuele Locatelli f0dc2333fb New release, fix strobe race condition 2020-07-29 10:13:00 +02:00
= 4fafa3a791 fix posizione toggle riscaldi superiori inferiori 2020-07-29 09:17:59 +02:00
Samuele Locatelli 3564f0cb72 Merge branch 'develop' of https://bitbucket.org/ncarminati/cms_thermo_active into develop 2020-07-29 08:19:36 +02:00
NICOLA CARMINATI 6b1bf6f94b Merge branch 'develop' of https://bitbucket.org/ncarminati/cms_thermo_active into develop 2020-07-28 17:36:23 +02:00
NICOLA CARMINATI d2f8c7f893 Fix disabled softkey 2020-07-28 17:34:01 +02:00
= 7f3ad3dbd9 Merge remote-tracking branch 'CMS/develop' into develop 2020-07-28 10:25:15 +02:00
= 01c42162d0 toggle & conferma disabilitato 2020-07-28 10:24:55 +02:00
= 8afcaf8f6f Merge remote-tracking branch 'CMS/develop' into develop 2020-07-28 10:09:24 +02:00
= 54573c76b1 toggle & combo 2020-07-28 09:41:58 +02:00
Samuele Locatelli 5900f2b9d9 new release 2020-07-28 09:08:18 +02:00
Samuele Locatelli 821b7accbd Fix calcolo IchMin x resistenze 2+ 2020-07-28 09:08:06 +02:00
Samuele Locatelli f6bc7e4ef4 Merge in new rel 2020-07-27 16:43:49 +02:00
Samuele Locatelli 0e35c3da9e Merge branch 'develop' of https://bitbucket.org/ncarminati/cms_thermo_active into feature/recipe 2020-07-27 16:43:08 +02:00
Samuele Locatelli d48d6e7925 Correazione formula IchMin 2020-07-27 16:42:04 +02:00
NICOLA CARMINATI b91a18b434 Merge branch 'develop' of https://bitbucket.org/ncarminati/cms_thermo_active into develop 2020-07-27 16:29:39 +02:00
NICOLA CARMINATI abaf3a4794 General fixes 2020-07-27 16:11:25 +02:00
Samuele Locatelli dbc2777bcd Merge branch 'develop' into feature/recipe 2020-07-27 14:33:06 +02:00
Samuele Locatelli 7ee0cdb5a6 new rel 2020-07-27 14:32:56 +02:00
Samuele Locatelli 69f1398d9a fix out usersoftkeys 2020-07-27 14:32:18 +02:00
Samuele Locatelli b707c4a2f5 Merge branch 'develop' into feature/recipe 2020-07-27 10:51:51 +02:00
Samuele Locatelli f741a39644 Added Operator Confirmation in starred softkey 2020-07-27 10:42:51 +02:00
Samuele Locatelli 6624c6b219 Start new rel con nuovo XML softkey 2020-07-27 08:22:11 +02:00
Samuele Locatelli 2819c901f1 new release 2020-07-24 11:18:05 +02:00
= 30ac1496e2 fix autorizzazioni e info di processo 2020-07-24 09:36:27 +02:00
= 2bbd500360 gantt animations 2020-07-23 19:16:39 +02:00
= d887dc7d48 Merge remote-tracking branch 'CMS/develop' into develop 2020-07-23 18:22:46 +02:00
= be669f66f1 revert login 2020-07-23 18:22:30 +02:00
Samuele Locatelli 5c96a2c9f1 Merge branch 'develop' into feature/recipe 2020-07-23 17:59:59 +02:00
Samuele Locatelli d4cc3a8877 new release 2020-07-23 17:59:46 +02:00
Samuele Locatelli d79d883224 Merge branch 'develop' of https://bitbucket.org/ncarminati/cms_thermo_active into develop 2020-07-23 17:58:51 +02:00
= 2e646b0547 fix softkeys 2020-07-23 17:51:20 +02:00
Samuele Locatelli 578351fbcc update min rev 2020-07-23 17:43:39 +02:00
= a1b5bbb9ef posizione tastiera & windows buttons 2020-07-23 17:26:05 +02:00
= 88095c418b fix step slider e riscaldi 2020-07-23 17:03:34 +02:00
= 866ae7c089 gantt positioning 2020-07-23 16:33:07 +02:00
= 5166e8db62 Merge remote-tracking branch 'CMS/develop' into develop 2020-07-23 14:27:16 +02:00
= ededb27d80 .window-buttons + processinfo + gantt 2020-07-23 14:26:42 +02:00
= 7ff75037f7 dashboard e processo 2020-07-23 14:18:01 +02:00
Samuele Locatelli bd350e15e4 Merge branch 'feature/recipe' into develop 2020-07-23 12:12:17 +02:00
Samuele Locatelli 10d3e8e958 Added PPStatus + cleanup M155 & PP data 2020-07-23 12:12:05 +02:00
Samuele Locatelli fe5ea382b9 Acquired forced process status 2020-07-23 09:17:49 +02:00
Samuele Locatelli 7992723cba new release 2020-07-23 08:00:52 +02:00
Samuele Locatelli 5e22af4625 update labels 2020-07-23 07:50:23 +02:00
Samuele Locatelli 393768fe7c Merge branch 'develop' of https://bitbucket.org/ncarminati/cms_thermo_active into develop 2020-07-22 19:04:48 +02:00
Samuele Locatelli 34edd6839e New Rel vers 2020-07-22 19:04:39 +02:00
= 0ef9a38073 manual/auto 2020-07-22 18:50:48 +02:00
= cb6271562b Merge remote-tracking branch 'CMS/develop' into develop 2020-07-22 18:33:26 +02:00
= 060a78964d fix starred softkeys 2020-07-22 18:32:51 +02:00
Samuele Locatelli 9159864ef2 Merge branch 'develop' of https://bitbucket.org/ncarminati/cms_thermo_active into develop 2020-07-22 18:24:09 +02:00
NICOLA CARMINATI 4f863b71f0 Added file-info .RCP 2020-07-22 18:18:58 +02:00
= c0edbdbd2f fix paddle starred & dashboard 2020-07-22 18:07:44 +02:00
NICOLA CARMINATI b893a9f2e0 Fix delete cache-folder on startup 2020-07-22 16:53:09 +02:00
= 71f4192bba fix posizinone card riscaldi 2020-07-22 16:43:45 +02:00
Samuele Locatelli ffadf07aaf Merge branch 'develop' of https://bitbucket.org/ncarminati/cms_thermo_active into feature/recipe 2020-07-22 14:11:20 +02:00
Samuele Locatelli 0648f53c94 Fix base address for iChMin 2020-07-22 14:10:34 +02:00
Samuele Locatelli d4e917cce2 Update install script 2020-07-22 13:18:55 +02:00
Samuele Locatelli 895914fd24 Added script for PROD deploy 2020-07-22 12:38:33 +02:00
Samuele Locatelli bc5fde0844 Fix labels & Fix conf userSoftKeys 2020-07-22 10:46:10 +02:00
= b9f82cb6f0 starred ? 2020-07-22 10:33:52 +02:00
= cc6ba8f0ef Merge remote-tracking branch 'CMS/develop' into develop 2020-07-22 09:39:34 +02:00
= 772aa06eb9 softkeys 2020-07-22 09:39:00 +02:00
Samuele Locatelli 2399cd0a9d Merge branch 'develop' into feature/recipe 2020-07-22 09:02:08 +02:00
Samuele Locatelli 35d0e05908 start new release cycle 2020-07-22 09:01:56 +02:00
Samuele Locatelli a057bb115e Merge branch 'develop' of https://bitbucket.org/ncarminati/cms_thermo_active into feature/recipe 2020-07-21 17:46:16 +02:00
Samuele Locatelli fa9a477a88 Fix decoding of softkey new data 2020-07-21 17:46:03 +02:00
Samuele Locatelli 0f23124a17 traduzione nuova label 2020-07-21 17:32:28 +02:00
Samuele Locatelli d2e728abf5 Modifica XML/XSD per gesiotne NUOVA info softkeys 2020-07-21 17:32:17 +02:00
= ecf740044d Merge remote-tracking branch 'CMS/develop' into develop 2020-07-21 16:46:25 +02:00
Samuele Locatelli 0341d98a95 Start new vers 2020-07-21 16:20:58 +02:00
= a88560e0c1 fix inversione quote 2020-07-21 14:33:55 +02:00
= 30a104854c fix inversione quote 2020-07-21 14:30:53 +02:00
139 changed files with 5663 additions and 3652 deletions
+1 -1
View File
@@ -12,7 +12,7 @@
<ServerUrl>localhost</ServerUrl>
<ServerPort>9000</ServerPort>
<Id>1</Id>
<DeleteCahceFolderOnStartup>false</DeleteCahceFolderOnStartup>
<DeleteCahceFolderOnStartup>true</DeleteCahceFolderOnStartup>
</Connection>
<VendorHmi>
<FollowNcWindow>True</FollowNcWindow>
+29 -8
View File
@@ -36,13 +36,14 @@ namespace Active_Client.Browser_Tools
private MainForm mainForm;
private static readonly string[] _validExtensions = { "", ".json", ".rcp", ".tpl" };
private static readonly string[] _validExtensions = {".json", ".rcp", ".tpl" };
//private static readonly string[] _validExtensions = { "", ".txt", ".cnc", ".cn", ".cno", ".ini", ".mpf", ".spf", ".tap", ".anc", ".iso" };
private static readonly string[] _validImages = { ".jpg", ".jpeg", ".png" };
private static string jobPath = "";
private static Dictionary<string, IntPtr> _editorOpened = new Dictionary<string, IntPtr>();
private static EditorVar _currentEditorObject = new EditorVar();
public static string RECENT_FOLDER_KEY = "RECENT";
public static string RECENT_FOLDER_KEY = "RECENT";
private const string THERMO_RECIPE_PATH = @"C:\CMS\Recipes";
public static FileSystemWatcher watcher = null;
public static DateTime _lastTimeFileWatcherEventRaised = DateTime.Now;
@@ -384,6 +385,16 @@ namespace Active_Client.Browser_Tools
Type = "SPFO"
});
if (Directory.Exists(THERMO_RECIPE_PATH))
{
drivelist.Add(new Drive()
{
Name = ElaborateName("Recipes", "", DriveType.Unknown),
Path = THERMO_RECIPE_PATH + "\\",
Type = "SPFO"
});
}
try
{
// Network Folders
@@ -689,16 +700,26 @@ namespace Active_Client.Browser_Tools
imagePath = Path.GetFileNameWithoutExtension(p);
imageDirectory = Path.GetDirectoryName(p);
file.Content = new List<string>();
file.SheetX = "";
file.SheetY = "";
file.SheetZ = "";
file.Annotation = "";
try
{
StreamReader fileRead = new StreamReader(p);
while ((line = fileRead.ReadLine()) != null && counter < 10)
dynamic content = JsonConvert.DeserializeObject(File.ReadAllText(p));
if(content != null && content.RecipeParameters != null)
{
file.Content.Add(line);
counter++;
if(content.RecipeParameters.general_sizes_sheet_dim_x != null)
file.SheetX = content.RecipeParameters.general_sizes_sheet_dim_x;
if (content.RecipeParameters.general_sizes_sheet_dim_y != null)
file.SheetY = content.RecipeParameters.general_sizes_sheet_dim_y;
if (content.RecipeParameters.general_sizes_sheet_thickness != null)
file.SheetZ = content.RecipeParameters.general_sizes_sheet_thickness;
if (content.recipeNotes != null)
file.Annotation = content.recipeNotes;
}
fileRead.Close();
foreach (string ext in _validImages)
{
+5 -1
View File
@@ -9,7 +9,11 @@ namespace Active_Client.Browser_Tools.Models
public String AbsolutePath;
public DateTime CreationDate;
public DateTime LastModDate;
public List<String> Content;
public String SheetX;
public String SheetY;
public String SheetZ;
public String Annotation;
public Boolean CanEdit;
public string PreviewBase64;
}
+13
View File
@@ -179,6 +179,19 @@ namespace Active_Client
//Method called Before Cef Initialization
static void Chromium_OnBeforeCfxInitialize(OnBeforeCfxInitializeEventArgs e)
{
try
{
if (Config.ConnectionConfig.DeleteCahceFolderOnStartup && Directory.Exists(Constants.BROWSER_CACHE_FOLDER))
{
Directory.Delete(Constants.BROWSER_CACHE_FOLDER, true);
}
}
catch (Exception E)
{
ShowAlarmAndClose(E.Message);
}
e.Settings.WindowlessRenderingEnabled = true;
//Path Setup
+1 -30
View File
@@ -40,12 +40,7 @@ namespace Active_Client.View
LogoCMS.Visible = true;
LogoSCM.Visible = false;
}
//Setup The Browser
if (!SetupBrowser())
return;
//Set window Position
this.Location = new Point((Screen.PrimaryScreen.Bounds.Width / 2) - (this.Width / 2), (Screen.PrimaryScreen.Bounds.Height / 2) - (this.Height / 2));
}
@@ -164,30 +159,6 @@ namespace Active_Client.View
}
//Sub-Method used to SetupThe Browser Environment
private bool SetupBrowser()
{
//Delete Browser Cache
try
{
if (Config.ConnectionConfig.DeleteCahceFolderOnStartup && Directory.Exists(Constants.BROWSER_CACHE_FOLDER))
{
setStatus("Deleting Browser Chache Folder...", "");
Directory.Delete(Constants.BROWSER_CACHE_FOLDER, true);
}
}
catch (Exception E)
{
setStatus("Close the application!", E.Message);
return false;
}
return true;
}
//Sub-Method used to test the connection
private bool testConnection(Uri url, out Boolean error)
{
+16
View File
@@ -0,0 +1,16 @@
# Progetto Thermo.Active CMS
## Struttura Progetto
## Ambiente sviluppo e simulazione
## Procedura Riavvio su SIM
Step come indicati da M.Carissoni:
* Dai un paio di ResetSK
* fai cicloReset
* quando si spegne ciclo reset auto
* Inizia a lampeggiare start e lo clicchi e parte
* Quando si spegne cicloReset fai cicloAuto
@@ -552,17 +552,17 @@
"233": 0
},
"RecipeOverview": {
"General": "HasError",
"Positions": "HasError",
"Cycle": "ChangedOk",
"Heats": "ChangedOk",
"Pyrometer": "ChangedOk",
"Drawing": "ChangedOk",
"UpperPlate": "ChangedOk",
"Cooling": "HasError",
"Vacuum": "ChangedOk",
"Extraction": "ChangedOk",
"Options": "HasError"
"General": "Unchanged",
"Positions": "Unchanged",
"Cycle": "Unchanged",
"Heats": "Unchanged",
"Pyrometer": "Unchanged",
"Drawing": "Unchanged",
"UpperPlate": "Unchanged",
"Cooling": "Unchanged",
"Vacuum": "Unchanged",
"Extraction": "Unchanged",
"Options": "Unchanged"
},
"TC_last": 2532.940840175
}
+101 -28
View File
@@ -23,10 +23,9 @@
<lang langKey="it">Refresh allarmi</lang>
</localizedNames>
<visible>true</visible>
<starred>true</starred>
</softKey_procedure>
<softKey_toggle>
<softKey_procedure>
<active>false</active>
<category>3</category>
<operatorConfirmationNeeded>false</operatorConfirmationNeeded>
@@ -36,9 +35,9 @@
<lang langKey="it">Termoregolatori</lang>
</localizedNames>
<visible>true</visible>
</softKey_toggle>
</softKey_procedure>
<softKey_toggle>
<softKey_procedure>
<active>false</active>
<category>4</category>
<operatorConfirmationNeeded>false</operatorConfirmationNeeded>
@@ -48,9 +47,9 @@
<lang langKey="it">Portellone frontale</lang>
</localizedNames>
<visible>true</visible>
</softKey_toggle>
</softKey_procedure>
<softKey_toggle>
<softKey_procedure>
<active>true</active>
<category>5</category>
<operatorConfirmationNeeded>false</operatorConfirmationNeeded>
@@ -60,8 +59,7 @@
<lang langKey="it">Pausa ciclo</lang>
</localizedNames>
<visible>true</visible>
<starred>true</starred>
</softKey_toggle>
</softKey_procedure>
<softKey_procedure>
<active>true</active>
@@ -76,7 +74,7 @@
<starred>true</starred>
</softKey_procedure>
<softKey_toggle>
<softKey_procedure>
<active>true</active>
<category>7</category>
<operatorConfirmationNeeded>false</operatorConfirmationNeeded>
@@ -87,9 +85,22 @@
</localizedNames>
<visible>true</visible>
<starred>true</starred>
</softKey_toggle>
</softKey_procedure>
<softKey_toggle>
<softKey_procedure>
<active>true</active>
<category>7</category>
<operatorConfirmationNeeded>false</operatorConfirmationNeeded>
<plcId>8</plcId>
<localizedNames>
<lang langKey="en">Heaters Back</lang>
<lang langKey="it">Riscaldi indietro</lang>
</localizedNames>
<visible>true</visible>
<starred>true</starred>
</softKey_procedure>
<softKey_procedure>
<active>true</active>
<category>1</category>
<operatorConfirmationNeeded>false</operatorConfirmationNeeded>
@@ -99,7 +110,19 @@
<lang langKey="it">Pompe vuoto</lang>
</localizedNames>
<visible>true</visible>
</softKey_toggle>
</softKey_procedure>
<softKey_procedure>
<active>true</active>
<category>10</category>
<operatorConfirmationNeeded>true</operatorConfirmationNeeded>
<plcId>10</plcId>
<localizedNames>
<lang langKey="en">START Cycle</lang>
<lang langKey="it">START Ciclo</lang>
</localizedNames>
<visible>true</visible>
</softKey_procedure>
<softKey_procedure>
<active>true</active>
@@ -327,6 +350,8 @@
<lang langKey="it">Apertura cornice</lang>
</localizedNames>
<visible>true</visible>
<refCallParam>general_sizes_frame_dim_x</refCallParam>
<refCallLabel>general_sizes_frame_dim_x_button</refCallLabel>
</softKey_procedure>
<softKey_procedure>
@@ -339,6 +364,8 @@
<lang langKey="it">Profondità cornice</lang>
</localizedNames>
<visible>true</visible>
<refCallParam>general_sizes_frame_dim_y</refCallParam>
<refCallLabel>general_sizes_frame_dim_y_button</refCallLabel>
</softKey_procedure>
<softKey_procedure>
@@ -351,6 +378,8 @@
<lang langKey="it">Larghezza piastrafinestra</lang>
</localizedNames>
<visible>true</visible>
<refCallParam>general_sizes_plate_dim_x</refCallParam>
<refCallLabel>general_sizes_plate_dim_x_button</refCallLabel>
</softKey_procedure>
<softKey_procedure>
@@ -363,6 +392,8 @@
<lang langKey="it">Profondità piastrafinestra</lang>
</localizedNames>
<visible>true</visible>
<refCallParam>general_sizes_plate_dim_y</refCallParam>
<refCallLabel>general_sizes_plate_dim_y_button</refCallLabel>
</softKey_procedure>
<softKey_procedure>
@@ -377,22 +408,64 @@
<visible>true</visible>
</softKey_procedure>
<!--
<softKey_group>
<active>true</active>
<category>3</category>
<operatorConfirmationNeeded>false</operatorConfirmationNeeded>
<localizedNames>
<lang langKey="en">Brakes ON/FF:</lang>
<lang langKey="it">Freni ON/OFF</lang>
</localizedNames>
<subKeys>
<subKey active="true" plcId="50"> B </subKey>
<subKey active="true" plcId="51"> C </subKey>
</subKeys>
<visible>true</visible>
</softKey_group>
-->
<softKey_procedure>
<active>false</active>
<category>7</category>
<operatorConfirmationNeeded>false</operatorConfirmationNeeded>
<plcId>35</plcId>
<localizedNames>
<lang langKey="en">Loader Cycle Start</lang>
<lang langKey="it">Start Ciclo Caricatore</lang>
</localizedNames>
<visible>true</visible>
<refCallParam>cycle_loader_enable</refCallParam>
<refCallLabel>cycle_loader_enable_button</refCallLabel>
</softKey_procedure>
<softKey_procedure>
<active>true</active>
<category>1</category>
<operatorConfirmationNeeded>false</operatorConfirmationNeeded>
<plcId>36</plcId>
<localizedNames>
<lang langKey="en">Dashboard Setpoint Plus</lang>
<lang langKey="it">Dashboard Setpoint Plus</lang>
</localizedNames>
<visible>true</visible>
<refCallParam>dash_setpoint_plus</refCallParam>
<refCallLabel>dash_setpoint_plus_button</refCallLabel>
</softKey_procedure>
<softKey_procedure>
<active>true</active>
<category>1</category>
<operatorConfirmationNeeded>false</operatorConfirmationNeeded>
<plcId>37</plcId>
<localizedNames>
<lang langKey="en">Dashboard Setpoint Minus</lang>
<lang langKey="it">Dashboard Setpoint Minus</lang>
</localizedNames>
<visible>true</visible>
<refCallParam>dash_setpoint_minus</refCallParam>
<refCallLabel>dash_setpoint_minus_button</refCallLabel>
</softKey_procedure>
<!--softKey_group>
<active>true</active>
<category>1</category>
<operatorConfirmationNeeded>false</operatorConfirmationNeeded>
<localizedNames>
<lang langKey="en">aaa:</lang>
<lang langKey="it">aaa</lang>
</localizedNames>
<subKeys>
<subKey active="true" plcId="21"> B </subKey>
<subKey active="true" plcId="22"> C </subKey>
</subKeys>
<visible>true</visible>
</softKey_group-->
</userSoftKeys>
@@ -31,6 +31,8 @@
<xs:element name="active" minOccurs="1" maxOccurs="1" type="xs:boolean"></xs:element>
<xs:element name="visible" minOccurs="1" maxOccurs="1" type="xs:boolean"></xs:element>
<xs:element name="starred" minOccurs="0" type="xs:boolean"></xs:element>
<xs:element name="refCallLabel" minOccurs="0" type="xs:string"></xs:element>
<xs:element name="refCallParam" minOccurs="0" type="xs:string"></xs:element>
<xs:element name="category" type="xs:integer"></xs:element>
<xs:element name="operatorConfirmationNeeded" type="xs:boolean"></xs:element>
<xs:element name="localizedNames">
@@ -66,6 +68,8 @@
<xs:element name="active" minOccurs="1" maxOccurs="1" type="xs:boolean"></xs:element>
<xs:element name="visible" minOccurs="1" maxOccurs="1" type="xs:boolean"></xs:element>
<xs:element name="starred" minOccurs="0" type="xs:boolean"></xs:element>
<xs:element name="refCallLabel" minOccurs="0" type="xs:string"></xs:element>
<xs:element name="refCallParam" minOccurs="0" type="xs:string"></xs:element>
<xs:element name="category" type="xs:integer"></xs:element>
<xs:element name="operatorConfirmationNeeded" type="xs:boolean"></xs:element>
<xs:element name="localizedNames">
@@ -86,6 +90,8 @@
<xs:element name="active" minOccurs="1" maxOccurs="1" type="xs:boolean"></xs:element>
<xs:element name="visible" minOccurs="1" maxOccurs="1" type="xs:boolean"></xs:element>
<xs:element name="starred" minOccurs="0" type="xs:boolean"></xs:element>
<xs:element name="refCallLabel" minOccurs="0" type="xs:string"></xs:element>
<xs:element name="refCallParam" minOccurs="0" type="xs:string"></xs:element>
<xs:element name="category" type="xs:integer"></xs:element>
<xs:element name="operatorConfirmationNeeded" type="xs:boolean"></xs:element>
<xs:element name="localizedNames">
+11 -11
View File
@@ -552,17 +552,17 @@
"233": 0
},
"RecipeOverview": {
"General": "HasError",
"Positions": "HasError",
"Cycle": "ChangedOk",
"Heats": "ChangedOk",
"Pyrometer": "ChangedOk",
"Drawing": "ChangedOk",
"UpperPlate": "ChangedOk",
"Cooling": "HasError",
"Vacuum": "ChangedOk",
"Extraction": "ChangedOk",
"Options": "HasError"
"General": "Unchanged",
"Positions": "Unchanged",
"Cycle": "Unchanged",
"Heats": "Unchanged",
"Pyrometer": "Unchanged",
"Drawing": "Unchanged",
"UpperPlate": "Unchanged",
"Cooling": "Unchanged",
"Vacuum": "Unchanged",
"Extraction": "Unchanged",
"Options": "Unchanged"
},
"TC_last": 2532.940840175
}
@@ -518,6 +518,8 @@ namespace Thermo.Active.Config
IsActive = Convert.ToBoolean(x.Element("active").Value),
IsVisible = Convert.ToBoolean(x.Element("visible").Value),
IsStarred = x.Element("starred") != null ? Convert.ToBoolean(x.Element("starred").Value) : false,
RefCallLabel = x.Element("refCallLabel") != null ? x.Element("refCallLabel").Value : "",
RefCallParam = x.Element("refCallParam") != null ? x.Element("refCallParam").Value : "",
Category = Convert.ToInt32(x.Element("category").Value),
LocalizedNames = x.Element("localizedNames").Elements().ToDictionary( // Read localized names and convert into a dictionary
y => y.Attribute("langKey").Value, y => y.Value
@@ -760,13 +762,14 @@ namespace Thermo.Active.Config
SetpointThermo = 0,
MaxPower = riferimento.Potenza,
NumResist = 1,
CalcIchMin = riferimento.Modello.Contains("Quarzo") || riferimento.Modello.Contains("Alogena")
// 2020.07.27 applicato x tutti
CalcIchMin = true //riferimento.Modello.Contains("Quarzo") || riferimento.Modello.Contains("Alogena")
});
}
else
{
chanFound.NumResist += 1;
}
}
else
{
chanFound.NumResist += 1;
}
}
@@ -88,7 +88,7 @@
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="Config\userSoftKeyConfig.xml">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
<SubType>Designer</SubType>
</Content>
<EmbeddedResource Include="Config\userSoftKeyConfigValidator.xsd">
+2 -10
View File
@@ -318,16 +318,8 @@ public static class ThreadsFunctions
ManageLibraryError(libraryError);
else
{
libraryError = ncAdapter.GetM155Data(out List<DTOM155InputModel> m155Data);
if (libraryError.errorCode != 0)
ManageLibraryError(libraryError);
else
{
// Send processes through signalR
MessageServices.Current.Publish(SEND_PROCESSES_DATA, null, processesPPData);
// Send m155 through signalR
MessageServices.Current.Publish(SEND_M155_DATA, null, m155Data);
}
// Send processes through signalR
MessageServices.Current.Publish(SEND_PROCESSES_DATA, null, processesPPData);
}
}
else
+1 -1
View File
@@ -16,7 +16,7 @@ namespace Thermo.Active.Core
ThreadsFunctions.ReadAlarms,
ThreadsFunctions.ReadPowerOnData,
ThreadsFunctions.StatThread,
//ThreadsFunctions.ReadProcessesPPStatus,
ThreadsFunctions.ReadProcessesPPStatus,
ThreadsFunctions.ReadEnabledFunctionality,
ThreadsFunctions.ReadExpiredMaintenances,
//ThreadsFunctions.ReadAxesPositionsData,
@@ -46,6 +46,8 @@ namespace Thermo.Active.Database.Controllers
Id = softKey.Id,
Category = softKey.Category,
OperatorConfirmationNeeded = softKey.OperatorConfirmationNeeded,
RefCallLabel = softKey.RefCallLabel,
RefCallParam = softKey.RefCallParam,
Type = softKey.Type,
SubKeys = tmpSubKey
});
@@ -11,6 +11,8 @@ namespace Thermo.Active.Model.ConfigModels
public bool IsActive { get; set; }
public bool IsVisible { get; set; }
public bool IsStarred { get; set; } = false;
public string RefCallParam { get; set; } = "";
public string RefCallLabel { get; set; } = "";
public bool OperatorConfirmationNeeded { get; set; }
public List<SubKeysModel> SubKeys { get; set; }
public int PlcId { get; set; }
@@ -82,11 +82,11 @@ namespace Thermo.Active.Model.DTOModels
if (WorkOverride != item.WorkOverride)
return false;
if (offsetData.RealLength != item.offsetData.RealLength)
return false;
//if (offsetData.RealLength != item.offsetData.RealLength)
// return false;
if (offsetData.RealRadius != item.offsetData.RealRadius)
return false;
//if (offsetData.RealRadius != item.offsetData.RealRadius)
// return false;
if (FeedOverride != item.FeedOverride)
return false;
@@ -8,6 +8,8 @@ namespace Thermo.Active.Model.DTOModels
public int Id { get; set; }
public int Category { get; set; }
public bool OperatorConfirmationNeeded { get; set; }
public string RefCallParam { get; set; } = "";
public string RefCallLabel { get; set; } = "";
public SOFTKEY_TYPE Type { get; set; }
public Dictionary<int, string> SubKeys { get; set; }
}
@@ -20,6 +22,9 @@ namespace Thermo.Active.Model.DTOModels
public bool Visible { get; set; }
public bool Starred { get; set; } = false;
public bool Value { get; set; }
public bool OperatorConfirmationNeeded { get; set; }
public string RefCallParam { get; set; } = "";
public string RefCallLabel { get; set; } = "";
public override bool Equals(object obj)
{
@@ -34,6 +39,12 @@ namespace Thermo.Active.Model.DTOModels
return false;
if (Value != item.Value)
return false;
if (OperatorConfirmationNeeded != item.OperatorConfirmationNeeded)
return false;
if (RefCallParam != item.RefCallParam)
return false;
if (RefCallLabel != item.RefCallLabel)
return false;
return true;
}
@@ -43,4 +54,5 @@ namespace Thermo.Active.Model.DTOModels
return base.GetHashCode();
}
}
}
+48 -31
View File
@@ -636,6 +636,7 @@ namespace Thermo.Active.NC
}
}
#if false
// Read selected axes
libraryError = numericalControl.AXES_RSelectedAxis(ref processesData.SelectedAxis);
if (libraryError.IsError())
@@ -677,7 +678,8 @@ namespace Thermo.Active.NC
// Measure
processesData.UnitMeasure = UMeas;
processesData.FeedOverride = selectedData.FeedOverride;
processesData.FeedOverride = selectedData.FeedOverride;
#endif
return libraryError;
}
@@ -1011,6 +1013,9 @@ namespace Thermo.Active.NC
Id = subkey.Id,
Active = plcSoftKey.Active,
Starred = softKey.IsStarred,
RefCallParam = softKey.RefCallParam,
RefCallLabel = softKey.RefCallLabel,
OperatorConfirmationNeeded = softKey.OperatorConfirmationNeeded,
Category = softKey.Category,
Value = plcSoftKey.Value
});
@@ -1020,6 +1025,7 @@ namespace Thermo.Active.NC
{
Id = softKey.Id,
Category = softKey.Category,
OperatorConfirmationNeeded = softKey.OperatorConfirmationNeeded,
Visible = softKey.IsVisible
});
}
@@ -1032,6 +1038,9 @@ namespace Thermo.Active.NC
Id = softKey.Id,
Active = plcSoftKey.Active,
Starred = softKey.IsStarred,
RefCallParam = softKey.RefCallParam,
RefCallLabel = softKey.RefCallLabel,
OperatorConfirmationNeeded = softKey.OperatorConfirmationNeeded,
Category = softKey.Category,
Visible = softKey.IsVisible,
Value = plcSoftKey.Value
@@ -1071,6 +1080,9 @@ namespace Thermo.Active.NC
Id = subkey.Id,
Active = plcSoftKey.Active,
Starred = softKey.IsStarred,
RefCallParam = softKey.RefCallParam,
RefCallLabel = softKey.RefCallLabel,
OperatorConfirmationNeeded = softKey.OperatorConfirmationNeeded,
Category = softKey.Category,
Value = plcSoftKey.Value
});
@@ -1083,6 +1095,7 @@ namespace Thermo.Active.NC
{
Id = softKey.Id,
Category = softKey.Category,
OperatorConfirmationNeeded = softKey.OperatorConfirmationNeeded,
Visible = softKey.IsVisible
});
}
@@ -1098,6 +1111,9 @@ namespace Thermo.Active.NC
Id = softKey.Id,
Active = plcSoftKey.Active,
Starred = softKey.IsStarred,
RefCallParam = softKey.RefCallParam,
RefCallLabel = softKey.RefCallLabel,
OperatorConfirmationNeeded = softKey.OperatorConfirmationNeeded,
Category = softKey.Category,
Visible = softKey.IsVisible,
Value = plcSoftKey.Value
@@ -1127,6 +1143,9 @@ namespace Thermo.Active.NC
// Get current head config
var configuredHead = HeadsConfig.Find(x => x.Id == head.Id);
// Create different model according on type
// 2020.08.27 update core.library ha sminchionato --> commentato!
#if false
switch (configuredHead.Type)
{
case HEAD_TYPE.SPINDLE:
@@ -1174,7 +1193,8 @@ namespace Thermo.Active.NC
});
}
break;
}
}
#endif
}
return libraryError;
@@ -1423,31 +1443,6 @@ namespace Thermo.Active.NC
numTcOk++;
}
}
#if DEBUG
// creo una perturubazione...
var rand = new Random();
int slope = TS_TC.Count / 2;
Dictionary<int, double> origTcData = new Dictionary<int, double>();
foreach (var item2fix in TS_TC)
{
origTcData.Add(item2fix.Key, item2fix.Value);
}
foreach (var origVal in origTcData)
{
TS_TC[origVal.Key] = Math.Round(origVal.Value + (rand.NextDouble() * 20 - 10) + slope, 2);
slope--;
if (TS_Cad.ContainsKey(origVal.Key))
{
TS_Cad[origVal.Key] = Math.Round((double)3600 / TS_TC[origVal.Key], 2);
}
else
{
TS_Cad.Add(origVal.Key, Math.Round((double)3600 / TS_TC[origVal.Key], 2));
}
}
#endif
// accodo!
currentProdPanel.TS_Cadenza = TS_Cad;
currentProdPanel.TS_TCiclo = TS_TC;
@@ -2264,6 +2259,7 @@ namespace Thermo.Active.NC
CmsError libraryError = NO_ERROR;
// overview di base: ultima salvata...
currOverview = new Dictionary<RecipeSection, RecipeCatStatus>();
var err2fix = new Dictionary<RecipeSection, RecipeCatStatus>();
// leggo la ricetta dal PLC!
var currRecipe = new Dictionary<string, DTORecipeParam>();
@@ -2295,6 +2291,7 @@ namespace Thermo.Active.NC
currOverview = NcFileAdapter.RecipeLiveData.RecipeOverview;
}
// verifico eventualmente se mancasse qualcosa...
bool changed = false;
foreach (var item in recipeConfig)
{
@@ -2304,6 +2301,19 @@ namespace Thermo.Active.NC
changed = true;
}
}
// ricerco SE co fossero errori --> reset come changedOK
foreach (var item in currOverview)
{
if (item.Value == RecipeCatStatus.HasError)
err2fix.Add(item.Key, RecipeCatStatus.ChangedOk);
}
foreach (var item in err2fix)
{
currOverview[item.Key] = item.Value;
changed = true;
}
// se cambiato --> salvo in live data...
if (changed)
{
@@ -2323,8 +2333,15 @@ namespace Thermo.Active.NC
// altrimenti controllo
else
{
// se in errore --> registro...
if (currRecipe[item.Label].Status.HasError)
// se in errore AND visibile --> registro...
bool checkCondition = false;
#if DEBUG
checkCondition = (currRecipe[item.Label].Status.HasError && currRecipe[item.Label].Status.Visible);
#else
checkCondition = (currRecipe[item.Label].Status.HasError);
#endif
// 2020.07.29 - controllo condizione secondo status debug/release...
if (checkCondition)
{
currOverview[getRecipeSection(item.Category)] = RecipeCatStatus.HasError;
}
@@ -2583,7 +2600,7 @@ namespace Thermo.Active.NC
// check div0!
if (VUMin == 0)
{
VUMin = 1;
VUMin = 230;
}
// processo corrente minima!
@@ -2595,7 +2612,7 @@ namespace Thermo.Active.NC
minICh = 0;
if (item.CalcIchMin)
{
calcPower = (item.NumResist - 1) + item.MaxPower + item.MaxPower / 2;
calcPower = (item.NumResist - 1) * item.MaxPower + item.MaxPower / 2;
minICh = (double)calcPower / VUMin;
}
newFloatTData.Add(item.IdChannel, minICh);
+2 -1
View File
@@ -146,7 +146,8 @@
<!-- Specifies the trace writer for output -->
<sharedListeners>
<!-- Listener for transport events -->
<add name="SignalR-Transports" type="System.Diagnostics.TextWriterTraceListener" initializeData="logs/transports.log" />
<add name="SignalR-Transports" type="System.Diagnostics.TextWriterTraceListener" initializeData="logs/transports.log" traceOutputOptions="None"/>
<!--<add name="SignalR-Transports" type="System.Diagnostics.TextWriterTraceListener" initializeData="logs/transports.log" />-->
<!-- Listener for scaleout provider events -->
<add name="SignalR-Bus" type="System.Diagnostics.TextWriterTraceListener" initializeData="logs/bus.log" />
<!-- Listener for hub discovery events -->
+3 -1
View File
@@ -172,6 +172,7 @@ namespace Thermo.Active.Controllers.SignalR
throw new HubException(libraryError.localizationKey);
}
#if false
[SignalRAuthorize(FunctionAccess = GENERAL, Action = ACTIONS.WRITE)]
public void WriteM155Response(int process, double responseVal)
{
@@ -179,7 +180,8 @@ namespace Thermo.Active.Controllers.SignalR
CmsError libraryError = ncAdapter.WriteM155Data(process, responseVal);
if (libraryError.IsError())
throw new HubException(libraryError.localizationKey);
}
}
#endif
[SignalRAuthorize(FunctionAccess = GENERAL, Action = ACTIONS.WRITE)]
public void WriteScadaValue(string memIndex, SCADA_MEM_TYPE memType, object value)
@@ -161,21 +161,18 @@ namespace Thermo.Active.Controllers.WebApi
libraryError = ncAdapter.ConfirmRecipeData(true);
if (libraryError.IsError())
{
ThermoActiveLogger.LogError($"ConfirmEdit error | {libraryError.exception}");
ThermoActiveLogger.LogError($"ConfirmEdit error | {libraryError.errorCode} | {libraryError.exception} | {libraryError.localizationKey}");
return BadRequest(libraryError.localizationKey);
}
// SE HO una section != null/empty --> salvo come modificata...
if (section != null)
try
{
try
{
NcFileAdapter.upsRecipeOverview(section, RecipeCatStatus.ChangedOk);
}
catch (Exception exc)
{
ThermoActiveLogger.LogError($"Error on set recipe overview | section: {section}{Environment.NewLine}{exc}");
}
NcFileAdapter.upsRecipeOverview(section, RecipeCatStatus.ChangedOk);
}
catch (Exception exc)
{
ThermoActiveLogger.LogError($"Error on set recipe overview | section: {section}{Environment.NewLine}{exc}");
}
// recupero i dati LIVE dei parametri HMI della ricetta...
@@ -506,7 +503,7 @@ namespace Thermo.Active.Controllers.WebApi
}
// salvo note...
if(!string.IsNullOrEmpty(recipeNotes))
if (!string.IsNullOrEmpty(recipeNotes))
{
NcFileAdapter.RecipeLiveData.recipeNotes = recipeNotes.Trim();
}
+13 -13
View File
@@ -1,17 +1,17 @@
mb_DiscesaCZ,CZ
mb_MembDiscesaZ,Z
mb_DiscesaCZ,↓ Cornice
mb_MembDiscesaZ,↓ Controstampo
mb_MembZ,Controstampo
mb_Mod_MembSalitaZ,Z
mb_Mod_AppoggioDiscesaW,W
mb_Mod_MembSalitaZ,↑ Controstampo
mb_Mod_AppoggioDiscesaW,↓ Stampo
mb_Mod_RiscaldoInf,Riscaldo inferiore
mb_Mod_RiscaldoSup,Riscaldo superiore
mb_Mod_PirometroRisc,Pirometro riscaldo
mb_Mod_DecompSustain,Decompressione/Sostentamento
mb_Mod_Acrilico,Acrilico
mb_Mod_RiscaldiIndietro,RS
mb_Mod_RiscaldiIndietro,← Riscaldi
mb_Mod_ExtraR,Riscaldo superiore aggiuntivo
mb_Mod_Imbutitura,Imbutitura
mb_Mod_SalitaW,W
mb_Mod_SalitaW,↑ Stampo
mb_Mod_AttesaStampo,Attesa stampo
mb_Mod_Raffreddamento,Raffreddamento
mb_Mod_PirometroRaffr,Pirometro raffreddamento
@@ -20,24 +20,24 @@ mb_Mod_VuotoDiretto,Vuoto diretto
mb_Mod_VuotoAux,Vuoto ausiliario
mb_Mod_Nebulizz,Nebulizzatori
mb_Mod_AttesaPartenzaZ,Attesa partenza Z
mb_Mod_DiscesaZ,Z
mb_Mod_DiscesaZ,↓ Controstampo
mb_Mod_Z,Controstampo basso
mb_Mod_SalitaZ,Z
mb_Mod_SalitaZ,↑ Controstampo
mb_Mod_AriaZ,Aria controstampo
mb_Mod_VuotoZ,Vuoto controstampo
mb_Mod_ScaricoVuotoZ,Scarico vuoto controstampo
mb_Mod_ScaricoVuoto,Scarico vuoto
mb_Mod_EstrazioneZ,Estrazione controstampo
mb_Mod_DiscesaAssistZ,Z
mb_Mod_DiscesaAssistZ,↓ Controstampo
mb_Mod_Estrazione,Estrazione
mb_Mod_DiscesaW,W
mb_Mod_RiscaldiIndietro2,RS
mb_Mod_SalitaCZ,CZ
mb_Mod_DiscesaW,↓ Stampo
mb_Mod_RiscaldiIndietro2,← Riscaldi
mb_Mod_SalitaCZ,↑ Cornice
mb_Mod_Riscaldi2,Secondo riscaldo
mb_Mod_Estrazione_Aux_W,Estrazione ausiliaria
mb_Mod_Attesa_Pirometro,Attesa pirometro
mb_Mod_Prevuoto,Prevuoto
mb_Mod_SalitaAssistZ,Z
mb_Mod_SalitaAssistZ,↑ Controstampo
general_sizes_mould_dim_x,Larghezza stampo
general_sizes_mould_dim_y,Profondità stampo
general_sizes_mould_max_height,Altezza massima stampo
+5 -3
View File
@@ -78,10 +78,12 @@ namespace Thermo.Active.Listeners
SignalRListener.SendPartProgramQueue(a);
SignalRDatabaseHandler.UpdateQueue(a);
}));
#if false
infos.Add(MessageServices.Current.Subscribe(SEND_M155_DATA, (a, b) =>
{
SignalRListener.SendM155Data(a);
}));
{
SignalRListener.SendM155Data(a);
}));
#endif
infos.Add(MessageServices.Current.Subscribe(SEND_SCADA_DATA, (a, b) =>
{
SignalRListener.SendScadaData(a);
@@ -226,6 +226,7 @@ namespace Thermo.Active.Listeners.SignalR
}
}
#if false
public static void SendM155Data(object data)
{
List<DTOM155InputModel> dtoM155Data = data as List<DTOM155InputModel>;
@@ -236,7 +237,8 @@ namespace Thermo.Active.Listeners.SignalR
var context = GlobalHost.ConnectionManager.GetHubContext<NcHub>();
context.Clients.Group("ncData").m155Data(dtoM155Data);
}
}
}
#endif
public static void SendScadaData(object scada)
{
@@ -512,8 +514,10 @@ namespace Thermo.Active.Listeners.SignalR
group.magazineIsActive(LastNcMagazineIsActive);
// Send PP Queue
group.partProgramQueue(LastPartProgramQueue);
#if false
// Send m155 data
group.m155Data(LastM155Data);
group.m155Data(LastM155Data);
#endif
// Send Scada
group.scadaData(LastScadaData);
@@ -27,7 +27,9 @@ namespace Thermo.Active.Listeners
public static DTOActiveProgramDataModel LastProgramData = new DTOActiveProgramDataModel();
public static Dictionary<int, bool> LastNcMagazineIsActive = new Dictionary<int, bool>();
public static List<DTOQueueModel> LastPartProgramQueue = new List<DTOQueueModel>();
public static List<DTOM155InputModel> LastM155Data = new List<DTOM155InputModel>();
#if false
public static List<DTOM155InputModel> LastM155Data = new List<DTOM155InputModel>();
#endif
public static List<DTOScadaModel> LastScadaData = new List<DTOScadaModel>();
// FIXME TODO inserire oggetti corretti per THERMO
+1 -1
View File
@@ -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("0.9.46")]
[assembly: AssemblyVersion("0.12.64")]
+81
View File
@@ -0,0 +1,81 @@
# Script di installazione in macchina zip dell'ultima release di ThermoActive
# Check parameters
Param (
[Parameter(Mandatory=$True)]
[ValidateNotNull()]
$zipPath
)
# recupera timestamp x logging
function Get-TimeStamp
{
return "[{0:MM/dd/yy} {0:HH:mm:ss}]" -f (Get-Date)
}
# registra log!
function DoLog($txt2log)
{
Write-Output "$(Get-TimeStamp) $txt2log" | Out-File c:\tmp\Script.log -Append
}
function checkFolder($dirPath)
{
if(!(Test-Path -path $dirPath))
{
New-Item -ItemType directory -Path $dirPath
DoLog("Folder path has been created successfully at $dirPath")
}
}
Write-Output "-------------------------------- START script --------------------------------" | Out-File c:\tmp\Script.log
$StopWatch = New-Object System.Diagnostics.Stopwatch
$StopWatch.Start()
# directory di base
$BaseDir = "C:\CMS"
$ArchiveDir = "$BaseDir\Archive"
$BackupDir = "$BaseDir\Backup"
$ConfDir = "$BaseDir\Conf"
$LogDir = "$BaseDir\Logs"
$UnzipDir = "$BaseDir\Unzip"
$ProgramDir = "$BaseDir\ThermoActive"
$adesso = Get-Date -Format "yyyy.MM.dd_HH.mm"
# mi sposto in Dir di base
cd $BaseDir
# creo se non ci fosse dir varie
checkFolder($BaseDir)
checkFolder($ArchiveDir)
checkFolder($BackupDir)
checkFolder($ConfDir)
checkFolder($LogDir)
checkFolder($UnzipDir)
checkFolder($ProgramDir)
# Salvo CONF varie
robocopy $ProgramDir"\Config\" $BackupDir"\Config\" /MIR /Z /LOG:$LogDir"\Config.1.log"
robocopy $ProgramDir"\Dict\" $BackupDir"\Dict\" /MIR /Z /LOG:$LogDir"\Dict.1.log"
robocopy $ProgramDir"\Recipes\" $BackupDir"\Recipes\" /MIR /Z /LOG:$LogDir"\Recipes.1.log"
robocopy $ProgramDir"\TMP\" $BackupDir"\TMP\" /MIR /Z /LOG:$LogDir"\Tmp.1.log"
# Move versione attuale
Move-Item -Path $ProgramDir -Destination $ArchiveDir"\ThermoActive_$adesso"
# Faccio unzip NUOVA versione
Expand-Archive -Path $zipPath -DestinationPath $UnzipDir -Force
# Move da ZIP a program
Move-Item -Path $UnzipDir -Destination $ProgramDir
#robocopy $UnzipDir $ProgramDir /MIR /Z /LOG:$LogDir+"Newversion.log" /XD "Config Dict Recipes"
# Ripristino CONF
robocopy $BackupDir"\Config\" $ProgramDir"\Config\" /MIR /Z /LOG:$LogDir"\Config.2.log"
robocopy $BackupDir"\Dict\" $ProgramDir"\Dict\" /MIR /Z /LOG:$LogDir"\Dict.2.log"
robocopy $BackupDir"\Recipes\" $ProgramDir"\Recipes\" /MIR /Z /LOG:$LogDir"\Recipes.2.log"
robocopy $BackupDir"\TMP\" $ProgramDir"\TMP\" /MIR /Z /LOG:$LogDir"\Tmp.2.log"
$StopWatch.Stop()
$StopWatch.Elapsed | Out-File $LogDir"\Install.log" -Append
DoLog("-------------------------------- END script --------------------------------")
+2 -1
View File
@@ -11,7 +11,8 @@ Param (
$npmInstall,
[Parameter(Mandatory=$True)]
[ValidateNotNull()]
$npmBuild,[Parameter(Mandatory=$True)]
$npmBuild,
[Parameter(Mandatory=$True)]
[ValidateNotNull()]
$version
)
Binary file not shown.

After

Width:  |  Height:  |  Size: 962 B

@@ -337,6 +337,8 @@ button.soft {
.togglebutton {
vertical-align: middle;
-webkit-tap-highlight-color: transparent;
}
.togglebutton,
@@ -374,6 +376,11 @@ fieldset[disabled] .form-group.is-focused .togglebutton label {
.togglebutton label .toggle {
text-align: left;
margin-left: 5px;
&.error {
background-color: rgba(255, 0, 0, .7);
color: #222;
}
}
.togglebutton label .toggle,
@@ -432,18 +439,19 @@ fieldset[disabled] .form-group.is-focused .togglebutton label {
color: #fff;
}
.togglebutton.big {
.togglebutton.big,
.togglebutton.big[disabled] {
span.toggle {
height: 40px;
width: 112px;
border-radius: 20px;
font-size: 17px;
line-height: 40px;
font-weight: bold;
height: 40px !important;
width: 112px !important;
border-radius: 20px !important;
font-size: 17px !important;
line-height: 40px !important;
font-weight: bold !important;
&:after {
width: 36px;
height: 36px;
width: 36px !important;
height: 36px !important;
}
}
@@ -10,7 +10,7 @@
width: 100%;
background-image: url("../../assets/icons/png/bg.png");
position: fixed;
z-index: 1001;
z-index: 1002;
display: grid;
grid-template-rows: 144px 1fr;
grid-template-columns: 152px 1fr 610px 1fr 152px;
@@ -143,6 +143,60 @@
margin-left: 5px;
margin-right: 5px;
}
.context-menu {
position: relative;
.context-area {
top: 50px;
display: none;
background-color: #fff;
box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.4);
position: absolute;
width: 300px;
left: -150px + 24px;
padding-inline-start: 0;
padding-inline-end: 0;
&.show {
display: block !important;
}
li {
list-style-type: none;
height: 62px;
border-bottom: 1px solid rgba(0, 0, 0, 0.5);
color: #545454;
display: flex;
align-items: center;
justify-content: flex-start;
padding: 0 28px;
font-weight: 500;
font-size: 18px;
cursor: pointer;
&:last-of-type {
border-bottom: none;
}
}
&:before {
content: "";
position: absolute;
top: -15px;
left: calc(~'50% - 8px');
display: block;
width: 0;
height: 0;
border-left: 15px solid transparent;
border-right: 15px solid transparent;
border-bottom: 15px solid #fff;
}
}
}
}
.colorWhite {
@@ -156,6 +210,10 @@
align-items: center;
-webkit-user-select: none;
&.prioritize {
z-index: 9000;
}
button {
font-size: 28px;
justify-content: center;
@@ -146,6 +146,7 @@ select:focus {
flex-flow: row;
align-items: center;
justify-content: space-between;
max-width: 472px;
&.grid {
display: grid;
@@ -222,6 +223,7 @@ select:focus {
color: #002680;
font-size: 24px;
font-weight: 500;
overflow: hidden;
// flex: 0.7;
}
@@ -51,6 +51,7 @@
@import "report.less";
@import "users.less";
@import "tooltip.less";
@import "saveas.less";
@background-color: rgb(216, 216, 216);
@@ -9,24 +9,27 @@
right: 0;
bottom: 80px;
overflow: visible;
z-index: 100;
background-color: #ddd;
width: 1360px;
box-shadow: 2px 10px 15px 0 rgba(0, 0, 0, 0.5);
box-shadow: none;
transform: translateX(1360px);
transition: transform .3s ease-in-out;
transition: transform .3s .2s ease-in-out,box-shadow .3s linear;
display: flex;
align-items: stretch;
justify-content: flex-start;
z-index: 1100;
z-index: 1001;
&.open-full {
transform: translateX(0);
box-shadow: 2px 10px 15px 0 rgba(0, 0, 0, 0.5);
transition: transform .1s ease-in-out,box-shadow .3s .1s linear;
}
&.open-half {
transform: translateX(680px);
box-shadow: 2px 10px 15px 0 rgba(0, 0, 0, 0.5);
transition: transform .1s ease-in-out,box-shadow .3s .1s linear;
}
.paddleButton {
@@ -127,7 +130,7 @@
width: 100%;
height: 100px;
border-radius: 2px;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.4);
background-color: #808e96;
cursor: pointer;
color: #fff;
@@ -141,6 +144,26 @@
justify-content: center;
padding: 1rem;
box-sizing: border-box;
border: none;
position: relative;
&.active {
box-shadow: inset 0px 0px 0px 3px #1791ff;
&[disabled]::after{
box-shadow: inset 0px 0px 0px 3px #1791ff !important;
}
}
&[disabled]::after{
top:0;
left: 0;
position: absolute;
width: 100%;
height: 100%;
background-color: #aaaaaaaa;
content: "";
}
button.configure {
position: absolute;
@@ -153,6 +176,55 @@
color: @color-darkish-blue;
background: #fff;
}
&.pressed:active,
&:active {
background-color: #57636b;
}
}
.starred-softkey {
box-sizing: border-box;
border-radius: 2px;
margin: 0 8px;
text-align: center;
font-size: 18px;
font-weight: bold;
box-shadow: none;
padding: 0 20px;
border: none;
position: relative;
background-image: linear-gradient(to bottom, @color-white2, @color-silver) !important;
&.pressed:active,
&:active {
background-image: linear-gradient(to bottom, @color-silver, @color-white2) !important;
}
&.pressed {
background-image: linear-gradient(to bottom, @color-silver, @color-white2) !important;
}
&.active {
box-shadow: inset 0px 0px 0px 3px #1791ff !important;
&[disabled]::after{
box-shadow: inset 0px 0px 0px 3px #1791ff !important;
}
}
img{
-webkit-user-drag: none;
}
&[disabled]::after{
top:0;
left: 0;
position: absolute;
width: 100%;
height: 100%;
background-color: #aaaaaaaa;
content: "";
}
}
.box-softkeys-prefered-footer {
@@ -119,6 +119,9 @@
color: @color-green;
}
.black{
color: #4b4b4b;
}
.content.READY,
.status.READY{
color: @color-clear-blue;
@@ -21,9 +21,11 @@
.tab-header {
width: 70%;
display: flex;
display: grid;
grid-template-columns: repeat(auto-fit, minmax(160px, 200px));
align-items: center;
justify-content: space-evenly;
justify-content: flex-end;
grid-column-gap: 10px;
button {
border: none;
@@ -45,6 +47,7 @@
}
label {
justify-self: flex-end;
font-size: 32px;
line-height: 1;
}
@@ -0,0 +1,34 @@
// out: false, sourceMap: false, main: ../style.less
.modal.save-as {
width: 500px;
height: 300px;
top: calc(~'50% - 200px');
article {
label {
color: #002680;
font-size: 24px;
font-weight: 500;
overflow: hidden;
margin-bottom: 10px;
}
input {
padding: 5px;
font-size: 18px;
font-weight: 500;
color: #6d6d6d;
width: 100%;
height: 48px;
border-radius: 2px;
box-shadow: inset 0 1px 3px 0 rgba(0, 0, 0, 0.5);
border: none;
display: flex;
flex-flow: row nowrap;
padding: 0 4px;
align-items: center;
justify-content: stretch;
}
}
}
@@ -238,6 +238,34 @@
}
}
i {
grid-column-start: -1;
grid-column-end: 1;
grid-row: 2;
z-index: 2;
margin: auto;
position: absolute;
top: -10px;
left: 47px;
font-size: 25px;
width: 14px;
height: 14px;
overflow: visible;
background-color: white;
justify-content: center;
align-items: center;
display: flex;
border-radius: 7px;
&.fa-check-circle {
color: #90BF3D;
}
&.fa-check-circle.undone-step {
color: #1791FF;
}
}
span,
label {
grid-row-start: 1;
+203 -20
View File
@@ -196,6 +196,31 @@
.setup .modal-footer-navigator .setup-button.current .background-bottom {
box-shadow: -3px -5px 5px rgba(0, 0, 0, 0.2) inset;
}
.setup .modal-footer-navigator .setup-button i {
grid-column-start: -1;
grid-column-end: 1;
grid-row: 2;
z-index: 2;
margin: auto;
position: absolute;
top: -10px;
left: 47px;
font-size: 25px;
width: 14px;
height: 14px;
overflow: visible;
background-color: white;
justify-content: center;
align-items: center;
display: flex;
border-radius: 7px;
}
.setup .modal-footer-navigator .setup-button i.fa-check-circle {
color: #90BF3D;
}
.setup .modal-footer-navigator .setup-button i.fa-check-circle.undone-step {
color: #1791FF;
}
.setup .modal-footer-navigator .setup-button span,
.setup .modal-footer-navigator .setup-button label {
grid-row-start: 1;
@@ -4132,7 +4157,7 @@ article .box .body {
width: 100%;
background-image: url("../../assets/icons/png/bg.png");
position: fixed;
z-index: 1001;
z-index: 1002;
display: grid;
grid-template-rows: 144px 1fr;
grid-template-columns: 152px 1fr 610px 1fr 152px;
@@ -4759,22 +4784,25 @@ article .box .body {
right: 0;
bottom: 80px;
overflow: visible;
z-index: 100;
background-color: #ddd;
width: 1360px;
box-shadow: 2px 10px 15px 0 rgba(0, 0, 0, 0.5);
box-shadow: none;
transform: translateX(1360px);
transition: transform 0.3s ease-in-out;
transition: transform 0.3s 0.2s ease-in-out, box-shadow 0.3s linear;
display: flex;
align-items: stretch;
justify-content: flex-start;
z-index: 1100;
z-index: 1001;
}
.paddle.open-full {
transform: translateX(0);
box-shadow: 2px 10px 15px 0 rgba(0, 0, 0, 0.5);
transition: transform 0.1s ease-in-out, box-shadow 0.3s 0.1s linear;
}
.paddle.open-half {
transform: translateX(680px);
box-shadow: 2px 10px 15px 0 rgba(0, 0, 0, 0.5);
transition: transform 0.1s ease-in-out, box-shadow 0.3s 0.1s linear;
}
.paddle .paddleButton {
width: 40px;
@@ -4852,20 +4880,36 @@ article .box .body {
width: 100%;
height: 100px;
border-radius: 2px;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.4);
background-color: #808e96;
cursor: pointer;
color: #fff;
font-size: 18px;
font-weight: 500;
display: grid;
position: relative;
grid-template-columns: auto 1fr;
grid-column-gap: 10px;
align-items: center;
justify-content: center;
padding: 1rem;
box-sizing: border-box;
border: none;
position: relative;
}
.softkey.active {
box-shadow: inset 0px 0px 0px 3px #1791ff;
}
.softkey.active[disabled]::after {
box-shadow: inset 0px 0px 0px 3px #1791ff !important;
}
.softkey[disabled]::after {
top: 0;
left: 0;
position: absolute;
width: 100%;
height: 100%;
background-color: #aaaaaaaa;
content: "";
}
.softkey button.configure {
position: absolute;
@@ -4878,6 +4922,48 @@ article .box .body {
color: #002680;
background: #fff;
}
.softkey.pressed:active,
.softkey:active {
background-color: #57636b;
}
.starred-softkey {
box-sizing: border-box;
border-radius: 2px;
margin: 0 8px;
text-align: center;
font-size: 18px;
font-weight: bold;
box-shadow: none;
padding: 0 20px;
border: none;
position: relative;
background-image: linear-gradient(to bottom, #f1f1f1, #bbbcbc) !important;
}
.starred-softkey.pressed:active,
.starred-softkey:active {
background-image: linear-gradient(to bottom, #bbbcbc, #f1f1f1) !important;
}
.starred-softkey.pressed {
background-image: linear-gradient(to bottom, #bbbcbc, #f1f1f1) !important;
}
.starred-softkey.active {
box-shadow: inset 0px 0px 0px 3px #1791ff !important;
}
.starred-softkey.active[disabled]::after {
box-shadow: inset 0px 0px 0px 3px #1791ff !important;
}
.starred-softkey img {
-webkit-user-drag: none;
}
.starred-softkey[disabled]::after {
top: 0;
left: 0;
position: absolute;
width: 100%;
height: 100%;
background-color: #aaaaaaaa;
content: "";
}
.box-softkeys-prefered-footer {
height: 65px;
display: flex;
@@ -4966,9 +5052,11 @@ article .box .body {
}
.modal.processo-info header .tab-header {
width: 70%;
display: flex;
display: grid;
grid-template-columns: repeat(auto-fit, minmax(160px, 200px));
align-items: center;
justify-content: space-evenly;
justify-content: flex-end;
grid-column-gap: 10px;
}
.modal.processo-info header .tab-header button {
border: none;
@@ -4987,6 +5075,7 @@ article .box .body {
margin: auto;
}
.modal.processo-info header .tab-header label {
justify-self: flex-end;
font-size: 32px;
line-height: 1;
}
@@ -5433,6 +5522,7 @@ select:focus {
flex-flow: row;
align-items: center;
justify-content: space-between;
max-width: 472px;
}
.input-area.grid {
display: grid;
@@ -5494,6 +5584,7 @@ select:focus {
color: #002680;
font-size: 24px;
font-weight: 500;
overflow: hidden;
}
.input-area .numeric {
font-size: 18px;
@@ -5887,6 +5978,10 @@ fieldset[disabled] .form-group.is-focused .togglebutton label {
text-align: left;
margin-left: 5px;
}
.togglebutton label .toggle.error {
background-color: rgba(255, 0, 0, 0.7);
color: #222;
}
.togglebutton label .toggle,
.togglebutton label input[type=checkbox][disabled] + .toggle {
content: "";
@@ -5937,19 +6032,22 @@ fieldset[disabled] .form-group.is-focused .togglebutton label {
background-image: linear-gradient(to bottom, #3fa4ff, #1791ff);
color: #fff;
}
.togglebutton.big span.toggle {
height: 40px;
width: 112px;
border-radius: 20px;
font-size: 17px;
line-height: 40px;
font-weight: bold;
.togglebutton.big span.toggle,
.togglebutton.big[disabled] span.toggle {
height: 40px !important;
width: 112px !important;
border-radius: 20px !important;
font-size: 17px !important;
line-height: 40px !important;
font-weight: bold !important;
}
.togglebutton.big span.toggle:after {
width: 36px;
height: 36px;
.togglebutton.big span.toggle:after,
.togglebutton.big[disabled] span.toggle:after {
width: 36px !important;
height: 36px !important;
}
.togglebutton.big input[type=checkbox]:checked + .toggle:after {
.togglebutton.big input[type=checkbox]:checked + .toggle:after,
.togglebutton.big[disabled] input[type=checkbox]:checked + .toggle:after {
left: 74px;
}
.custom-checkbox {
@@ -6189,6 +6287,57 @@ fieldset[disabled] .form-group.is-focused .togglebutton label {
margin-left: 5px;
margin-right: 5px;
}
#app > header .context-menu,
.dashboard > header .context-menu {
position: relative;
}
#app > header .context-menu .context-area,
.dashboard > header .context-menu .context-area {
top: 50px;
display: none;
background-color: #fff;
box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.4);
position: absolute;
width: 300px;
left: -126px;
padding-inline-start: 0;
padding-inline-end: 0;
}
#app > header .context-menu .context-area.show,
.dashboard > header .context-menu .context-area.show {
display: block !important;
}
#app > header .context-menu .context-area li,
.dashboard > header .context-menu .context-area li {
list-style-type: none;
height: 62px;
border-bottom: 1px solid rgba(0, 0, 0, 0.5);
color: #545454;
display: flex;
align-items: center;
justify-content: flex-start;
padding: 0 28px;
font-weight: 500;
font-size: 18px;
cursor: pointer;
}
#app > header .context-menu .context-area li:last-of-type,
.dashboard > header .context-menu .context-area li:last-of-type {
border-bottom: none;
}
#app > header .context-menu .context-area:before,
.dashboard > header .context-menu .context-area:before {
content: "";
position: absolute;
top: -15px;
left: calc(50% - 8px);
display: block;
width: 0;
height: 0;
border-left: 15px solid transparent;
border-right: 15px solid transparent;
border-bottom: 15px solid #fff;
}
.colorWhite {
color: #fff !important;
}
@@ -6204,6 +6353,9 @@ fieldset[disabled] .form-group.is-focused .togglebutton label {
display: flex;
padding-right: 8px !important;
}
.window-buttons.prioritize {
z-index: 9000;
}
.window-buttons button {
font-size: 28px;
justify-content: center;
@@ -6701,6 +6853,9 @@ footer .container button.big:before {
.process-info .status.RUN {
color: #7ed321;
}
.process-info .black {
color: #4b4b4b;
}
.process-info .content.READY,
.process-info .status.READY {
color: #1791ff;
@@ -23638,6 +23793,34 @@ footer .container button.big:before {
text-align: center;
color: #4b4b4b;
}
.modal.save-as {
width: 500px;
height: 300px;
top: calc(50% - 200px);
}
.modal.save-as article label {
color: #002680;
font-size: 24px;
font-weight: 500;
overflow: hidden;
margin-bottom: 10px;
}
.modal.save-as article input {
padding: 5px;
font-size: 18px;
font-weight: 500;
color: #6d6d6d;
width: 100%;
height: 48px;
border-radius: 2px;
box-shadow: inset 0 1px 3px 0 rgba(0, 0, 0, 0.5);
border: none;
display: flex;
flex-flow: row nowrap;
padding: 0 4px;
align-items: center;
justify-content: stretch;
}
a,
a:visited,
a:hover,
-2
View File
@@ -19,13 +19,11 @@
</head>
<body>
<app>
<div id="loading-spinner"><i class="fa fa-circle-o-notch fa-spin"></i></div>
</app>
<script src="/dist/vendors~main.js" type="text/javascript"></script>
<script src="/dist/build.js" type="text/javascript"></script>
</body>
</html>
+2648 -2628
View File
File diff suppressed because it is too large Load Diff
+11 -11
View File
@@ -25,7 +25,7 @@
"svg-pan-zoom": "3.6.1",
"v-tooltip": "^2.0.3",
"vee-validate": "2.1.1",
"vue": "^2.6.11",
"vue": "^2.6.12",
"vue-chartjs": "^3.5.0",
"vue-class-component": "7.2.3",
"vue-drag-drop": "1.1.4",
@@ -37,16 +37,16 @@
"vuex": "3.1.3"
},
"devDependencies": {
"@babel/plugin-proposal-export-default-from": "7.8.3",
"@babel/plugin-proposal-export-default-from": "7.10.4",
"@types/es6-promise": "3.3.0",
"@vue/cli-plugin-babel": "^4.1.0",
"@vue/cli-plugin-eslint": "^4.1.0",
"@vue/cli-plugin-router": "^4.1.0",
"@vue/cli-plugin-typescript": "^4.1.0",
"@vue/cli-plugin-vuex": "^4.1.0",
"@vue/cli-service": "^4.2.3",
"@vue/cli-plugin-babel": "^4.5.4",
"@vue/cli-plugin-eslint": "^4.5.4",
"@vue/cli-plugin-router": "^4.5.4",
"@vue/cli-plugin-typescript": "^4.5.4",
"@vue/cli-plugin-vuex": "^4.5.4",
"@vue/cli-service": "^4.5.4",
"autoprefixer": "^7.1.2",
"babel-loader": "8.0.6",
"babel-loader": "8.1.0",
"chalk": "^2.0.1",
"copy-webpack-plugin": "^4.0.1",
"css-loader": "^0.28.0",
@@ -57,8 +57,8 @@
"ts-loader": "6.2.1",
"typescript": "3.8.3",
"url-loader": "^3.0.0",
"vue-loader": "^15.9.0",
"vue-template-compiler": "^2.6.11",
"vue-loader": "^15.9.3",
"vue-template-compiler": "^2.6.12",
"webpack": "^4.42.0",
"webpack-cli": "3.2.3",
"webpack-dev-server": "3.2.1"
+1
View File
@@ -12,6 +12,7 @@ declare module Recipe {
}
interface IValue {
key?: string,
range: IRange,
status: IStatus,
unitMeasure: string,
+3
View File
@@ -56,6 +56,7 @@ export default class app extends Vue {
loadingOperations = 0;
HMIsrc = null;
hub: Hub = null;
prioritizeWindowsButtons = false;
beforeMount() {
moment.locale((window.navigator as any).userLanguage || window.navigator.language);
@@ -73,10 +74,12 @@ export default class app extends Vue {
ms.subscribeToChannel("show-modal-login", args => {
this.applyBlur = true;
this.prioritizeWindowsButtons = true;
});
ms.subscribeToChannel("hide-modal-login", args => {
this.applyBlur = false;
this.prioritizeWindowsButtons = false;
});
ms.subscribeToChannel("hide-modal", args => {
+3 -2
View File
@@ -21,8 +21,8 @@
</div>
<modal-container containerName="modal-login" name="modal-login"></modal-container>
<keyboard></keyboard>
<modal-container name="modal"></modal-container>
<div class="window-buttons">
<div class="window-buttons" :class="{prioritize: prioritizeWindowsButtons}">
<button
class="gray square close"
@click="sendMessage('hide')"
@@ -34,6 +34,7 @@
:title="'header_tooltip_btn_close' | localize('Close the application')"
>&times;</button>
</div>
<modal-container name="modal"></modal-container>
</div>
</template>
<script src="./App.ts" lang="ts"></script>
@@ -1,7 +1,6 @@
import Axios, { AxiosInstance, AxiosPromise, AxiosResponse, AxiosBasicCredentials, AxiosRequestConfig } from "axios";
import Factory from "./factoryService";
import * as iziToast from "izitoast";
// import { localizeString } from "../filters/localizeFilter";
import { store, AppModel } from "@/store";
interface InterceptorRequestDelegate { (config: AxiosRequestConfig): AxiosRequestConfig; }
@@ -9,6 +9,7 @@ import { UserInfoDialog, MachineInfoDialog, ContactInfoDialog } from "@/app_modu
import { ModalHelper } from "./components/modals/ModalHelper";
import Vue from "vue";
import { loginService, machineService, localizationService } from "./services";
import { prodService } from "./services/prodService";
// import { UsersService } from "./services/usersService";
@@ -61,6 +62,8 @@ async function loadMachineConfig() {
let mcresult = await machine.getMachineConfiguration();
await prodService.GetProdPanel();
// load default language
if (!(store.state as AppModel).localization.currentLanguage) {
localizationService.changeCurrentLanguage(mcresult.defaultLanguage);
@@ -2,7 +2,6 @@ import Component from "vue-class-component";
import Vue from "vue";
import { Prop } from "vue-property-decorator";
import lottie from "lottie-web";
import { localizeString } from "@/filters/localizeFilter";
@Component({})
export default class Combo extends Vue {
@@ -25,13 +24,15 @@ export default class Combo extends Vue {
get currentValue() {
let result = this.options.find(o => o.id == this.value.setpointHMI);
if (result) return localizeString(result.text, result.text);
if (result) {
return this.$options.filters.localize(result.text, result.text);
}
return null;
}
opened: boolean = false;
showList() {
this.opened = true;
this.opened = !this.opened;
this.$nextTick(() => lottie.searchAnimations());
}
@@ -1,6 +1,6 @@
<template>
<div class="combo">
<div class="form" @click="showList">
<div class="form" @click="showList" :class="{'error': value.status && value.status.hasError}">
{{currentValue}}
<i v-if="opened" class="fa fa-chevron-up" />
<i v-else class="fa fa-chevron-down" />
@@ -36,7 +36,7 @@
font-size: 18px;
font-weight: 500;
color: #6d6d6d;
min-width: 80px;
min-width: 200px;
width: fit-content;
height: 48px;
@@ -53,6 +53,10 @@
cursor: pointer;
}
.combo .form.error {
outline: 2px red auto;
}
.combo .form i {
position: absolute;
right: 4px;
@@ -48,9 +48,10 @@ export default class Numeric extends Vue {
KeyboardHelper.showKeyboard(x, y, this.value);
let textBox = (this.$refs.input as any);
textBox.SelectionStart = textBox.value.length;
textBox.SelectionLength = 0;
this.$nextTick(() => { this.focused = true; })
this.$nextTick(() => {
this.focused = true;
})
}
@@ -5,6 +5,7 @@ import { dataService } from "@/services/dataService";
import { store, MachineStatusModel } from "@/store";
import { SoftKeysConfigurationModel, machineInfoStore } from "@/store/machineInfo.store";
import { Hub, machineService } from "@/services";
import { Watch } from "vue-property-decorator";
@Component({
components: { softKey }
@@ -58,6 +59,11 @@ export default class Paddle extends Vue {
}
async mounted() {
this.loadData();
}
@Watch("isOpen")
async loadData() {
await dataService.GetSoftKeysConfiguration();
await dataService.GetUserSoftkeyFavorite();
}
@@ -22,6 +22,7 @@
@toggleFavourite="toggleFavourite(b.id, false)"
v-model="getSoftKeyStatus(b.id).value"
:active="getSoftKeyStatus(b.id).active"
:value="getSoftKeyStatus(b.id).value"
:isFavourite="true"
@click="softKeyChanged(b.id, b.operatorConfirmationNeeded)"
@checkChanged="softKeyChanged(b.id, b.operatorConfirmationNeeded)"
@@ -55,6 +56,7 @@
<template v-for="(b,idx) in allSoftKeys">
<soft-key
v-if="getSoftKeyStatus(b.id) && getSoftKeyStatus(b.id).visible"
:id="b.id"
:key="idx"
:title="'softkey_' + b.id | localize('softkey_' + b.id)"
:type="b.type"
@@ -62,6 +64,7 @@
@toggleFavourite="toggleFavourite(b.id, !isFavourite(b.id))"
v-model="getSoftKeyStatus(b.id).value"
:active="getSoftKeyStatus(b.id).active"
:value="getSoftKeyStatus(b.id).value"
:isFavourite="isFavourite(b.id)"
@click="softKeyChanged(b.id, b.operatorConfirmationNeeded)"
@checkChanged="softKeyChanged(b.id, b.operatorConfirmationNeeded)"
@@ -18,11 +18,18 @@ export default class SoftKey extends Vue {
@Prop({ default: false })
configMode: boolean;
@Prop({ default: false })
active: boolean;
@Prop({ default: false })
isFavourite: boolean;
@Prop({ default: null })
id: number;
doclick() {
if (!this.configMode && this.type != 0) this.$emit('click');
if (this.configMode) this.$emit('toggleFavourite');
}
get Checked() { return this.value; }
@@ -1,11 +1,11 @@
<template>
<div class="softkey" @click="doclick()">
<button class="softkey" @click="doclick()" :disabled="!active && !configMode" :class="{ active: (value && type==1 && !configMode)}">
<button class="configure" v-if="configMode" @click.prevent.stop="$emit('toggleFavourite')">
<i class="fa fa-plus" v-if="!isFavourite"></i>
<i class="fa fa-minus" v-if="isFavourite"></i>
</button>
<toggle-button v-if="type==0" v-model="Checked"></toggle-button>
{{title}}
</div>
</button>
</template>
<script src="./softkey.ts" lang="ts"></script>
@@ -1,7 +1,9 @@
import Vue from "vue";
import Component from "vue-class-component";
import { Prop } from 'vue-property-decorator';
import { debounce } from "@/_base/debounce";
import { Hub } from "@/services";
import Numeric from "./numeric";
@Component({ name: "slider" })
export default class Slider extends Vue {
@@ -16,49 +18,69 @@ export default class Slider extends Vue {
@Prop({ default: 1 })
decimal: number;
incrementing: number = 0;
tempValue: number = null;
get actualvalue() {
return this.value.setpointHMI;
}
set actualvalue(v: number) {
this.debouncedActualValue(v)
get softKey() {
return this.$store.getters.getSoftKeyByRef(this.value.key);
}
debouncedActualValue = debounce((v: number) => this.value.setpointHMI = v, 200);
set actualvalue(v: number) {
this.value.setpointHMI = v;
}
get step() {
var s = ((this.value.range.max - this.value.range.min) / (this.lines + 1));
var m = Math.pow(10, this.decimal);
return Math.round(s * m) / m
// var s = ((this.value.range.max - this.value.range.min) / (this.lines + 1));
// var m = Math.pow(10, this.decimal);
// return Math.round(s * m) / m
return 1;
};
increment() {
startIncrement() {
if (!this.value.status.enabled) return;
this.incrementing = setInterval(() => {
var v = this.value.setpointHMI;
if (v < this.value.range.max) {
v += this.step;
}
if (v > this.value.range.max) {
v = this.value.range.max;
}
this.actualvalue = v;
}, 50);
}
var v = this.value.setpointHMI;
if (v < this.value.range.max) {
v -= (-this.step);
}
if (v > this.value.range.max) {
v = this.value.range.max;
}
this.actualvalue = v;
};
decrement() {
startDecrement() {
if (!this.value.status.enabled) return;
this.incrementing = setInterval(() => {
var v = this.value.setpointHMI;
if (v > this.value.range.min) {
v -= this.step;
}
if (v < this.value.range.min) {
v = this.value.range.min;
}
this.actualvalue = v;
}, 50);
}
confirm() {
if (!this.value.status.enabled) return;
if (this.incrementing)
clearInterval(this.incrementing);
this.incrementing = 0;
var v = this.value.setpointHMI;
if (v > this.value.range.min) {
v -= this.step;
}
if (v < this.value.range.min) {
v = this.value.range.min;
}
this.actualvalue = v;
};
doSoftKeyClick() {
Hub.Current.sendUserSoftKey(this.softKey.id);
}
}
@@ -1,29 +1,44 @@
<template>
<div class="slider">
<button @click="decrement()">
<img src="assets/icons/png/min.png" />
</button>
<div class="control">
<input
:disabled="!this.value.status.enabled"
:min="this.value.range.min"
:max="this.value.range.max"
v-model.number="actualvalue"
type="range"
/>
<div class="lines">
<span v-for="iter in lines" :key="iter" class="line"></span>
</div>
<div class="labels">
<small>{{`${this.value.range.min} ${this.value.unitMeasure}`}}</small>
<small>{{`${(this.value.range.max - this.value.range.min) / 2 + this.value.range.min} ${this.value.unitMeasure}`}}</small>
<small>{{`${this.value.range.max} ${this.value.unitMeasure}`}}</small>
<div class="slider-container">
<div class="slider">
<button @mousedown="startDecrement()" @mouseup="confirm()" @mouseout="confirm()">
<img src="assets/icons/png/min.png" />
</button>
<div class="control">
<input
:disabled="!this.value.status.enabled"
:min="this.value.range.min"
:max="this.value.range.max"
v-model.number="actualvalue"
type="range"
/>
<div class="lines">
<span v-for="iter in lines" :key="iter" class="line"></span>
</div>
<div class="labels">
<small>{{`${this.value.range.min} ${this.value.unitMeasure}`}}</small>
<small>{{`${(this.value.range.max - this.value.range.min) / 2 + this.value.range.min} ${this.value.unitMeasure}`}}</small>
<small>{{`${this.value.range.max} ${this.value.unitMeasure}`}}</small>
</div>
</div>
<button @mousedown="startIncrement()" @mouseup="confirm()" @mouseout="confirm()">
<img src="assets/icons/png/max.png" />
</button>
</div>
<button @click="increment()">
<img src="assets/icons/png/max.png" />
</button>
<button
class="submit"
v-if="softKey"
@click="doSoftKeyClick()"
>{{softKey.refCallLabel | localize(softKey.refCallLabel)}}</button>
</div>
</template>
<style scoped>
.slider-container {
display: grid;
grid-row-gap: 1rem;
flex-flow: column;
justify-items: center;
width: 100%;
}
</style>
<script lang="ts" src="./slider.ts"></script>
@@ -56,11 +56,11 @@
</div>
<div class="col">
<small>{{'history-item_mouldEnergyIN' | localize("energia utilizzata in")}}</small>
<span>{{value.mouldEnergyIN | round(1)}}kW</span>
<span>{{value.mouldEnergyIN | round(1)}}kWh</span>
</div>
<div class="col">
<small>{{'history-item_mouldEnergyOUT' | localize("energia utilizzata out")}}</small>
<span>{{value.mouldEnergyOUT | round(1)}}kW</span>
<span>{{value.mouldEnergyOUT | round(1)}}kWh</span>
</div>
</div>
</div>
@@ -86,7 +86,7 @@ export default class Dashboard extends Vue {
async mounted() {
await prodService.GetProdPanel();
prodService.GetProdPanel();
let $this = this;
setInterval(() => {
@@ -1,6 +1,6 @@
import Component from "vue-class-component";
import Vue from "vue";
import { Prop, InjectReactive } from "vue-property-decorator";
import { Prop, InjectReactive, Watch } from "vue-property-decorator";
import { IGanttOptions } from "./gantt";
import block from "./gantt-component.vue";
import { relativeTimeRounding } from "moment";
@@ -36,6 +36,17 @@ export default class GanttRow extends Vue {
return blockStartPosition(block, this.blocks, this.ganttOptions) * this.ganttOptions.secondSize;
}
get ActiveBlocks() {
return this.blocksInSection.filter(i => !i.terminated);
}
@Watch('ActiveBlocks')
firstActiveBlockChanged(n, o) {
if (n && n != o) {
this.$emit('firstBlockChanged', this.$el.getBoundingClientRect().top, Math.min(...this.ActiveBlocks.map(i => this.verticalPosition(i))));
}
}
/*
Questa funzione calcola la posizione verticale di ogni blocco seguendo l'ordine dei blocchi ed utilizza
@@ -71,7 +82,16 @@ export default class GanttRow extends Vue {
get rowHeight() {
let result = Math.max(...this.blocksInSection.map(b => this.verticalPosition(b) + this.ganttOptions.elementHeight + this.ganttOptions.elementPadding * 2)) * this.zoomFactor;
if (!Number.isNaN(result) && Number.isFinite(result)) return result;
return 0;
return 10;
}
@Watch("rowHeight")
rowHeightChanged(n, o) {
if (n != o) this.$emit("heightChanged");
}
mounted() {
this.rowHeightChanged(0, this.rowHeight);
}
}
@@ -1,18 +1,24 @@
<template>
<g class="gantt-row" :transform="`translate(0 ${paddingVertical})`">
<g
:transform="`translate(${ganttOptions.stepDuration * ganttOptions.secondSize + paddingHorizontal} 0) scale(${zoomFactor} ${zoomFactor})`"
>
<template v-for="b in blocksInSection.filter( i=> i.visible)">
<block
:key="b.id"
:value="b"
:x="startPosition(b)"
:y="verticalPosition(b) + ganttOptions.elementPadding"
stroke="#999"
stroke-width="2"
/>
</template>
<g>
<rect x="0" y="0" width="100%" :height="rowHeight" class="background"></rect>
</g>
<g :transform="`scale(${zoomFactor} ${zoomFactor})`">
<g
class="pad"
:transform="`translate(${ganttOptions.stepDuration * ganttOptions.secondSize + paddingHorizontal} 0)`"
>
<template v-for="b in blocksInSection.filter( i=> i.visible)">
<block
:key="b.id"
:value="b"
:x="startPosition(b)"
:y="verticalPosition(b) + ganttOptions.elementPadding"
stroke="#999"
stroke-width="2"
/>
</template>
</g>
</g>
<g>
<rect x="0" y="0" width="25" :height="rowHeight " fill="#cfcfcf"></rect>
@@ -18,6 +18,37 @@ export default class Gantt extends Vue {
padX: number = 0;
padY: number = 0;
get PadX() {
let w = ((this.$refs.mainContainer as any)?.clientWidth ?? 0) / 3;
if (this.follow && w && this.currentTime * this.ganttOptions.secondSize > w)
return -(this.currentTime * this.ganttOptions.secondSize - w);
return this.padX;
}
set PadX(value: number) {
if (!this.follow)
this.padX = value;
}
get PadY() {
return this.padY;
}
set PadY(value: number) {
this.padY = value;
}
follow: boolean = false;
get canFollow() {
if (this.follow && this.currentTime > 1)
return true;
return false;
}
activeBlockYPosition = 0;
updateVerticalPosition(b, e) {
this.activeBlockYPosition = b + e;
}
@Prop({ default: 1 })
zoomFactor: number;
@@ -48,10 +79,6 @@ export default class Gantt extends Vue {
return element?.rowHeight || 0;
}
mounted() {
this.$nextTick(() => this.$forceUpdate())
}
startPan(event: MouseEvent | TouchEvent) {
this.lastPosition = this.getSvgCoords(event);
}
@@ -66,8 +93,8 @@ export default class Gantt extends Vue {
if (event.type == "touchmove" || (event.type == "mousemove" && (event as MouseEvent).buttons)) {
let p = this.getSvgCoords(event)
this.padX = Math.min(this.padX + p.x - this.lastPosition.x, 0);
this.padY = Math.max(Math.min(this.padY + p.y - this.lastPosition.y, 0), -this.maxPaddingY);
this.PadX = Math.min(this.PadX + p.x - this.lastPosition.x, 0);
this.PadY = Math.max(Math.min(this.PadY + p.y - this.lastPosition.y, 0), -this.maxPaddingY);
@@ -110,6 +137,17 @@ export default class Gantt extends Vue {
return { x, y };
}
updateRow() {
this.$forceUpdate()
}
toggleFollow() {
this.follow = !this.follow;
if (this.follow)
this.padX = 0;
}
}
@@ -11,44 +11,52 @@
@mouseup="stopPan"
v-on:touchstart="startPan"
v-on:touchend="stopPan"
:class="{follow:canFollow}"
>
<!-- <gantt-header :padding-horizontal="padX " /> -->
<g :transform="`translate(0 ${ganttOptions.stepDuration * ganttOptions.secondSize + padY })`">
<g :transform="`translate(0 ${ganttOptions.stepDuration * ganttOptions.secondSize + PadY })`">
<gantt-row
:section="1"
:blocks="blocks"
ref="section1"
:padding-horizontal="padX"
:padding-horizontal="PadX"
:zoom-factor="zoomFactor"
@heightChanged="updateRow"
@firstBlockChanged="updateVerticalPosition"
>
<span>{{`process-heating` | localize('Riscaldo')}}</span>
</gantt-row>
<gantt-row
v-if="getRowHeight($refs.section1)"
:padding-horizontal="padX "
:padding-horizontal="PadX "
:padding-vertical="getRowHeight($refs.section1) + ganttOptions.elementPadding"
:section="2"
:blocks="blocks"
:zoom-factor="zoomFactor"
@heightChanged="updateRow"
@firstBlockChanged="updateVerticalPosition"
ref="section2"
>
<span>{{`process-forming` | localize('Formatura')}}</span>
</gantt-row>
<gantt-row
v-if="getRowHeight($refs.section1)+ getRowHeight($refs.section2)"
:padding-horizontal="padX "
v-if="!!getRowHeight($refs.section1) && !!getRowHeight($refs.section2)"
:padding-horizontal="PadX "
ref="section3"
@heightChanged="updateRow"
:padding-vertical="getRowHeight($refs.section1) + getRowHeight($refs.section2) + ganttOptions.elementPadding*2"
:section="3"
:blocks="blocks"
:zoom-factor="zoomFactor"
@firstBlockChanged="updateVerticalPosition"
>
<span>{{`process-extraction` | localize('Estrazione')}}</span>
</gantt-row>
</g>
<gantt-header :padding-horizontal="padX " :zoom-factor="zoomFactor" />
<gantt-header :padding-horizontal="PadX " :zoom-factor="zoomFactor" />
<time-line
:padding-horizontal="padX"
v-if="!!getRowHeight($refs.section1) && !!getRowHeight($refs.section2)"
:padding-horizontal="PadX"
:zoom-factor="zoomFactor"
:speed="1"
:x="ganttOptions.stepDuration * ganttOptions.secondSize - 15"
@@ -57,10 +65,23 @@
/>
</svg>
</template>
<style scoped>
<style>
svg.gantt {
cursor: move;
}
.gantt-row .background {
fill: transparent;
}
.gantt-row:nth-child(even) .background {
fill: #f6f6f6;
}
svg.gantt.follow g.gantt-header,
svg.gantt.follow g.pad {
transition: 1s transform linear;
}
</style>
<script lang="ts" src="./gantt.ts"></script>
@@ -1,12 +1,16 @@
<template>
<svg class="timeline">
<g :transform="`translate(${ paddingHorizontal} 0)`">
<g
:transform="`translate(${(position + Math.min(20*position/60, 20)*speed) * zoomFactor} 0)`"
:style="position>20?`transition: transform ${speed}s linear`:''"
>
<path class="arrow" d="M 0 0 L 30 0 L 15 24 Z" />
<line x1="15" y1="24" x2="15" :y2="lineHeight" />
<g :transform="`translate(${ paddingHorizontal} 0)`" class="pad">
<g :transform="`scale(${zoomFactor} 1)`">
<g
:transform="`translate(${position} 0)`"
:style="position>20?`transition: transform ${speed}s linear`:''"
>
<g :transform="`scale(${2-zoomFactor} 1)`">
<path class="arrow" d="M 0 0 L 30 0 L 15 24 Z" />
<line x1="15" y1="24" x2="15" :y2="lineHeight" />
</g>
</g>
</g>
</g>
</svg>
@@ -1,25 +1,29 @@
import Vue from 'vue';
import Component from 'vue-class-component';
import { Prop } from 'vue-property-decorator';
import { messageService } from "@/_base/messageService";
import { Modal, ModalHelper } from "@/components/modals";
import gantt from "./gantt/gantt.vue";
import { moduleService } from '@/services/moduleService';
import { Modal as modal, ModalHelper } from "@/components/modals";
import { CONFIGURATION } from '@/config';
import zoom from "./gantt/zoomLevel.vue";
import { store } from '@/store';
import { dataService } from '@/services/dataService';
import gantt from "./gantt/gantt.vue";
import zoom from "./gantt/zoomLevel.vue";
import softKey from "./softkey.vue";
import { Hub } from '@/services';
@Component({
components: {
modal: Modal, gantt, zoom
modal, gantt, zoom, softKey
}
})
export default class Processo extends Vue {
@Prop({ default: 25 })
actual: number;
@Prop({ default: 145 })
tot: number;
get actual(): number {
return store.state.prod.panel.numDone;
};
get tot(): number {
return store.state.prod.panel.numTarget;
};
get blocks(): server.Modblock[] {
return store.state.modules.blocks;
@@ -29,6 +33,8 @@ export default class Processo extends Vue {
zoomStep = 1.2;
starred: { id: number }[] = []
get gaugeData() {
return store.state.machineStatus.gaugeData;
}
@@ -40,11 +46,25 @@ export default class Processo extends Vue {
showAllBlocks: boolean = false;
async mounted() {
let c = await CONFIGURATION;
this.showAllBlocks = c.allUIVisible;
this.starred = await dataService.GetStarredSoftKeysConfiguration();
}
softKeyChanged(id, confirm) {
if (!confirm)
Hub.Current.sendUserSoftKey(id);
else {
ModalHelper.AskConfirm( this.$options.filters.localize("", ""),
this.$options.filters.localize("softkey_confirm", "Cancel"),
() => {
Hub.Current.sendUserSoftKey(id);
}, null, "modal");
}
}
getSoftKeyStatus(id) {
return this.$store.getters.getSoftKeyStatus(id);
}
}
@@ -5,33 +5,24 @@
:title="'processo_lbl_title' | localize('Attività attuale (es. attesa spostamento assi)')"
>
<div class="tab-header" slot="header-buttons">
<button>
<img src="assets/icons/png/star.png" />
<span>Opzioni di lavorazione</span>
</button>
<button>
<img src="assets/icons/png/star.png" />
<span>Pirometro</span>
</button>
<button>
<img src="assets/icons/png/star.png" />
<span>Attivazione riscaldi</span>
</button>
<button>
<img src="assets/icons/png/star.png" />
<span>Riscaldo +10 secondi</span>
</button>
<button>
<img src="assets/icons/png/star.png" />
<span>Risclado -10 secondi</span>
</button>
<button>
<img src="assets/icons/png/star.png" />
<span>Label pulsante opzionale</span>
</button>
<label>{{actual}}/{{tot}}</label>
<template v-for="(b,idx) in starred">
<soft-key
v-if="getSoftKeyStatus(b.id) && getSoftKeyStatus(b.id).visible"
:id="b.id"
:key="idx"
:title="'softkey_' + b.id | localize('softkey_' + b.id)"
:type="b.type"
v-model="getSoftKeyStatus(b.id).value"
:value="getSoftKeyStatus(b.id).value"
:active="getSoftKeyStatus(b.id).active"
@click="softKeyChanged(b.id, b.operatorConfirmationNeeded)"
@checkChanged="softKeyChanged(b.id, b.operatorConfirmationNeeded)"
></soft-key>
</template>
<label><span v-if="tot">{{actual}}/{{tot}}</span></label>
</div>
<gantt
ref="gantt"
v-if="blocks"
:blocks="blocks"
:zoom-factor="zoomFactor"
@@ -45,6 +36,14 @@
<button class="btn">
<i class="fa fa-search-plus" @click="zoomFactor *= zoomStep"></i>
</button>
<button
class="realign"
v-if="$refs.gantt"
@click="$refs.gantt.toggleFollow()"
:class="{active: $refs.gantt.follow}"
>
<img src="/assets/icons/png/recenter-time.png" />
</button>
</div>
</modal>
</div>
@@ -82,6 +81,19 @@
flex-shrink: 0;
margin: 0;
}
.zoom-buttons button.realign {
position: absolute;
top: 60px;
width: 90px;
height: 90px;
border-radius: 50px;
right: 0;
}
.zoom-buttons button.realign.active {
border-color: #1791ff;
}
</style>
<script lang="ts" src="./processo.ts"></script>
@@ -0,0 +1,26 @@
import Vue from "vue";
import Component from "vue-class-component";
import { Prop } from "vue-property-decorator";
@Component({})
export default class SoftKey extends Vue {
@Prop({ default: "" })
title: string;
@Prop({ default: 0 })
type: number;
@Prop({ default: false })
value: boolean;
@Prop({ default: false })
active: boolean;
@Prop({ default: null })
id: number;
doclick() {
this.$emit('click');
}
}
@@ -0,0 +1,7 @@
<template>
<button class="starred-softkey" @click="doclick()" :disabled="!active" :class="{ active: value }">
<img src="assets/icons/png/star.png" />
<span>{{title}}</span>
</button>
</template>
<script src="./softkey.ts" lang="ts"/>
@@ -1,68 +1,71 @@
<template>
<div class="setup">
<modal type="progr-preriscaldo-info" :title="'progr-preriscaldo_lbl_title' | localize('Programmazione preriscaldo')">
<section>
<aside class="scrollable auto">
<div class="input-area">
<label>Abilitazione</label>
<toggle-button v-model="enabling"></toggle-button>
</div>
<hr>
<div class="input-area">
<label>Riscaldi</label>
<toggle-button v-model="risc"></toggle-button>
</div>
<div class="input-area">
<label>Termoregolatore</label>
<toggle-button v-model="termo"></toggle-button>
</div>
<div class="input-area">
<label>Blocca schermo</label>
<toggle-button v-model="block"></toggle-button>
</div>
<button @click="showPreDashboard()">Mostra countdown</button>
</aside>
<hr>
<div class="specific">
<label>{{active}} alle ore {{hours}}:00 {{meridian}}</label>
<div>
<button :class="{'active':active=='Lunedì'}" @click="active='Lunedì'">Lunedì</button>
<button :class="{'active':active=='Martedì'}" @click="active='Martedì'">Martedì</button>
<button :class="{'active':active=='Mercoledì'}" @click="active='Mercoledì'">Mercoledì</button>
<button :class="{'active':active=='Giovedì'}" @click="active='Giovedì'">Giovedì</button>
<button :class="{'active':active=='Venerdì'}" @click="active='Venerdì'">Vener</button>
<button :class="{'active':active=='Sabato'}" @click="active='Sabato'">Sabato</button>
<button :class="{'active':active=='Domenica'}" @click="active='Domenica'">Domenica</button>
</div>
<div>
<div>
<label>{{hours}}:00</label>
<label>{{meridian}}</label>
</div>
<div class="clock">
<button class="btn1" :class="{'selected':hours=='1'}" @click="hours='1'">1</button>
<button class="btn2" :class="{'selected':hours=='2'}" @click="hours='2'">2</button>
<button class="btn3" :class="{'selected':hours=='3'}" @click="hours='3'">3</button>
<button class="btn4" :class="{'selected':hours=='4'}" @click="hours='4'">4</button>
<button class="btn5" :class="{'selected':hours=='5'}" @click="hours='5'">5</button>
<button class="btn6" :class="{'selected':hours=='6'}" @click="hours='6'">6</button>
<button class="btn7" :class="{'selected':hours=='7'}" @click="hours='7'">7</button>
<button class="btn8" :class="{'selected':hours=='8'}" @click="hours='8'">8</button>
<button class="btn9" :class="{'selected':hours=='9'}" @click="hours='9'">9</button>
<button class="btn10" :class="{'selected':hours=='10'}" @click="hours='10'">10</button>
<button class="btn11" :class="{'selected':hours=='11'}" @click="hours='11'">11</button>
<button class="btn12" :class="{'selected':hours=='12'}" @click="hours='12'">12</button>
<span></span>
</div>
<div>
<button @click="meridian='AM'">AM</button>
<button @click="meridian='PM'">PM</button>
</div>
</div>
</div>
</section>
</modal>
</div>
<div class="setup">
<modal
type="progr-preriscaldo-info"
:title="'progr-preriscaldo_lbl_title' | localize('Programmazione preriscaldo')"
>
<section>
<aside class="scrollable auto">
<div class="input-area">
<label>Abilitazione</label>
<toggle-button v-model="enabling"></toggle-button>
</div>
<hr />
<div class="input-area">
<label>Riscaldi</label>
<toggle-button v-model="risc"></toggle-button>
</div>
<div class="input-area">
<label>Termoregolatore</label>
<toggle-button v-model="termo"></toggle-button>
</div>
<div class="input-area">
<label>Blocca schermo</label>
<toggle-button v-model="block"></toggle-button>
</div>
<button @click="showPreDashboard()">Mostra countdown</button>
</aside>
<hr />
<div class="specific">
<label>{{active}} alle ore {{hours}}:00 {{meridian}}</label>
<div>
<button :class="{'active':active=='Lunedì'}" @click="active='Lunedì'">Lunedì</button>
<button :class="{'active':active=='Martedì'}" @click="active='Martedì'">Marte</button>
<button :class="{'active':active=='Mercoledì'}" @click="active='Mercoledì'">Mercoledì</button>
<button :class="{'active':active=='Giovedì'}" @click="active='Giovedì'">Giovedì</button>
<button :class="{'active':active=='Venerdì'}" @click="active='Venerdì'">Venerdì</button>
<button :class="{'active':active=='Sabato'}" @click="active='Sabato'">Sabato</button>
<button :class="{'active':active=='Domenica'}" @click="active='Domenica'">Domenica</button>
</div>
<div>
<div>
<label>{{hours}}:00</label>
<label>{{meridian}}</label>
</div>
<div class="clock">
<button class="btn1" :class="{'selected':hours=='1'}" @click="hours='1'">1</button>
<button class="btn2" :class="{'selected':hours=='2'}" @click="hours='2'">2</button>
<button class="btn3" :class="{'selected':hours=='3'}" @click="hours='3'">3</button>
<button class="btn4" :class="{'selected':hours=='4'}" @click="hours='4'">4</button>
<button class="btn5" :class="{'selected':hours=='5'}" @click="hours='5'">5</button>
<button class="btn6" :class="{'selected':hours=='6'}" @click="hours='6'">6</button>
<button class="btn7" :class="{'selected':hours=='7'}" @click="hours='7'">7</button>
<button class="btn8" :class="{'selected':hours=='8'}" @click="hours='8'">8</button>
<button class="btn9" :class="{'selected':hours=='9'}" @click="hours='9'">9</button>
<button class="btn10" :class="{'selected':hours=='10'}" @click="hours='10'">10</button>
<button class="btn11" :class="{'selected':hours=='11'}" @click="hours='11'">11</button>
<button class="btn12" :class="{'selected':hours=='12'}" @click="hours='12'">12</button>
<span></span>
</div>
<div>
<button @click="meridian='AM'">AM</button>
<button @click="meridian='PM'">PM</button>
</div>
</div>
</div>
</section>
</modal>
</div>
</template>
<script lang="ts" src="./programmazione-preriscaldo.ts"></script>
@@ -0,0 +1,34 @@
import Vue from "vue";
import Component from "vue-class-component";
import { Prop } from "vue-property-decorator";
import { Deferred } from "@/services";
import { Modal, ModalHelper } from "@/components/modals";
import { messageService } from "@/_base";
@Component({ components: { modal: Modal } })
export default class Notes extends Vue {
@Prop()
deferred: Deferred<string>;
@Prop()
value: string;
note: string = null;
get Note() {
return this.note || this.value;
}
set Note(value: string) {
this.note = value;
}
save(value: string) {
this.deferred.resolve(this.Note);
ModalHelper.HideModal();
}
close() {
messageService.deleteChannel("esc_pressed");
this.deferred.reject();
ModalHelper.HideModal();
}
}
@@ -0,0 +1,26 @@
<template>
<div class="setup">
<modal type="save-as" :title="'save-as' | localize('Salva con nome')">
<div slot="header-buttons">
<button class="modal-close" @click="close()">
<i class="fa fa-remove"></i>
</button>
</div>
<section>
<article>
<label>{{'recipe_note' | localize('Note della ricetta')}}</label>
<textarea
rows="3"
v-model="Note"
:placeholder="'recipe_note' | localize('Note della ricetta')"
/>
</article>
</section>
<footer>
<button class="btn" @click="annulla()">{{'cancel' | localize("Annulla")}}</button>
<button class="btn btn-success" @click="save()">{{'confirm' | localize("Conferma")}}</button>
</footer>
</modal>
</div>
</template>
<script src="./changeNotes.ts" lang="ts"></script>
@@ -1,7 +1,36 @@
import Vue from "vue";
import Component from "vue-class-component";
import modal from "@/components/modals/modal.vue";
import { Deferred } from "@/services";
import { Prop } from "vue-property-decorator";
import { messageService } from "@/_base";
import { Modal, ModalHelper } from "@/components/modals";
@Component({})
@Component({ components: { modal: Modal } })
export default class SaveAs extends Vue {
@Prop()
deferred: Deferred<string>;
@Prop()
value: string;
recipeName: string = null;
get RecipeName() {
return this.recipeName || this.value;
}
set RecipeName(value: string) {
this.recipeName = value;
}
save(value: string) {
this.deferred.resolve(this.RecipeName);
ModalHelper.HideModal();
}
close() {
messageService.deleteChannel("esc_pressed");
this.deferred.reject();
ModalHelper.HideModal();
}
}
@@ -8,18 +8,12 @@
</div>
<section>
<article>
<div class="input-area mb-10">
<label>{{'recipe_name' | localize('Nome della ricetta')}}</label>
<input
class="custom"
v-model="searchText"
:placeholder="'recipe_name' | localize('Nome della ricetta')"
/>
</div>
<label>{{'recipe_name' | localize('Nome della ricetta')}}</label>
<input v-model="RecipeName" :placeholder="'recipe_name' | localize('Nome della ricetta')" />
</article>
</section>
<footer>
<button class="btn" @click="annulla()">{{'cancel' | localize("Annulla")}}</button>
<button class="btn" @click="close()">{{'cancel' | localize("Annulla")}}</button>
<button class="btn btn-success" @click="save()">{{'confirm' | localize("Conferma")}}</button>
</footer>
</modal>
@@ -6,7 +6,10 @@
<template v-if="recipe.cycle_loader_enable.status.visible">
<div class="input-area">
<label>{{'cycle_loader_enable'|localize('Abilitazione')}}</label>
<toggle-button v-model="recipe.cycle_loader_enable.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.cycle_loader_enable.setpointHMI"
:status="recipe.cycle_loader_enable.status"
></toggle-button>
</div>
</template>
<hr />
@@ -48,37 +51,55 @@
<template v-if="recipe.cycle_loader_center_x.status.visible">
<div class="input-area">
<label>{{'cycle_loader_center_x'|localize('Centratura X')}}</label>
<toggle-button v-model="recipe.cycle_loader_center_x.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.cycle_loader_center_x.setpointHMI"
:status="recipe.cycle_loader_center_x.status"
></toggle-button>
</div>
</template>
<template v-if="recipe.cycle_loader_center_y.status.visible">
<div class="input-area">
<label>{{'cycle_loader_center_y'|localize('Centratura Y')}}</label>
<toggle-button v-model="recipe.cycle_loader_center_y.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.cycle_loader_center_y.setpointHMI"
:status="recipe.cycle_loader_center_y.status"
></toggle-button>
</div>
</template>
<template v-if="recipe.cycle_loader_checktichness_enabled.status.visible">
<div class="input-area">
<label>{{'cycle_loader_checktichness_enabled'|localize('Controllo spessore')}}</label>
<toggle-button v-model="recipe.cycle_loader_checktichness_enabled.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.cycle_loader_checktichness_enabled.setpointHMI"
:status="recipe.cycle_loader_checktichness_enabled.status"
></toggle-button>
</div>
</template>
<template v-if="recipe.cycle_loader_suckers_vacuum.status.visible">
<div class="input-area">
<label>{{'cycle_loader_suckers_vacuum'|localize('Vuoto ventose')}}</label>
<toggle-button v-model="recipe.cycle_loader_suckers_vacuum.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.cycle_loader_suckers_vacuum.setpointHMI"
:status="recipe.cycle_loader_suckers_vacuum.status"
></toggle-button>
</div>
</template>
<template v-if="recipe.cycle_loader_ionizer_enabled.status.visible">
<div class="input-area">
<label>{{'cycle_loader_ionizer_enabled'|localize('Abilitazione ionizzatore')}}</label>
<toggle-button v-model="recipe.cycle_loader_ionizer_enabled.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.cycle_loader_ionizer_enabled.setpointHMI"
:status="recipe.cycle_loader_ionizer_enabled.status"
></toggle-button>
</div>
</template>
<template v-if="recipe.cycle_loader_manualunloading_enabled.status.visible">
<div class="input-area">
<label>{{'cycle_loader_manualunloading_enabled'|localize('Funzione scarico pezzo manuale')}}</label>
<toggle-button v-model="recipe.cycle_loader_manualunloading_enabled.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.cycle_loader_manualunloading_enabled.setpointHMI"
:status="recipe.cycle_loader_manualunloading_enabled.status"
></toggle-button>
</div>
</template>
</div>
@@ -12,19 +12,28 @@
<template v-if="recipe.cycle_forming_pause_cycle.status.visible">
<div class="input-area">
<label>{{'cycle_forming_pause_cycle'|localize('Pausa ciclo')}}</label>
<toggle-button v-model="recipe.cycle_forming_pause_cycle.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.cycle_forming_pause_cycle.setpointHMI"
:status="recipe.cycle_forming_pause_cycle.status"
></toggle-button>
</div>
</template>
<template v-if="recipe.cycle_forming_cooling_enabled.status.visible">
<div class="input-area">
<label>{{'cycle_forming_cooling_enabled'|localize('Raffreddamento fine ciclo')}}</label>
<toggle-button v-model="recipe.cycle_forming_cooling_enabled.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.cycle_forming_cooling_enabled.setpointHMI"
:status="recipe.cycle_forming_cooling_enabled.status"
></toggle-button>
</div>
</template>
<template v-if="recipe.cycle_forming_blowingbox_enabled.status.visible">
<div class="input-area">
<label>{{'cycle_forming_blowingbox_enabled'|localize('Ventilazione cassone fine ciclo')}}</label>
<toggle-button v-model="recipe.cycle_forming_blowingbox_enabled.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.cycle_forming_blowingbox_enabled.setpointHMI"
:status="recipe.cycle_forming_blowingbox_enabled.status"
></toggle-button>
</div>
</template>
</div>
@@ -7,7 +7,10 @@
<template v-if="recipe.cycle_acrylicframe_enabled.status.visible">
<div class="input-area">
<label>{{'cycle_acrylicframe_enabled'|localize('Abilitazione')}}</label>
<toggle-button v-model="recipe.cycle_acrylicframe_enabled.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.cycle_acrylicframe_enabled.setpointHMI"
:status="recipe.cycle_acrylicframe_enabled.status"
></toggle-button>
</div>
</template>
<template v-if="recipe.cycle_acrylicframe_time.status.visible">
@@ -7,7 +7,10 @@
<template v-if="recipe.cycle_upperoverheating_enabled.status.visible">
<div class="input-area">
<label>{{'cycle_upperoverheating_enabled'|localize('Abilitazione')}}</label>
<toggle-button v-model="recipe.cycle_upperoverheating_enabled.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.cycle_upperoverheating_enabled.setpointHMI"
:status="recipe.cycle_upperoverheating_enabled.status"
></toggle-button>
</div>
</template>
<template v-if="recipe.cycle_upperoverheating_time.status.visible">
@@ -10,6 +10,7 @@ import { recipeActions } from "@/store/recipe.store";
import { store } from "@/store";
import { Deferred } from '@/services';
import { recipeService } from "@/services/recipeService";
import { debounce } from '@/_base/debounce';
@Component({ components: { modal: Modal, stepfooter: StepFooter, caricatore: Caricatore, cicloformatura: CicloFormatura } })
export default class ShowCicloInfo extends Vue {
@@ -27,36 +28,60 @@ export default class ShowCicloInfo extends Vue {
};
get payload() {
return {
cycle_forming_type: this.recipe.cycle_forming_type,
cycle_forming_pause_cycle: this.recipe.cycle_forming_pause_cycle,
cycle_forming_cooling_enabled: this.recipe.cycle_forming_cooling_enabled,
cycle_forming_blowingbox_enabled: this.recipe.cycle_forming_blowingbox_enabled,
cycle_acrylicframe_enabled: this.recipe.cycle_acrylicframe_enabled,
cycle_acrylicframe_time: this.recipe.cycle_acrylicframe_time,
cycle_upperoverheating_enabled: this.recipe.cycle_upperoverheating_enabled,
cycle_upperoverheating_time: this.recipe.cycle_upperoverheating_time,
cycle_crystallisation_type: this.recipe.cycle_crystallisation_type,
cycle_crystallisation_time: this.recipe.cycle_crystallisation_time,
cycle_loader_enable: this.recipe.cycle_loader_enable,
cycle_loader_lifter_lowerposition_delay: this.recipe.cycle_loader_lifter_lowerposition_delay,
cycle_loader_lifter_upperposition_delay: this.recipe.cycle_loader_lifter_upperposition_delay,
cycle_loader_split_sheet_time: this.recipe.cycle_loader_split_sheet_time,
cycle_loader_ejector_position: this.recipe.cycle_loader_ejector_position,
cycle_loader_pallet_height: this.recipe.cycle_loader_pallet_height,
cycle_loader_center_x: this.recipe.cycle_loader_center_x,
cycle_loader_center_y: this.recipe.cycle_loader_center_y,
cycle_loader_checktichness_enabled: this.recipe.cycle_loader_checktichness_enabled,
cycle_loader_suckers_vacuum: this.recipe.cycle_loader_suckers_vacuum,
cycle_loader_ionizer_enabled: this.recipe.cycle_loader_ionizer_enabled,
cycle_loader_manualunloading_enabled: this.recipe.cycle_loader_manualunloading_enabled,
};
}
@Watch('recipe', { deep: true })
async recipeChanged(n, o) {
await recipeService.Update(
{
cycle_forming_type: this.recipe.cycle_forming_type,
cycle_forming_pause_cycle: this.recipe.cycle_forming_pause_cycle,
cycle_forming_cooling_enabled: this.recipe.cycle_forming_cooling_enabled,
cycle_forming_blowingbox_enabled: this.recipe.cycle_forming_blowingbox_enabled,
cycle_acrylicframe_enabled: this.recipe.cycle_acrylicframe_enabled,
cycle_acrylicframe_time: this.recipe.cycle_acrylicframe_time,
cycle_upperoverheating_enabled: this.recipe.cycle_upperoverheating_enabled,
cycle_upperoverheating_time: this.recipe.cycle_upperoverheating_time,
cycle_crystallisation_type: this.recipe.cycle_crystallisation_type,
cycle_crystallisation_time: this.recipe.cycle_crystallisation_time,
cycle_loader_enable: this.recipe.cycle_loader_enable,
cycle_loader_lifter_lowerposition_delay: this.recipe.cycle_loader_lifter_lowerposition_delay,
cycle_loader_lifter_upperposition_delay: this.recipe.cycle_loader_lifter_upperposition_delay,
cycle_loader_split_sheet_time: this.recipe.cycle_loader_split_sheet_time,
cycle_loader_ejector_position: this.recipe.cycle_loader_ejector_position,
cycle_loader_pallet_height: this.recipe.cycle_loader_pallet_height,
cycle_loader_center_x: this.recipe.cycle_loader_center_x,
cycle_loader_center_y: this.recipe.cycle_loader_center_y,
cycle_loader_checktichness_enabled: this.recipe.cycle_loader_checktichness_enabled,
cycle_loader_suckers_vacuum: this.recipe.cycle_loader_suckers_vacuum,
cycle_loader_ionizer_enabled: this.recipe.cycle_loader_ionizer_enabled,
cycle_loader_manualunloading_enabled: this.recipe.cycle_loader_manualunloading_enabled,
}
);
this.debouncedRecipeSave()
};
debouncedRecipeSave = debounce(async () => await recipeService.Update(this.payload), 200);
hasErrors() {
let payload = this.recipe;
let errors = false;
for (const key in this.recipe) {
const el = payload[key] as Recipe.IValue;
if (el.status.hasError) errors = true;
}
return errors;
}
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;
}
return result;
}
hasEnabledFields(...fields: string[]) {
let result = false;
for (const field of fields) {
@@ -101,8 +126,8 @@ export default class ShowCicloInfo extends Vue {
// recipeActions.setCurrent(store, this.recipe);
await recipeService.Confirm('Cycle');
ModalHelper.HideModal();
this.deferred.resolve(1);
// ModalHelper.HideModal();
// this.deferred.resolve(1);
};
goTo(step) {
@@ -17,8 +17,16 @@
<cicloformatura v-if="show==0" :recipe="recipe"></cicloformatura>
<caricatore v-if="show==1" :recipe="recipe"></caricatore>
<footer>
<button class="btn" @click="annulla()">{{'cancel' | localize('Annulla')}}</button>
<button class="btn btn-success" @click="conferma()">{{'confirm' | localize('Conferma')}}</button>
<button
class="btn"
@click="annulla()"
:disabled="!hasChanges()"
>{{'cancel' | localize('Annulla')}}</button>
<button
class="btn btn-success"
@click="conferma()"
:disabled="hasErrors() || !hasChanges()"
>{{'confirm' | localize('Conferma')}}</button>
</footer>
</modal>
<stepfooter :current="2" @click="goTo"></stepfooter>
@@ -3,6 +3,7 @@ import Component from 'vue-class-component';
import { messageService } from "@/_base/messageService";
import setupButton from "./setupButton.vue";
import { Prop } from 'vue-property-decorator';
import { store } from '@/store';
@Component({ name: 'stepfooter', components: { setupButton } })
export default class StepFooter extends Vue {
@@ -13,4 +14,9 @@ export default class StepFooter extends Vue {
public showModalAtStep(step: number) {
this.$emit('click', step - this.current)
}
get overview() {
return store.state.recipe.overview;
}
}
@@ -4,77 +4,88 @@
@click="showModalAtStep(0)"
:class="{'current': current== 0}"
:phase="1"
title="Formato"
:title="'overview.general' | localize('Formato')"
:status="overview.general"
></setup-button>
<setup-button
@click="showModalAtStep(1)"
:class="{'current': current== 1}"
:phase="2"
title="Quota e velocità"
:title="'overview.positions' | localize('Quota e velocità')"
:status="overview.positions"
></setup-button>
<setup-button
@click="showModalAtStep(2)"
:class="{'current': current== 2}"
:phase="3"
title="Ciclo"
:title="'overview.cycle' | localize('Ciclo')"
:status="overview.cycle"
></setup-button>
<setup-button
@click="showModalAtStep(3)"
:class="{'current': current== 3}"
:phase="4"
title="Riscaldi"
:title="'overview.heats' | localize('Riscaldi')"
:status="overview.heats"
></setup-button>
<setup-button
@click="showModalAtStep(4)"
:class="{'current': current== 4}"
:phase="5"
title="Pirometro"
:title="'overview.pyrometer' | localize('Pirometro')"
:status="overview.pyrometer"
></setup-button>
<setup-button
@click="showModalAtStep(5)"
:class="{'current': current== 5}"
:phase="6"
title="Imbutitura"
:title="'overview.drawing' | localize('Imbutitura')"
:status="overview.drawing"
></setup-button>
<setup-button
@click="showModalAtStep(6)"
:class="{'current': current== 6}"
:phase="7"
title="Controstampo"
:title="'overview.upperPlate' | localize('Controstampo')"
:status="overview.upperPlate"
></setup-button>
<setup-button
@click="showModalAtStep(7)"
:class="{'current': current== 7}"
:phase="8"
title="Raffreddamento"
:title="'overview.cooling' | localize('Raffreddamento')"
:status="overview.cooling"
></setup-button>
<setup-button
@click="showModalAtStep(8)"
:class="{'current': current== 8}"
:phase="9"
title="Vuoto"
:title="'overview.vacuum' | localize('Vuoto')"
:status="overview.vacuum"
></setup-button>
<setup-button
@click="showModalAtStep(9)"
:class="{'current': current== 9}"
:phase="10"
title="Estrazione"
:title="'overview.extraction' | localize('Estrazione')"
:status="overview.extraction"
></setup-button>
<setup-button
@click="showModalAtStep(10)"
:class="{'current': current== 10}"
:phase="11"
title="Opzioni di lavorazione"
:title="'overview.options' | localize('Opzioni di lavorazione')"
:status="overview.options"
></setup-button>
</div>
</template>
@@ -6,7 +6,10 @@
<template v-if="recipe.upperplate_air_enable.status.visible">
<div class="input-area">
<label>{{'upperplate_air_enable'|localize('Abilitazione')}}</label>
<toggle-button v-model="recipe.upperplate_air_enable.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.upperplate_air_enable.setpointHMI"
:status="recipe.upperplate_air_enable.status"
></toggle-button>
</div>
</template>
<template v-if="recipe.upperplate_air_delay.status.visible">
@@ -59,7 +62,7 @@
<template v-if="recipe.upperplate_air_max_time.status.visible">
<div class="input-area">
<label>{{'upperplate_air_max_time'|localize('Durata massima')}}</label>
<numeric v-model="recipe.upperplate_air_max_time" />
<numeric v-model="recipe.upperplate_air_max_time" keyboard-position="top" />
</div>
<slider v-model="recipe.upperplate_air_max_time"></slider>
</template>
@@ -6,7 +6,10 @@
<template v-if="recipe.upperplate_extraction_enable.status.visible">
<div class="input-area">
<label>{{'upperplate_extraction_enable'|localize('Abilitazione')}}</label>
<toggle-button v-model="recipe.upperplate_extraction_enable.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.upperplate_extraction_enable.setpointHMI"
:status="recipe.upperplate_extraction_enable.status"
></toggle-button>
</div>
</template>
<template v-if="recipe.upperplate_extraction_delay.status.visible">
@@ -6,7 +6,10 @@
<template v-if="recipe.upperplate_vacuum_enable.status.visible">
<div class="input-area">
<label>{{'upperplate_vacuum_enable'|localize('Abilitazione')}}</label>
<toggle-button v-model="recipe.upperplate_vacuum_enable.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.upperplate_vacuum_enable.setpointHMI"
:status="recipe.upperplate_vacuum_enable.status"
></toggle-button>
</div>
</template>
<template v-if="recipe.upperplate_vacuum_delay.status.visible">
@@ -58,7 +61,7 @@
<template v-if="recipe.upperplate_vacuum_max_time.status.visible">
<div class="input-area">
<label>{{'upperplate_vacuum_max_time'|localize('Durata massima')}}</label>
<numeric v-model="recipe.upperplate_vacuum_max_time" />
<numeric v-model="recipe.upperplate_vacuum_max_time" keyboard-position="top" />
</div>
<slider v-model="recipe.upperplate_vacuum_max_time"></slider>
</template>
@@ -12,6 +12,7 @@ import { recipeActions } from "@/store/recipe.store";
import { store } from "@/store";
import { Deferred } from '@/services';
import { recipeService } from "@/services/recipeService";
import { debounce } from '@/_base/debounce';
@Component({
components: {
@@ -39,38 +40,61 @@ export default class ShowControstampoInfo extends Vue {
@Watch('recipe', { deep: true })
async recipeChanged(n, o) {
await recipeService.Update(
{
upperplate_cycle_type: this.recipe.upperplate_cycle_type,
upperplate_cycle_delay: this.recipe.upperplate_cycle_delay,
upperplate_cycle_time: this.recipe.upperplate_cycle_time,
upperplate_air_enable: this.recipe.upperplate_air_enable,
upperplate_air_delay: this.recipe.upperplate_air_delay,
upperplate_air_max_time: this.recipe.upperplate_air_max_time,
upperplate_air_1_chart_setpointx: this.recipe.upperplate_air_1_chart_setpointx,
upperplate_air_1_chart_setpointy: this.recipe.upperplate_air_1_chart_setpointy,
upperplate_air_2_chart_setpointx: this.recipe.upperplate_air_2_chart_setpointx,
upperplate_air_2_chart_setpointy: this.recipe.upperplate_air_2_chart_setpointy,
upperplate_air_3_chart_setpointx: this.recipe.upperplate_air_3_chart_setpointx,
upperplate_air_3_chart_setpointy: this.recipe.upperplate_air_3_chart_setpointy,
upperplate_air_manual: this.recipe.upperplate_air_manual,
upperplate_vacuum_enable: this.recipe.upperplate_vacuum_enable,
upperplate_vacuum_delay: this.recipe.upperplate_vacuum_delay,
upperplate_vacuum_max_time: this.recipe.upperplate_vacuum_max_time,
upperplate_vacuum_1_chart_setpointx: this.recipe.upperplate_vacuum_1_chart_setpointx,
upperplate_vacuum_1_chart_setpointy: this.recipe.upperplate_vacuum_1_chart_setpointy,
upperplate_vacuum_2_chart_setpointx: this.recipe.upperplate_vacuum_2_chart_setpointx,
upperplate_vacuum_2_chart_setpointy: this.recipe.upperplate_vacuum_2_chart_setpointy,
upperplate_vacuum_3_chart_setpointx: this.recipe.upperplate_vacuum_3_chart_setpointx,
upperplate_vacuum_3_chart_setpointy: this.recipe.upperplate_vacuum_3_chart_setpointy,
upperplate_vacuum_manual: this.recipe.upperplate_vacuum_manual,
upperplate_extraction_enable: this.recipe.upperplate_extraction_enable,
upperplate_extraction_delay: this.recipe.upperplate_extraction_delay,
upperplate_extraction_1_chart_setpointx: this.recipe.upperplate_extraction_1_chart_setpointx,
upperplate_extraction_1_chart_setpointy: this.recipe.upperplate_extraction_1_chart_setpointy,
upperplate_extraction_manual: this.recipe.upperplate_extraction_manual,
}
);
this.debouncedRecipeSave()
};
debouncedRecipeSave = debounce(async () => await recipeService.Update(this.payload), 200);
get payload() {
return {
upperplate_cycle_type: this.recipe.upperplate_cycle_type,
upperplate_cycle_delay: this.recipe.upperplate_cycle_delay,
upperplate_cycle_time: this.recipe.upperplate_cycle_time,
upperplate_air_enable: this.recipe.upperplate_air_enable,
upperplate_air_delay: this.recipe.upperplate_air_delay,
upperplate_air_max_time: this.recipe.upperplate_air_max_time,
upperplate_air_1_chart_setpointx: this.recipe.upperplate_air_1_chart_setpointx,
upperplate_air_1_chart_setpointy: this.recipe.upperplate_air_1_chart_setpointy,
upperplate_air_2_chart_setpointx: this.recipe.upperplate_air_2_chart_setpointx,
upperplate_air_2_chart_setpointy: this.recipe.upperplate_air_2_chart_setpointy,
upperplate_air_3_chart_setpointx: this.recipe.upperplate_air_3_chart_setpointx,
upperplate_air_3_chart_setpointy: this.recipe.upperplate_air_3_chart_setpointy,
upperplate_air_manual: this.recipe.upperplate_air_manual,
upperplate_vacuum_enable: this.recipe.upperplate_vacuum_enable,
upperplate_vacuum_delay: this.recipe.upperplate_vacuum_delay,
upperplate_vacuum_max_time: this.recipe.upperplate_vacuum_max_time,
upperplate_vacuum_1_chart_setpointx: this.recipe.upperplate_vacuum_1_chart_setpointx,
upperplate_vacuum_1_chart_setpointy: this.recipe.upperplate_vacuum_1_chart_setpointy,
upperplate_vacuum_2_chart_setpointx: this.recipe.upperplate_vacuum_2_chart_setpointx,
upperplate_vacuum_2_chart_setpointy: this.recipe.upperplate_vacuum_2_chart_setpointy,
upperplate_vacuum_3_chart_setpointx: this.recipe.upperplate_vacuum_3_chart_setpointx,
upperplate_vacuum_3_chart_setpointy: this.recipe.upperplate_vacuum_3_chart_setpointy,
upperplate_vacuum_manual: this.recipe.upperplate_vacuum_manual,
upperplate_extraction_enable: this.recipe.upperplate_extraction_enable,
upperplate_extraction_delay: this.recipe.upperplate_extraction_delay,
upperplate_extraction_1_chart_setpointx: this.recipe.upperplate_extraction_1_chart_setpointx,
upperplate_extraction_1_chart_setpointy: this.recipe.upperplate_extraction_1_chart_setpointy,
upperplate_extraction_manual: this.recipe.upperplate_extraction_manual,
}
}
hasErrors() {
let payload = this.recipe;
let errors = false;
for (const key in this.recipe) {
const el = payload[key] as Recipe.IValue;
if (el.status.hasError) errors = true;
}
return errors;
}
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;
}
return result;
}
hasEnabledFields(...fields: string[]) {
@@ -134,8 +158,8 @@ export default class ShowControstampoInfo extends Vue {
// recipeActions.setCurrent(store, this.recipe);
await recipeService.Confirm('UpperPlate');
ModalHelper.HideModal();
this.deferred.resolve(1);
// ModalHelper.HideModal();
// this.deferred.resolve(1);
};
goTo(step) {
@@ -33,8 +33,16 @@
<vuotocontrostampo v-if="show==2" :recipe="recipe"></vuotocontrostampo>
<estrazionecontrostampo v-if="show==3" :recipe="recipe"></estrazionecontrostampo>
<footer>
<button class="btn" @click="annulla()">{{'cancel' | localize('Annulla')}}</button>
<button class="btn btn-success" @click="conferma()">{{'confirm' | localize('Conferma')}}</button>
<button
class="btn"
@click="annulla()"
:disabled="!hasChanges()"
>{{'cancel' | localize('Annulla')}}</button>
<button
class="btn btn-success"
@click="conferma()"
:disabled="hasErrors() || !hasChanges()"
>{{'confirm' | localize('Conferma')}}</button>
</footer>
</modal>
<stepfooter :current="6" @click="goTo"></stepfooter>
@@ -6,7 +6,10 @@
<template v-if="recipe.extraction_aux_enabled.status.visible">
<div class="input-area">
<label>{{'extraction_aux_enabled'|localize('Abilitazione')}}</label>
<toggle-button v-model="recipe.extraction_aux_enabled.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.extraction_aux_enabled.setpointHMI"
:status="recipe.extraction_aux_enabled.status"
></toggle-button>
</div>
</template>
<template v-if="recipe.extraction_aux_delay.status.visible">
@@ -10,6 +10,7 @@ import { recipeActions } from "@/store/recipe.store";
import { store } from "@/store";
import { Deferred } from '@/services';
import { recipeService } from "@/services/recipeService";
import { debounce } from '@/_base/debounce';
@Component({
components:
@@ -36,22 +37,44 @@ export default class ShowEstrazioneInfo extends Vue {
@Watch('recipe', { deep: true })
async recipeChanged(n, o) {
this.debouncedRecipeSave()
};
await recipeService.Update(
{
extraction_main_type: this.recipe.extraction_main_type,
extraction_main_mould_dw_delay: this.recipe.extraction_main_mould_dw_delay,
extraction_main_delay: this.recipe.extraction_main_delay,
extraction_main_1_chart_setpointx: this.recipe.extraction_main_1_chart_setpointx,
extraction_main_1_chart_setpointy: this.recipe.extraction_main_1_chart_setpointy,
extraction_main_manual: this.recipe.extraction_main_manual,
extraction_aux_enabled: this.recipe.extraction_aux_enabled,
extraction_aux_delay: this.recipe.extraction_aux_delay,
extraction_aux_1_chart_setpointx: this.recipe.extraction_aux_1_chart_setpointx,
extraction_aux_1_chart_setpointy: this.recipe.extraction_aux_1_chart_setpointy,
extraction_aux_manual: this.recipe.extraction_aux_manual,
}
);
debouncedRecipeSave = debounce(async () => await recipeService.Update(this.payload), 200);
get payload() {
return {
extraction_main_type: this.recipe.extraction_main_type,
extraction_main_mould_dw_delay: this.recipe.extraction_main_mould_dw_delay,
extraction_main_delay: this.recipe.extraction_main_delay,
extraction_main_1_chart_setpointx: this.recipe.extraction_main_1_chart_setpointx,
extraction_main_1_chart_setpointy: this.recipe.extraction_main_1_chart_setpointy,
extraction_main_manual: this.recipe.extraction_main_manual,
extraction_aux_enabled: this.recipe.extraction_aux_enabled,
extraction_aux_delay: this.recipe.extraction_aux_delay,
extraction_aux_1_chart_setpointx: this.recipe.extraction_aux_1_chart_setpointx,
extraction_aux_1_chart_setpointy: this.recipe.extraction_aux_1_chart_setpointy,
extraction_aux_manual: this.recipe.extraction_aux_manual,
};
}
hasErrors() {
let payload = this.recipe;
let errors = false;
for (const key in this.recipe) {
const el = payload[key] as Recipe.IValue;
if (el.status.hasError) errors = true;
}
return errors;
}
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;
}
return result;
}
hasEnabledFields(...fields: string[]) {
@@ -86,8 +109,8 @@ export default class ShowEstrazioneInfo extends Vue {
// recipeActions.setCurrent(store, this.recipe);
await recipeService.Confirm('Extraction');
ModalHelper.HideModal();
this.deferred.resolve(1);
// ModalHelper.HideModal();
// this.deferred.resolve(1);
};
goTo(step) {
@@ -21,8 +21,16 @@
<estrprincipale v-if="show==0" :recipe="recipe"></estrprincipale>
<estrsecondaria v-if="show==1" :recipe="recipe"></estrsecondaria>
<footer>
<button class="btn" @click="annulla()">{{'cancel' | localize('Annulla')}}</button>
<button class="btn btn-success" @click="conferma()">{{'confirm' | localize('Conferma')}}</button>
<button
class="btn"
@click="annulla()"
:disabled="!hasChanges()"
>{{'cancel' | localize('Annulla')}}</button>
<button
class="btn btn-success"
@click="conferma()"
:disabled="hasErrors() || !hasChanges()"
>{{'confirm' | localize('Conferma')}}</button>
</footer>
</modal>
<stepfooter :current="9" @click="goTo"></stepfooter>
@@ -17,7 +17,6 @@
<numeric v-model="recipe.general_sizes_frame_dim_x" id="general_sizes_frame_dim_x" />
</div>
<slider v-model="recipe.general_sizes_frame_dim_x"></slider>
<button class="submit">Muovi</button>
</template>
<template v-if="recipe.general_sizes_frame_dim_y.status.visible">
<div class="input-area">
@@ -25,7 +24,6 @@
<numeric v-model="recipe.general_sizes_frame_dim_y" id="general_sizes_frame_dim_y" />
</div>
<slider v-model="recipe.general_sizes_frame_dim_y"></slider>
<button class="submit">Muovi</button>
</template>
</div>
</div>
@@ -17,7 +17,6 @@
<numeric v-model="recipe.general_sizes_plate_dim_x" id="general_sizes_plate_dim_x" />
</div>
<slider v-model="recipe.general_sizes_plate_dim_x"></slider>
<button class="submit">Muovi</button>
</template>
<template v-if="recipe.general_sizes_plate_dim_y.status.visible">
<div class="input-area">
@@ -25,7 +24,6 @@
<numeric v-model="recipe.general_sizes_plate_dim_y" id="general_sizes_plate_dim_y" />
</div>
<slider v-model="recipe.general_sizes_plate_dim_y"></slider>
<button class="submit">Muovi</button>
</template>
</div>
</div>
@@ -19,6 +19,7 @@ import { recipeActions } from "@/store/recipe.store";
import { store } from "@/store";
import { Deferred } from "@/services";
import { recipeService } from "@/services/recipeService";
import { debounce } from "@/_base/debounce";
@Component({
components: {
@@ -57,35 +58,58 @@ export default class ShowFormatoInfo extends Vue {
@Watch('recipe', { deep: true })
async recipeChanged(n, o) {
await recipeService.Update(
{
general_sizes_mould_dim_x: this.recipe.general_sizes_mould_dim_x,
general_sizes_mould_dim_y: this.recipe.general_sizes_mould_dim_y,
general_sizes_mould_max_height: this.recipe.general_sizes_mould_max_height,
general_sizes_mould_min_height: this.recipe.general_sizes_mould_min_height,
general_sizes_mould_base_height: this.recipe.general_sizes_mould_base_height,
general_sizes_sheet_material: this.recipe.general_sizes_sheet_material,
general_sizes_sheet_dim_x: this.recipe.general_sizes_sheet_dim_x,
general_sizes_sheet_dim_y: this.recipe.general_sizes_sheet_dim_y,
general_sizes_sheet_thickness: this.recipe.general_sizes_sheet_thickness,
general_sizes_plate_type: this.recipe.general_sizes_plate_type,
general_sizes_plate_dim_x: this.recipe.general_sizes_plate_dim_x,
general_sizes_plate_dim_y: this.recipe.general_sizes_plate_dim_y,
general_sizes_frame_traverses: this.recipe.general_sizes_frame_traverses,
general_sizes_frame_dim_x: this.recipe.general_sizes_frame_dim_x,
general_sizes_frame_dim_y: this.recipe.general_sizes_frame_dim_y,
general_sizes_upperplate_max_height: this.recipe.general_sizes_upperplate_max_height,
general_area_working_dxsx: this.recipe.general_area_working_dxsx,
}
);
this.debouncedRecipeSave()
};
debouncedRecipeSave = debounce(async () => await recipeService.Update(this.payload), 200);
get payload() {
return {
general_sizes_mould_dim_x: this.recipe.general_sizes_mould_dim_x,
general_sizes_mould_dim_y: this.recipe.general_sizes_mould_dim_y,
general_sizes_mould_max_height: this.recipe.general_sizes_mould_max_height,
general_sizes_mould_min_height: this.recipe.general_sizes_mould_min_height,
general_sizes_mould_base_height: this.recipe.general_sizes_mould_base_height,
general_sizes_sheet_material: this.recipe.general_sizes_sheet_material,
general_sizes_sheet_dim_x: this.recipe.general_sizes_sheet_dim_x,
general_sizes_sheet_dim_y: this.recipe.general_sizes_sheet_dim_y,
general_sizes_sheet_thickness: this.recipe.general_sizes_sheet_thickness,
general_sizes_plate_type: this.recipe.general_sizes_plate_type,
general_sizes_plate_dim_x: this.recipe.general_sizes_plate_dim_x,
general_sizes_plate_dim_y: this.recipe.general_sizes_plate_dim_y,
general_sizes_frame_traverses: this.recipe.general_sizes_frame_traverses,
general_sizes_frame_dim_x: this.recipe.general_sizes_frame_dim_x,
general_sizes_frame_dim_y: this.recipe.general_sizes_frame_dim_y,
general_sizes_upperplate_max_height: this.recipe.general_sizes_upperplate_max_height,
general_area_working_dxsx: this.recipe.general_area_working_dxsx,
};
}
hasErrors() {
let payload = this.recipe;
let errors = false;
for (const key in this.recipe) {
const el = payload[key] as Recipe.IValue;
if (el.status.hasError) errors = true;
}
return errors;
}
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;
}
return result;
}
async conferma() {
// recipeActions.setCurrent(store, this.recipe);
await recipeService.Confirm('General');
ModalHelper.HideModal();
this.deferred.resolve(1);
// ModalHelper.HideModal();
// this.deferred.resolve(1);
};
goTo(step) {
@@ -70,8 +70,16 @@
</article>
</section>
<footer>
<button class="btn" @click="annulla()">Annulla</button>
<button class="btn btn-success" @click="conferma()">Conferma</button>
<button
class="btn"
@click="annulla()"
:disabled="!hasChanges()"
>{{'cancel' | localize('Annulla')}}</button>
<button
class="btn btn-success"
@click="conferma()"
:disabled="hasErrors() || !hasChanges()"
>{{'confirm' | localize('Conferma')}}</button>
</footer>
</modal>
<stepfooter :current="0" @click="goTo"></stepfooter>
@@ -11,6 +11,7 @@ import { store } from "@/store";
import { Deferred } from "@/services";
import { recipeService } from "@/services/recipeService";
import svgChart from "@/app_modules_thermo/components/svgChart.vue";
import { debounce } from "@/_base/debounce";
@Component({
components: {
@@ -47,25 +48,48 @@ export default class ShowImbutituraInfo extends Vue {
@Watch('recipe', { deep: true })
async recipeChanged(n, o) {
await recipeService.Update(
{
drawing_type: this.recipe.drawing_type,
drawing_height: this.recipe.drawing_height,
drawing_delay: this.recipe.drawing_delay,
drawing_1_chart_setpointx: this.recipe.drawing_1_chart_setpointx,
drawing_1_chart_setpointy: this.recipe.drawing_1_chart_setpointy,
drawing_photocell: this.recipe.drawing_photocell,
drawing_mantaining_flow: this.recipe.drawing_mantaining_flow,
drawing_manual: this.recipe.drawing_manual,
drawing_mould_up_delay: this.recipe.drawing_mould_up_delay,
}
);
this.debouncedRecipeSave()
};
debouncedRecipeSave = debounce(async () => await recipeService.Update(this.payload), 200);
get payload() {
return {
drawing_type: this.recipe.drawing_type,
drawing_height: this.recipe.drawing_height,
drawing_delay: this.recipe.drawing_delay,
drawing_1_chart_setpointx: this.recipe.drawing_1_chart_setpointx,
drawing_1_chart_setpointy: this.recipe.drawing_1_chart_setpointy,
drawing_photocell: this.recipe.drawing_photocell,
drawing_mantaining_flow: this.recipe.drawing_mantaining_flow,
drawing_manual: this.recipe.drawing_manual,
drawing_mould_up_delay: this.recipe.drawing_mould_up_delay,
};
}
hasErrors() {
let payload = this.recipe;
let errors = false;
for (const key in this.recipe) {
const el = payload[key] as Recipe.IValue;
if (el.status.hasError) errors = true;
}
return errors;
}
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;
}
return result;
}
async conferma(name: string) {
await recipeService.Confirm('Drawing');
ModalHelper.HideModal();
this.deferred.resolve(1);
// ModalHelper.HideModal();
// this.deferred.resolve(1);
};
goTo(step) {
@@ -80,12 +80,16 @@
</article>
</section>
<footer>
<button class="btn" @click="annulla()">
<label>Annulla</label>
</button>
<button class="btn btn-success" @click="conferma()">
<label>Conferma</label>
</button>
<button
class="btn"
@click="annulla()"
:disabled="!hasChanges()"
>{{'cancel' | localize('Annulla')}}</button>
<button
class="btn btn-success"
@click="conferma()"
:disabled="hasErrors() || !hasChanges()"
>{{'confirm' | localize('Conferma')}}</button>
</footer>
</modal>
<stepfooter :current="5" @click="goTo"></stepfooter>
@@ -4,7 +4,7 @@
<template v-if="abilitazione.status.visible">
<div class="input-area">
<label>{{'options_thermoregulator__enabled'|localize('Abilitazione')}}</label>
<toggle-button v-model="abilitazione.setpointHMI"></toggle-button>
<toggle-button v-model="abilitazione.setpointHMI" :status="abilitazione.status"></toggle-button>
</div>
</template>
<template v-if="setpoint.status.visible">
@@ -11,6 +11,7 @@ import { store } from "@/store";
import { Prop, Watch } from "vue-property-decorator";
import { Deferred } from "@/services";
import { recipeService } from "@/services/recipeService";
import { debounce } from "@/_base/debounce";
@Component({
components: {
@@ -38,118 +39,141 @@ export default class ShowOpzioniInfo extends Vue {
@Watch('recipe', { deep: true })
async recipeChanged(n, o) {
await recipeService.Update(
{
options_undercutmould_1_mode: this.recipe.options_undercutmould_1_mode,
options_undercutmould_1_position: this.recipe.options_undercutmould_1_position,
options_undercutmould_1_delay_acti: this.recipe.options_undercutmould_1_delay_acti,
options_undercutmould_1_delay_dis: this.recipe.options_undercutmould_1_delay_dis,
options_undercutmould_2_mode: this.recipe.options_undercutmould_2_mode,
options_undercutmould_2_position: this.recipe.options_undercutmould_2_position,
options_undercutmould_2_delay_acti: this.recipe.options_undercutmould_2_delay_acti,
options_undercutmould_2_delay_dis: this.recipe.options_undercutmould_2_delay_dis,
options_undercutmould_3_mode: this.recipe.options_undercutmould_3_mode,
options_undercutmould_3_position: this.recipe.options_undercutmould_3_position,
options_undercutmould_3_delay_acti: this.recipe.options_undercutmould_3_delay_acti,
options_undercutmould_3_delay_dis: this.recipe.options_undercutmould_3_delay_dis,
options_undercutmould_4_mode: this.recipe.options_undercutmould_4_mode,
options_undercutmould_4_position: this.recipe.options_undercutmould_4_position,
options_undercutmould_4_delay_acti: this.recipe.options_undercutmould_4_delay_acti,
options_undercutmould_4_delay_dis: this.recipe.options_undercutmould_4_delay_dis,
options_undercutmould_5_mode: this.recipe.options_undercutmould_5_mode,
options_undercutmould_5_position: this.recipe.options_undercutmould_5_position,
options_undercutmould_5_delay_acti: this.recipe.options_undercutmould_5_delay_acti,
options_undercutmould_5_delay_dis: this.recipe.options_undercutmould_5_delay_dis,
options_undercutmould_6_mode: this.recipe.options_undercutmould_6_mode,
options_undercutmould_6_position: this.recipe.options_undercutmould_6_position,
options_undercutmould_6_delay_acti: this.recipe.options_undercutmould_6_delay_acti,
options_undercutmould_6_delay_dis: this.recipe.options_undercutmould_6_delay_dis,
options_undercutmould_7_mode: this.recipe.options_undercutmould_7_mode,
options_undercutmould_7_position: this.recipe.options_undercutmould_7_position,
options_undercutmould_7_delay_acti: this.recipe.options_undercutmould_7_delay_acti,
options_undercutmould_7_delay_dis: this.recipe.options_undercutmould_7_delay_dis,
options_undercutmould_8_mode: this.recipe.options_undercutmould_8_mode,
options_undercutmould_8_position: this.recipe.options_undercutmould_8_position,
options_undercutmould_8_delay_acti: this.recipe.options_undercutmould_8_delay_acti,
options_undercutmould_8_delay_dis: this.recipe.options_undercutmould_8_delay_dis,
options_undercutmould_9_mode: this.recipe.options_undercutmould_9_mode,
options_undercutmould_9_position: this.recipe.options_undercutmould_9_position,
options_undercutmould_9_delay_acti: this.recipe.options_undercutmould_9_delay_acti,
options_undercutmould_9_delay_dis: this.recipe.options_undercutmould_9_delay_dis,
options_undercutmould_10_mode: this.recipe.options_undercutmould_10_mode,
options_undercutmould_10_position: this.recipe.options_undercutmould_10_position,
options_undercutmould_10_delay_acti: this.recipe.options_undercutmould_10_delay_acti,
options_undercutmould_10_delay_dis: this.recipe.options_undercutmould_10_delay_dis,
options_undercutupperplate_1_mode: this.recipe.options_undercutupperplate_1_mode,
options_undercutupperplate_1_position: this.recipe.options_undercutupperplate_1_position,
options_undercutupperplate_1_delay_acti: this.recipe.options_undercutupperplate_1_delay_acti,
options_undercutupperplate_1_delay_dis: this.recipe.options_undercutupperplate_1_delay_dis,
options_undercutupperplate_2_mode: this.recipe.options_undercutupperplate_2_mode,
options_undercutupperplate_2_position: this.recipe.options_undercutupperplate_2_position,
options_undercutupperplate_2_delay_acti: this.recipe.options_undercutupperplate_2_delay_acti,
options_undercutupperplate_2_delay_dis: this.recipe.options_undercutupperplate_2_delay_dis,
options_undercutupperplate_3_mode: this.recipe.options_undercutupperplate_3_mode,
options_undercutupperplate_3_position: this.recipe.options_undercutupperplate_3_position,
options_undercutupperplate_3_delay_acti: this.recipe.options_undercutupperplate_3_delay_acti,
options_undercutupperplate_3_delay_dis: this.recipe.options_undercutupperplate_3_delay_dis,
options_undercutupperplate_4_mode: this.recipe.options_undercutupperplate_4_mode,
options_undercutupperplate_4_position: this.recipe.options_undercutupperplate_4_position,
options_undercutupperplate_4_delay_acti: this.recipe.options_undercutupperplate_4_delay_acti,
options_undercutupperplate_4_delay_dis: this.recipe.options_undercutupperplate_4_delay_dis,
options_undercutupperplate_5_mode: this.recipe.options_undercutupperplate_5_mode,
options_undercutupperplate_5_position: this.recipe.options_undercutupperplate_5_position,
options_undercutupperplate_5_delay_acti: this.recipe.options_undercutupperplate_5_delay_acti,
options_undercutupperplate_5_delay_dis: this.recipe.options_undercutupperplate_5_delay_dis,
options_undercutupperplate_6_mode: this.recipe.options_undercutupperplate_6_mode,
options_undercutupperplate_6_position: this.recipe.options_undercutupperplate_6_position,
options_undercutupperplate_6_delay_acti: this.recipe.options_undercutupperplate_6_delay_acti,
options_undercutupperplate_6_delay_dis: this.recipe.options_undercutupperplate_6_delay_dis,
options_undercutupperplate_7_mode: this.recipe.options_undercutupperplate_7_mode,
options_undercutupperplate_7_position: this.recipe.options_undercutupperplate_7_position,
options_undercutupperplate_7_delay_acti: this.recipe.options_undercutupperplate_7_delay_acti,
options_undercutupperplate_7_delay_dis: this.recipe.options_undercutupperplate_7_delay_dis,
options_undercutupperplate_8_mode: this.recipe.options_undercutupperplate_8_mode,
options_undercutupperplate_8_position: this.recipe.options_undercutupperplate_8_position,
options_undercutupperplate_8_delay_acti: this.recipe.options_undercutupperplate_8_delay_acti,
options_undercutupperplate_8_delay_dis: this.recipe.options_undercutupperplate_8_delay_dis,
options_undercutupperplate_9_mode: this.recipe.options_undercutupperplate_9_mode,
options_undercutupperplate_9_position: this.recipe.options_undercutupperplate_9_position,
options_undercutupperplate_9_delay_acti: this.recipe.options_undercutupperplate_9_delay_acti,
options_undercutupperplate_9_delay_dis: this.recipe.options_undercutupperplate_9_delay_dis,
options_undercutupperplate_10_mode: this.recipe.options_undercutupperplate_10_mode,
options_undercutupperplate_10_position: this.recipe.options_undercutupperplate_10_position,
options_undercutupperplate_10_delay_acti: this.recipe.options_undercutupperplate_10_delay_acti,
options_undercutupperplate_10_delay_dis: this.recipe.options_undercutupperplate_10_delay_dis,
options_thermoregulator_1_enabled: this.recipe.options_thermoregulator_1_enabled,
options_thermoregulator_1_setpoint: this.recipe.options_thermoregulator_1_setpoint,
options_thermoregulator_2_enabled: this.recipe.options_thermoregulator_2_enabled,
options_thermoregulator_2_setpoint: this.recipe.options_thermoregulator_2_setpoint,
options_thermoregulator_3_enabled: this.recipe.options_thermoregulator_3_enabled,
options_thermoregulator_3_setpoint: this.recipe.options_thermoregulator_3_setpoint,
options_thermoregulator_4_enabled: this.recipe.options_thermoregulator_4_enabled,
options_thermoregulator_4_setpoint: this.recipe.options_thermoregulator_4_setpoint,
options_thermoregulator_5_enabled: this.recipe.options_thermoregulator_5_enabled,
options_thermoregulator_5_setpoint: this.recipe.options_thermoregulator_5_setpoint,
options_thermoregulator_6_enabled: this.recipe.options_thermoregulator_6_enabled,
options_thermoregulator_6_setpoint: this.recipe.options_thermoregulator_6_setpoint,
options_thermoregulator_7_enabled: this.recipe.options_thermoregulator_7_enabled,
options_thermoregulator_7_setpoint: this.recipe.options_thermoregulator_7_setpoint,
options_thermoregulator_8_enabled: this.recipe.options_thermoregulator_8_enabled,
options_thermoregulator_8_setpoint: this.recipe.options_thermoregulator_8_setpoint,
options_thermoregulator_9_enabled: this.recipe.options_thermoregulator_9_enabled,
options_thermoregulator_9_setpoint: this.recipe.options_thermoregulator_9_setpoint,
options_thermoregulator_10_enabled: this.recipe.options_thermoregulator_10_enabled,
options_thermoregulator_10_setpoint: this.recipe.options_thermoregulator_10_setpoint,
}
);
this.debouncedRecipeSave()
};
debouncedRecipeSave = debounce(async () => await recipeService.Update(this.payload), 200);
get payload() {
return {
options_undercutmould_1_mode: this.recipe.options_undercutmould_1_mode,
options_undercutmould_1_position: this.recipe.options_undercutmould_1_position,
options_undercutmould_1_delay_acti: this.recipe.options_undercutmould_1_delay_acti,
options_undercutmould_1_delay_dis: this.recipe.options_undercutmould_1_delay_dis,
options_undercutmould_2_mode: this.recipe.options_undercutmould_2_mode,
options_undercutmould_2_position: this.recipe.options_undercutmould_2_position,
options_undercutmould_2_delay_acti: this.recipe.options_undercutmould_2_delay_acti,
options_undercutmould_2_delay_dis: this.recipe.options_undercutmould_2_delay_dis,
options_undercutmould_3_mode: this.recipe.options_undercutmould_3_mode,
options_undercutmould_3_position: this.recipe.options_undercutmould_3_position,
options_undercutmould_3_delay_acti: this.recipe.options_undercutmould_3_delay_acti,
options_undercutmould_3_delay_dis: this.recipe.options_undercutmould_3_delay_dis,
options_undercutmould_4_mode: this.recipe.options_undercutmould_4_mode,
options_undercutmould_4_position: this.recipe.options_undercutmould_4_position,
options_undercutmould_4_delay_acti: this.recipe.options_undercutmould_4_delay_acti,
options_undercutmould_4_delay_dis: this.recipe.options_undercutmould_4_delay_dis,
options_undercutmould_5_mode: this.recipe.options_undercutmould_5_mode,
options_undercutmould_5_position: this.recipe.options_undercutmould_5_position,
options_undercutmould_5_delay_acti: this.recipe.options_undercutmould_5_delay_acti,
options_undercutmould_5_delay_dis: this.recipe.options_undercutmould_5_delay_dis,
options_undercutmould_6_mode: this.recipe.options_undercutmould_6_mode,
options_undercutmould_6_position: this.recipe.options_undercutmould_6_position,
options_undercutmould_6_delay_acti: this.recipe.options_undercutmould_6_delay_acti,
options_undercutmould_6_delay_dis: this.recipe.options_undercutmould_6_delay_dis,
options_undercutmould_7_mode: this.recipe.options_undercutmould_7_mode,
options_undercutmould_7_position: this.recipe.options_undercutmould_7_position,
options_undercutmould_7_delay_acti: this.recipe.options_undercutmould_7_delay_acti,
options_undercutmould_7_delay_dis: this.recipe.options_undercutmould_7_delay_dis,
options_undercutmould_8_mode: this.recipe.options_undercutmould_8_mode,
options_undercutmould_8_position: this.recipe.options_undercutmould_8_position,
options_undercutmould_8_delay_acti: this.recipe.options_undercutmould_8_delay_acti,
options_undercutmould_8_delay_dis: this.recipe.options_undercutmould_8_delay_dis,
options_undercutmould_9_mode: this.recipe.options_undercutmould_9_mode,
options_undercutmould_9_position: this.recipe.options_undercutmould_9_position,
options_undercutmould_9_delay_acti: this.recipe.options_undercutmould_9_delay_acti,
options_undercutmould_9_delay_dis: this.recipe.options_undercutmould_9_delay_dis,
options_undercutmould_10_mode: this.recipe.options_undercutmould_10_mode,
options_undercutmould_10_position: this.recipe.options_undercutmould_10_position,
options_undercutmould_10_delay_acti: this.recipe.options_undercutmould_10_delay_acti,
options_undercutmould_10_delay_dis: this.recipe.options_undercutmould_10_delay_dis,
options_undercutupperplate_1_mode: this.recipe.options_undercutupperplate_1_mode,
options_undercutupperplate_1_position: this.recipe.options_undercutupperplate_1_position,
options_undercutupperplate_1_delay_acti: this.recipe.options_undercutupperplate_1_delay_acti,
options_undercutupperplate_1_delay_dis: this.recipe.options_undercutupperplate_1_delay_dis,
options_undercutupperplate_2_mode: this.recipe.options_undercutupperplate_2_mode,
options_undercutupperplate_2_position: this.recipe.options_undercutupperplate_2_position,
options_undercutupperplate_2_delay_acti: this.recipe.options_undercutupperplate_2_delay_acti,
options_undercutupperplate_2_delay_dis: this.recipe.options_undercutupperplate_2_delay_dis,
options_undercutupperplate_3_mode: this.recipe.options_undercutupperplate_3_mode,
options_undercutupperplate_3_position: this.recipe.options_undercutupperplate_3_position,
options_undercutupperplate_3_delay_acti: this.recipe.options_undercutupperplate_3_delay_acti,
options_undercutupperplate_3_delay_dis: this.recipe.options_undercutupperplate_3_delay_dis,
options_undercutupperplate_4_mode: this.recipe.options_undercutupperplate_4_mode,
options_undercutupperplate_4_position: this.recipe.options_undercutupperplate_4_position,
options_undercutupperplate_4_delay_acti: this.recipe.options_undercutupperplate_4_delay_acti,
options_undercutupperplate_4_delay_dis: this.recipe.options_undercutupperplate_4_delay_dis,
options_undercutupperplate_5_mode: this.recipe.options_undercutupperplate_5_mode,
options_undercutupperplate_5_position: this.recipe.options_undercutupperplate_5_position,
options_undercutupperplate_5_delay_acti: this.recipe.options_undercutupperplate_5_delay_acti,
options_undercutupperplate_5_delay_dis: this.recipe.options_undercutupperplate_5_delay_dis,
options_undercutupperplate_6_mode: this.recipe.options_undercutupperplate_6_mode,
options_undercutupperplate_6_position: this.recipe.options_undercutupperplate_6_position,
options_undercutupperplate_6_delay_acti: this.recipe.options_undercutupperplate_6_delay_acti,
options_undercutupperplate_6_delay_dis: this.recipe.options_undercutupperplate_6_delay_dis,
options_undercutupperplate_7_mode: this.recipe.options_undercutupperplate_7_mode,
options_undercutupperplate_7_position: this.recipe.options_undercutupperplate_7_position,
options_undercutupperplate_7_delay_acti: this.recipe.options_undercutupperplate_7_delay_acti,
options_undercutupperplate_7_delay_dis: this.recipe.options_undercutupperplate_7_delay_dis,
options_undercutupperplate_8_mode: this.recipe.options_undercutupperplate_8_mode,
options_undercutupperplate_8_position: this.recipe.options_undercutupperplate_8_position,
options_undercutupperplate_8_delay_acti: this.recipe.options_undercutupperplate_8_delay_acti,
options_undercutupperplate_8_delay_dis: this.recipe.options_undercutupperplate_8_delay_dis,
options_undercutupperplate_9_mode: this.recipe.options_undercutupperplate_9_mode,
options_undercutupperplate_9_position: this.recipe.options_undercutupperplate_9_position,
options_undercutupperplate_9_delay_acti: this.recipe.options_undercutupperplate_9_delay_acti,
options_undercutupperplate_9_delay_dis: this.recipe.options_undercutupperplate_9_delay_dis,
options_undercutupperplate_10_mode: this.recipe.options_undercutupperplate_10_mode,
options_undercutupperplate_10_position: this.recipe.options_undercutupperplate_10_position,
options_undercutupperplate_10_delay_acti: this.recipe.options_undercutupperplate_10_delay_acti,
options_undercutupperplate_10_delay_dis: this.recipe.options_undercutupperplate_10_delay_dis,
options_thermoregulator_1_enabled: this.recipe.options_thermoregulator_1_enabled,
options_thermoregulator_1_setpoint: this.recipe.options_thermoregulator_1_setpoint,
options_thermoregulator_2_enabled: this.recipe.options_thermoregulator_2_enabled,
options_thermoregulator_2_setpoint: this.recipe.options_thermoregulator_2_setpoint,
options_thermoregulator_3_enabled: this.recipe.options_thermoregulator_3_enabled,
options_thermoregulator_3_setpoint: this.recipe.options_thermoregulator_3_setpoint,
options_thermoregulator_4_enabled: this.recipe.options_thermoregulator_4_enabled,
options_thermoregulator_4_setpoint: this.recipe.options_thermoregulator_4_setpoint,
options_thermoregulator_5_enabled: this.recipe.options_thermoregulator_5_enabled,
options_thermoregulator_5_setpoint: this.recipe.options_thermoregulator_5_setpoint,
options_thermoregulator_6_enabled: this.recipe.options_thermoregulator_6_enabled,
options_thermoregulator_6_setpoint: this.recipe.options_thermoregulator_6_setpoint,
options_thermoregulator_7_enabled: this.recipe.options_thermoregulator_7_enabled,
options_thermoregulator_7_setpoint: this.recipe.options_thermoregulator_7_setpoint,
options_thermoregulator_8_enabled: this.recipe.options_thermoregulator_8_enabled,
options_thermoregulator_8_setpoint: this.recipe.options_thermoregulator_8_setpoint,
options_thermoregulator_9_enabled: this.recipe.options_thermoregulator_9_enabled,
options_thermoregulator_9_setpoint: this.recipe.options_thermoregulator_9_setpoint,
options_thermoregulator_10_enabled: this.recipe.options_thermoregulator_10_enabled,
options_thermoregulator_10_setpoint: this.recipe.options_thermoregulator_10_setpoint,
}
}
hasErrors() {
let payload = this.recipe;
let errors = false;
for (const key in this.recipe) {
const el = payload[key] as Recipe.IValue;
if (el.status.hasError) errors = true;
}
return errors;
}
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;
}
return result;
}
async conferma() {
// recipeActions.setCurrent(store, this.recipe);
await recipeService.Confirm('Options');
ModalHelper.HideModal();
this.deferred.resolve(1);
// ModalHelper.HideModal();
// this.deferred.resolve(1);
};
goTo(step) {
@@ -10,10 +10,7 @@
<aside class="scrollable auto">
<button :class="{'active':showOpzioni == 0}" @click="showOpzioni=0">Termoregolatori</button>
<button :class="{'active':showOpzioni == 1}" @click="showOpzioni=1">Sottosquadra stampo</button>
<button
:class="{'active':showOpzioni == 2}"
@click="showOpzioni=2"
>Sottosquadra controstampo</button>
<button :class="{'active':showOpzioni == 2}" @click="showOpzioni=2">Sottosquadra controstampo</button>
</aside>
<hr />
<termoregolatori v-if="showOpzioni==0" :recipe="recipe"></termoregolatori>
@@ -21,8 +18,16 @@
<sottosquadracontrostampo v-if="showOpzioni==2" :recipe="recipe"></sottosquadracontrostampo>
</section>
<footer>
<button class="btn" @click="annulla()">Annulla</button>
<button class="btn btn-success" @click="conferma()">Conferma</button>
<button
class="btn"
@click="annulla()"
:disabled="!hasChanges()"
>{{'cancel' | localize('Annulla')}}</button>
<button
class="btn btn-success"
@click="conferma()"
:disabled="hasErrors() || !hasChanges()"
>{{'confirm' | localize('Conferma')}}</button>
</footer>
</modal>
<stepfooter :current="10" @click="goTo"></stepfooter>
@@ -6,7 +6,10 @@
<template v-if="recipe.pyrometer_pyrometer_enabled.status.visible">
<div class="input-area">
<label>{{'pyrometer_pyrometer_enabled'|localize('Abilitazione')}}</label>
<toggle-button v-model="recipe.pyrometer_pyrometer_enabled.setpointHMI"></toggle-button>
<toggle-button
v-model="recipe.pyrometer_pyrometer_enabled.setpointHMI"
:status="recipe.pyrometer_pyrometer_enabled.status"
></toggle-button>
</div>
</template>
<template v-if="recipe.pyrometer_pyrometer_delay.status.visible">

Some files were not shown because too many files have changed in this diff Show More