BNA8/.resources/177574d9443bf2ddec2678c483d7b5081d8760e303c3d727346d62e8cbf869c7

4692 lines
174 KiB
Plaintext

{
"custom": {},
"params": {
"tab": 0,
"tagPath": "null"
},
"propConfig": {
"params.tab": {
"paramDirection": "input",
"persistent": true
}
},
"props": {
"defaultSize": {
"height": 930,
"width": 1920
}
},
"root": {
"children": [
{
"children": [
{
"children": [
{
"meta": {
"name": "HistoryAlarm"
},
"position": {
"height": "100%",
"width": "100%"
},
"propConfig": {
"custom.query": {
"binding": {
"config": {
"expression": "{..../TabContainer.props.currentTabIndex} + {..../Period_not_Global/Period.props.value} + {..../Period_not_Global/StartTime.custom.Selected} + {..../Period_not_Global/EndTime.custom.Selected} + {..../DropdownMinClass.props.value}"
},
"type": "expr"
},
"onChange": {
"enabled": null,
"script": "\t\n\tfrom system import date\n\n\tfrom java.lang import System\n\t\n\tfrom com.inductiveautomation.ignition.common.config import BasicProperty\n\t\n\tfrom com.inductiveautomation.ignition.common.alarming.config import CommonAlarmProperties\n\t\t\t\n\tp_alarmClass \u003d BasicProperty(\"Class\", BasicProperty().getType())\n\tp_location \u003d BasicProperty(\"Area\", BasicProperty().getType())\n\tp_description \u003d BasicProperty(\"Description\", BasicProperty().getType())\n\tp_tag \u003d BasicProperty(\"Tag\", BasicProperty().getType())\n\t\n\tdef testRow(number,startTime,endTime,duration,alarmClass,location,description,tag,color):\n\t\t return {\n\t\t\"value\":{\n\t\t\t \"NumberID\": number,\n\t\t\t \"StartTimestamp\": startTime, \n\t\t\t \"EndTimestamp\": endTime,\n\t\t\t \"Duration\": duration,\n\t\t\t \"Class\": alarmClass,\n\t\t\t \"Area\": location,\n\t\t\t \"Description\": description, \n\t\t\t \"Tag\": tag\n\t\t\t }, \n\t\t \"style\": {\n\t\t\t \"backgroundColor\": color,\n\t\t\t \"classes\": \"some-class\"\n\t\t }\n\t\t } \n\tpar_class \u003d []\n\tif self.parent.parent.parent.getChild(\"DropdownMinClass\").props.value \u003d\u003d \"Error\": par_class \u003d [(\"Class\",\"\u003d\",\"Error\")]\n\telif self.parent.parent.parent.getChild(\"DropdownMinClass\").props.value \u003d\u003d \"Warning\": par_class \u003d [(\"Class\",\"\u003d\",\"Error\"),(\"Class\",\"\u003d\",\"Warning\")]\n\telse: par_class \u003d [(\"Class\",\"\u003d\",\"Error\"),(\"Class\",\"\u003d\",\"Warning\"),(\"Class\",\"\u003d\",\"Message\")]\t\t\n\t\t\t\n\tdata \u003d []\n\t\n\tevents \u003d system.alarm.queryJournal(journalName\u003d\"Journal\", startDate\u003dself.parent.parent.parent.getChild(\"Period_not_Global\").custom.StartDate, \n\tendDate\u003dself.parent.parent.parent.getChild(\"Period_not_Global\").custom.EndDate,\n\tany_properties\u003dpar_class,state\u003d[\u0027ActiveUnacked\u0027], includeData\u003dTrue)\n\t\n\tcolor \u003d \"#FFFFFF\"\n\t\n\t# Get the active duration for each alarm id\n\tfor alarm in events:\n\t\tactTime \u003d None\n\t\tclrTime \u003d None\n\t\t# Get active time\n\t\td \u003d alarm.activeData\n\t\tactTime \u003d d.timestamp\n\t\talarmClass \u003d d.get(p_alarmClass)\n\t\tlocation \u003d d.get(p_location)\n\t\tdescription \u003d d.get(p_description)\n\t\ttag \u003d d.get(p_tag)\n\t\tnumberID \u003d system.db.runQuery(\"SELECT id FROM alarm_events where eventid \u003d \" + \"\u0027\" + str(alarm.id) + \"\u0027\",\"MariaDB80\")[0][0]\n\t\t#Get Clear time\n\t\tfindOutsidePeriod \u003d system.db.runQuery(\"SELECT eventtime FROM alarm_events where eventid \u003d \" + \"\u0027\" + str(alarm.id) + \"\u0027 AND eventtype \u003d 1\",\"MariaDB80\")\n\t\tif len(findOutsidePeriod) \u003e 0:\n\t\t\tclrTime \u003d date.toMillis(findOutsidePeriod[0][0])\n\t\t# Populate Table\n\t\tif actTime !\u003d None and clrTime !\u003d None:\n\t\t\tduration \u003d (clrTime - actTime) / 1000\n\t\t\tclrTime \u003d date.format(date.fromMillis(clrTime),\"yyyy-MM-dd HH:mm:ss\")\n\t\t\tcolor \u003d \"#FFFFFF\"\n\t\telif actTime !\u003d None and alarmClass !\u003d None:\n\t\t\tduration \u003d (date.toMillis(date.now()) - actTime) / 1000\n\t\t\tclrTime \u003d \"\"\n\t\t\tcolor \u003d \"#FFA500\"\n\t\tif actTime !\u003d None and alarmClass !\u003d None:\t\n\t\t\t#Number (ID)\n\t\t\tdata.append(testRow(numberID + 30000,\n\t\t\t#Start Time\t \n\t\t\tdate.format(date.fromMillis(actTime),\"yyyy-MM-dd HH:mm:ss\"),\n\t\t\t#End Time\n\t\t\tclrTime,\n\t\t\t#Duration\n\t\t\tdate.format(date.addSeconds(date.midnight(date.now()),duration),\"HH:mm:ss\"),\n\t\t\t#Class\n\t\t\talarmClass,\n\t\t\t#Location\n\t\t\tlocation,\n\t\t\t#Description\n\t\t\tdescription,\n\t\t\t#Tag\n\t\t\ttag,\n\t\t\t#Color\n\t\t\tcolor))\n\t\t\n\tself.props.data \u003d data\t\n\tself.custom.query \u003d 0\n"
}
},
"props.data": {
"persistent": true
}
},
"props": {
"columns": [
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "NumberID",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "Number (ID)"
},
"justify": "center",
"number": "value",
"numberFormat": "none",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 30
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "StartTimestamp",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "Start Timestamp"
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "descending",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 40
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "EndTimestamp",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "End Timestamp"
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 40
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Duration",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "Duration"
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 25
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Class",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "Class"
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 20
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Area",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "Location"
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 30
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Description",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "Description"
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 150
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Tag",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "Tag"
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 120
}
],
"data": [
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 107 has detected Jam condition",
"Duration": "00:04:43",
"EndTimestamp": "2023-09-05 13:29:24",
"NumberID": 228812,
"StartTimestamp": "2023-09-05 13:24:41",
"Tag": "[Interroll]Chute[107].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 108 has detected Jam condition",
"Duration": "00:00:01",
"EndTimestamp": "2023-09-05 13:24:57",
"NumberID": 228814,
"StartTimestamp": "2023-09-05 13:24:56",
"Tag": "[Interroll]Chute[108].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 108 has detected Jam condition",
"Duration": "00:04:30",
"EndTimestamp": "2023-09-05 13:29:28",
"NumberID": 228817,
"StartTimestamp": "2023-09-05 13:24:58",
"Tag": "[Interroll]Chute[108].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 106 has detected Jam condition",
"Duration": "00:04:33",
"EndTimestamp": "2023-09-05 13:30:00",
"NumberID": 228819,
"StartTimestamp": "2023-09-05 13:25:27",
"Tag": "[Interroll]Chute[106].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "M1",
"Class": "Error",
"Description": "SORTER JAMMED AT CHUTE LOCATION",
"Duration": "00:04:26",
"EndTimestamp": "2023-09-05 13:32:08",
"NumberID": 228821,
"StartTimestamp": "2023-09-05 13:27:42",
"Tag": "[Interroll]Sorter.FLT_JamChutes"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 108 has detected Jam condition",
"Duration": "00:00:01",
"EndTimestamp": "2023-09-05 13:29:30",
"NumberID": 228827,
"StartTimestamp": "2023-09-05 13:29:29",
"Tag": "[Interroll]Chute[108].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Induct",
"Class": "Error",
"Description": "M10 Motor disconnect open",
"Duration": "00:01:06",
"EndTimestamp": "2023-09-05 13:32:43",
"NumberID": 228832,
"StartTimestamp": "2023-09-05 13:31:37",
"Tag": "[Interroll]Induct[0].Conveyor[0].FLT_Disconnect"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Induct",
"Class": "Error",
"Description": "M10 Motor disconnect open",
"Duration": "00:04:37",
"EndTimestamp": "2023-09-05 13:37:21",
"NumberID": 228836,
"StartTimestamp": "2023-09-05 13:32:44",
"Tag": "[Interroll]Induct[0].Conveyor[0].FLT_Disconnect"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 105 has detected Jam condition",
"Duration": "00:04:26",
"EndTimestamp": "2023-09-05 13:37:11",
"NumberID": 228838,
"StartTimestamp": "2023-09-05 13:32:45",
"Tag": "[Interroll]Chute[105].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 110 has detected Jam condition",
"Duration": "00:04:27",
"EndTimestamp": "2023-09-05 13:37:13",
"NumberID": 228840,
"StartTimestamp": "2023-09-05 13:32:46",
"Tag": "[Interroll]Chute[110].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 107 has detected Jam condition",
"Duration": "00:05:34",
"EndTimestamp": "2023-09-05 13:39:45",
"NumberID": 228842,
"StartTimestamp": "2023-09-05 13:34:11",
"Tag": "[Interroll]Chute[107].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 108 has detected Jam condition",
"Duration": "00:00:02",
"EndTimestamp": "2023-09-05 13:34:41",
"NumberID": 228844,
"StartTimestamp": "2023-09-05 13:34:39",
"Tag": "[Interroll]Chute[108].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 108 has detected Jam condition",
"Duration": "00:05:31",
"EndTimestamp": "2023-09-05 13:40:14",
"NumberID": 228847,
"StartTimestamp": "2023-09-05 13:34:43",
"Tag": "[Interroll]Chute[108].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 106 has detected Jam condition",
"Duration": "00:05:29",
"EndTimestamp": "2023-09-05 13:40:29",
"NumberID": 228849,
"StartTimestamp": "2023-09-05 13:35:00",
"Tag": "[Interroll]Chute[106].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Induct",
"Class": "Error",
"Description": "M10 Motor disconnect open",
"Duration": "00:06:58",
"EndTimestamp": "2023-09-05 13:44:20",
"NumberID": 228854,
"StartTimestamp": "2023-09-05 13:37:22",
"Tag": "[Interroll]Induct[0].Conveyor[0].FLT_Disconnect"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "M1",
"Class": "Error",
"Description": "SORTER JAMMED AT CHUTE LOCATION",
"Duration": "00:05:45",
"EndTimestamp": "2023-09-05 13:43:22",
"NumberID": 228856,
"StartTimestamp": "2023-09-05 13:37:37",
"Tag": "[Interroll]Sorter.FLT_JamChutes"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 105 has detected Jam condition",
"Duration": "00:06:13",
"EndTimestamp": "2023-09-05 13:48:50",
"NumberID": 228861,
"StartTimestamp": "2023-09-05 13:42:37",
"Tag": "[Interroll]Chute[105].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 110 has detected Jam condition",
"Duration": "00:06:12",
"EndTimestamp": "2023-09-05 13:48:51",
"NumberID": 228862,
"StartTimestamp": "2023-09-05 13:42:39",
"Tag": "[Interroll]Chute[110].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Induct",
"Class": "Error",
"Description": "M10 Motor disconnect open",
"Duration": "00:04:12",
"EndTimestamp": "2023-09-05 13:48:33",
"NumberID": 228867,
"StartTimestamp": "2023-09-05 13:44:21",
"Tag": "[Interroll]Induct[0].Conveyor[0].FLT_Disconnect"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 107 has detected Jam condition",
"Duration": "00:03:29",
"EndTimestamp": "2023-09-05 13:49:00",
"NumberID": 228868,
"StartTimestamp": "2023-09-05 13:45:31",
"Tag": "[Interroll]Chute[107].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 108 has detected Jam condition",
"Duration": "00:03:33",
"EndTimestamp": "2023-09-05 13:49:06",
"NumberID": 228871,
"StartTimestamp": "2023-09-05 13:45:33",
"Tag": "[Interroll]Chute[108].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 106 has detected Jam condition",
"Duration": "00:03:43",
"EndTimestamp": "2023-09-05 13:49:38",
"NumberID": 228872,
"StartTimestamp": "2023-09-05 13:45:55",
"Tag": "[Interroll]Chute[106].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "M1",
"Class": "Error",
"Description": "SORTER JAMMED AT CHUTE LOCATION",
"Duration": "00:04:06",
"EndTimestamp": "2023-09-05 13:52:19",
"NumberID": 228874,
"StartTimestamp": "2023-09-05 13:48:13",
"Tag": "[Interroll]Sorter.FLT_JamChutes"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Induct",
"Class": "Error",
"Description": "M10 Motor disconnect open",
"Duration": "00:02:51",
"EndTimestamp": "2023-09-05 13:51:25",
"NumberID": 228878,
"StartTimestamp": "2023-09-05 13:48:34",
"Tag": "[Interroll]Induct[0].Conveyor[0].FLT_Disconnect"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "SEPC1-RE2-5",
"Class": "Error",
"Description": "SEPC1-RE2-5 Control station E-Stop Tripped",
"Duration": "00:00:02",
"EndTimestamp": "2023-09-05 13:49:02",
"NumberID": 228883,
"StartTimestamp": "2023-09-05 13:49:00",
"Tag": "[AB1]SEPC1_RE2_5.HMI.Alarm.Estopped"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "SEPC1-RE2-5",
"Class": "Error",
"Description": "SEPC1-RE2-5 Control station E-Stop Tripped",
"Duration": "00:00:01",
"EndTimestamp": "2023-09-05 13:49:04",
"NumberID": 228887,
"StartTimestamp": "2023-09-05 13:49:03",
"Tag": "[AB1]SEPC1_RE2_5.HMI.Alarm.Estopped"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "SEPC1-RE2-5",
"Class": "Error",
"Description": "SEPC1-RE2-5 Control station E-Stop Tripped",
"Duration": "00:00:02",
"EndTimestamp": "2023-09-05 13:49:07",
"NumberID": 228889,
"StartTimestamp": "2023-09-05 13:49:05",
"Tag": "[AB1]SEPC1_RE2_5.HMI.Alarm.Estopped"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "SEPC1-RE2-5",
"Class": "Error",
"Description": "SEPC1-RE2-5 Control station E-Stop Tripped",
"Duration": "00:01:24",
"EndTimestamp": "2023-09-05 13:50:35",
"NumberID": 228893,
"StartTimestamp": "2023-09-05 13:49:11",
"Tag": "[AB1]SEPC1_RE2_5.HMI.Alarm.Estopped"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "SEPC1-RE2-5",
"Class": "Error",
"Description": "SEPC1-RE2-5 Control station E-Stop Tripped",
"Duration": "00:00:01",
"EndTimestamp": "2023-09-05 13:50:37",
"NumberID": 228898,
"StartTimestamp": "2023-09-05 13:50:36",
"Tag": "[AB1]SEPC1_RE2_5.HMI.Alarm.Estopped"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "SEPC1-RE2-5",
"Class": "Error",
"Description": "SEPC1-RE2-5 Control station E-Stop Tripped",
"Duration": "00:00:33",
"EndTimestamp": "2023-09-05 13:51:27",
"NumberID": 228900,
"StartTimestamp": "2023-09-05 13:50:54",
"Tag": "[AB1]SEPC1_RE2_5.HMI.Alarm.Estopped"
}
},
{
"style": {
"backgroundColor": "#FFA500",
"classes": "some-class"
},
"value": {
"Area": "Induct",
"Class": "Error",
"Description": "M10 Motor disconnect open",
"Duration": "00:02:47",
"EndTimestamp": "",
"NumberID": 228904,
"StartTimestamp": "2023-09-05 13:51:26",
"Tag": "[Interroll]Induct[0].Conveyor[0].FLT_Disconnect"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "SEPC1-RE2-5",
"Class": "Error",
"Description": "SEPC1-RE2-5 Control station E-Stop Tripped",
"Duration": "00:02:29",
"EndTimestamp": "2023-09-05 13:54:02",
"NumberID": 228906,
"StartTimestamp": "2023-09-05 13:51:33",
"Tag": "[AB1]SEPC1_RE2_5.HMI.Alarm.Estopped"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 105 has detected Jam condition",
"Duration": "00:00:04",
"EndTimestamp": "2023-09-05 13:53:32",
"NumberID": 228909,
"StartTimestamp": "2023-09-05 13:53:28",
"Tag": "[Interroll]Chute[105].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 110 has detected Jam condition",
"Duration": "00:00:04",
"EndTimestamp": "2023-09-05 13:53:32",
"NumberID": 228911,
"StartTimestamp": "2023-09-05 13:53:28",
"Tag": "[Interroll]Chute[110].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 106 has detected Jam condition",
"Duration": "00:00:31",
"EndTimestamp": "2023-09-05 13:54:08",
"NumberID": 228916,
"StartTimestamp": "2023-09-05 13:53:37",
"Tag": "[Interroll]Chute[106].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 107 has detected Jam condition",
"Duration": "00:00:31",
"EndTimestamp": "2023-09-05 13:54:08",
"NumberID": 228918,
"StartTimestamp": "2023-09-05 13:53:37",
"Tag": "[Interroll]Chute[107].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 108 has detected Jam condition",
"Duration": "00:00:31",
"EndTimestamp": "2023-09-05 13:54:08",
"NumberID": 228920,
"StartTimestamp": "2023-09-05 13:53:37",
"Tag": "[Interroll]Chute[108].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFA500",
"classes": "some-class"
},
"value": {
"Area": "M1",
"Class": "Error",
"Description": "SORTER JAMMED AT CHUTE LOCATION",
"Duration": "00:00:28",
"EndTimestamp": "",
"NumberID": 228921,
"StartTimestamp": "2023-09-05 13:53:45",
"Tag": "[Interroll]Sorter.FLT_JamChutes"
}
},
{
"style": {
"backgroundColor": "#FFA500",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 105 has detected Jam condition",
"Duration": "00:00:10",
"EndTimestamp": "",
"NumberID": 228924,
"StartTimestamp": "2023-09-05 13:54:03",
"Tag": "[Interroll]Chute[105].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFA500",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Description": "Chute 110 has detected Jam condition",
"Duration": "00:00:10",
"EndTimestamp": "",
"NumberID": 228926,
"StartTimestamp": "2023-09-05 13:54:03",
"Tag": "[Interroll]Chute[110].SignallingJam"
}
}
],
"filter": {
"enabled": true,
"results": {
"enabled": true
}
},
"footerGroups": [
[]
],
"pager": {
"bottom": false,
"options": [
5,
10,
25,
50,
999
]
},
"selection": {
"enableColumnSelection": true
},
"sortOrder": [
"StartTimestamp"
],
"style": {
"overflow": "visible"
}
},
"type": "ia.display.table"
},
{
"events": {
"component": {
"onActionPerformed": {
"config": {
"script": "\t\n\tself.getSibling(\"HistoryAlarm\").custom.query \u003d 1"
},
"scope": "G",
"type": "script"
}
}
},
"meta": {
"name": "Refresh"
},
"position": {
"height": 34,
"width": 120,
"x": 1789,
"y": 6
},
"props": {
"text": "Refresh"
},
"type": "ia.input.button"
}
],
"meta": {
"name": "Alarm History"
},
"position": {
"tabIndex": 1
},
"type": "ia.container.coord"
},
{
"children": [
{
"meta": {
"name": "AlarmHitList"
},
"position": {
"height": "100%",
"width": "100%"
},
"propConfig": {
"custom.query": {
"binding": {
"config": {
"expression": "{..../TabContainer.props.currentTabIndex} + {..../Period_not_Global/Period.props.value} + {..../Period_not_Global/StartTime.custom.Selected} + {..../Period_not_Global/EndTime.custom.Selected} + {..../DropdownMinClass.props.value}"
},
"type": "expr"
},
"onChange": {
"enabled": null,
"script": "\t\n\tfrom system import date\n\t\n\tfrom java.lang import System\n\t\n\tfrom com.inductiveautomation.ignition.common.config import BasicProperty\n\t\n\tfrom com.inductiveautomation.ignition.common.alarming.config import CommonAlarmProperties\n\t\n\tp_alarmClass \u003d BasicProperty(\"Class\", BasicProperty().getType())\n\tp_location \u003d BasicProperty(\"Area\", BasicProperty().getType())\n\tp_description \u003d BasicProperty(\"Description\", BasicProperty().getType())\n\tp_tag \u003d BasicProperty(\"Tag\", BasicProperty().getType())\n\t\n\tdef testRow(startTime,endTime,count,duration,alarmClass,location,description,tag,color):\n\t\t return {\n\t\t\"value\":{\n\t\t\t \"StartTimestamp\": startTime, \n\t\t\t \"EndTimestamp\": endTime,\n\t\t\t \"Count\": count,\n\t\t\t \"Duration\": duration,\n\t\t\t \"Class\": alarmClass,\n\t\t\t \"Area\": location,\n\t\t\t \"Description\": description, \n\t\t\t \"Tag\": tag\n\t\t\t }, \n\t\t \"style\": {\n\t\t\t \"backgroundColor\": color,\n\t\t\t \"classes\": \"some-class\"\n\t\t }\n\t\t } \n\tpar_class \u003d []\n\tif self.parent.parent.parent.getChild(\"DropdownMinClass\").props.value \u003d\u003d \"Error\": par_class \u003d [(\"Class\",\"\u003d\",\"Error\")]\n\telif self.parent.parent.parent.getChild(\"DropdownMinClass\").props.value \u003d\u003d \"Warning\": par_class \u003d [(\"Class\",\"\u003d\",\"Error\"),(\"Class\",\"\u003d\",\"Warning\")]\n\telse: par_class \u003d [(\"Class\",\"\u003d\",\"Error\"),(\"Class\",\"\u003d\",\"Warning\"),(\"Class\",\"\u003d\",\"Message\")]\t \n\t\t \n\t\t \n\tdata \u003d []\n\t\n\tevents \u003d system.alarm.queryJournal(journalName\u003d\"Journal\", startDate\u003dself.parent.parent.parent.getChild(\"Period_not_Global\").custom.StartDate, \n\tendDate\u003dself.parent.parent.parent.getChild(\"Period_not_Global\").custom.EndDate,state\u003d[\u0027ActiveUnacked\u0027],\n\tany_properties\u003dpar_class, includeData\u003dTrue)\n\t\t\n\tcolor \u003d \"#FFFFFF\"\n\t\n\t# Get a dict where the key is alarm id and the value is a list of corresponding events.\n\talarms \u003d {}\n\tfor e in events:\n\t\tif e.source in alarms: alarms[e.source].append(e)\n\t\telse: alarms[e.source] \u003d [e]\n\t\t\n\t\n\t# Get the active duration for each alarm id\n\tfor id in alarms:\n\t\tactTime \u003d None\n\t\tclrTime \u003d None\n\t\talarmEvents \u003d alarms[id]\n\t\tcount \u003d 0\n\t\ttimes \u003d []\n\t\tstartCount \u003d 0\n\t\tfor e in alarmEvents:\n\t\t\t# Get active time\n\t\t\td \u003d e.activeData\n\t\t\tif d !\u003d None:\n\t\t\t\tactTime \u003d d.timestamp\n\t\t\t\talarmClass \u003d d.get(p_alarmClass)\n\t\t\t\tlocation \u003d d.get(p_location)\n\t\t\t\tdescription \u003d d.get(p_description)\n\t\t\t\ttag \u003d d.get(p_tag)\n\t\t\t\tcount \u003d count + 1\n\t\t\t\tstartCount \u003d 1\n\t\t\t\ttimes.append(d.timestamp)\n\t\t\t# Get cleared time\n\t\t\tfindOutsidePeriod \u003d system.db.runQuery(\"SELECT eventtime FROM alarm_events where eventid \u003d \" + \"\u0027\" + str(e.id) + \"\u0027 AND eventtype \u003d 1\",\"MariaDB80\")\n\t\t\tif len(findOutsidePeriod) \u003e 0:\n\t\t\t\tif startCount \u003d\u003d 1:\n\t\t\t\t\ttimes.append(date.toMillis(findOutsidePeriod[0][0]))\n\t\t\t\tclrTime \u003d date.toMillis(findOutsidePeriod[0][0])\n\t\t# Populate Table\n\t\tu \u003d 0\t\t\t\n\t\tduration \u003d 0\n\t\tendTime \u003d \"\"\n\t\tif len(times) \u003e 0:\n\t\t\tif len(times) % 2 \u003d\u003d 0:\n\t\t\t\tcolor \u003d \"#FFFFFF\"\n\t\t\t\twhile u \u003c len(times): \n\t\t\t\t\tduration \u003d duration + ((times[u+1] - times[u]) / 1000)\n\t\t\t\t\tu \u003d u + 2\n\t\t\t\tendTime \u003d date.format(date.fromMillis(times[-1]),\"yyyy-MM-dd HH:mm:ss\")\t\n\t\t\telse:\n\t\t\t\tcolor \u003d \"#FFA500\"\n\t\t\t\twhile u \u003c len(times):\n\t\t\t\t\tif u !\u003d len(times) - 1:\n\t\t\t\t\t\tduration \u003d duration + ((times[u+1] - times[u]) / 1000)\n\t\t\t\t\telse:\n\t\t\t\t\t\tduration \u003d duration + ((date.toMillis(date.now()) - times[u]) / 1000)\n\t\t\t\t\tu \u003d u + 2\t\n\t\t\tif actTime !\u003d None and alarmClass !\u003d None:\t\n\t\t\t\tdata.append(testRow(\n\t\t\t\t#Start Time\t \n\t\t\t\tdate.format(date.fromMillis(times[0]),\"yyyy-MM-dd HH:mm:ss\"),\n\t\t\t\t#End Time\n\t\t\t\tendTime,\n\t\t\t\t#Count\n\t\t\t\tcount,\n\t\t\t\t#Duration\n\t\t\t\tdate.format(date.addSeconds(date.midnight(date.now()),duration),\"HH:mm:ss\"),\n\t\t\t\t#Class\n\t\t\t\talarmClass,\n\t\t\t\t#Location\n\t\t\t\tlocation,\n\t\t\t\t#Description\n\t\t\t\tdescription,\n\t\t\t\t#Tag\n\t\t\t\ttag,\n\t\t\t\t#Color\n\t\t\t\tcolor))\n\t\t\t\n\tself.getSibling(\"AlarmHitList\").props.data \u003d data\t\n\tself.custom.query \u003d 0"
}
},
"props.data": {
"persistent": true
}
},
"props": {
"columns": [
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "StartTimestamp",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "First Timestamp"
},
"justify": "center",
"number": "value",
"numberFormat": "none",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 70
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "EndTimestamp",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "Last Timestamp"
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 70
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Count",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": ""
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "descending",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 40
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Duration",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": ""
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "descending",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 60
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Class",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": ""
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 40
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Area",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "Location"
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 50
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Description",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "Description"
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 150
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Tag",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "Tag"
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 150
}
],
"data": [
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Count": 7,
"Description": "Chute 108 has detected Jam condition",
"Duration": "00:14:09",
"EndTimestamp": "2023-09-05 13:54:08",
"StartTimestamp": "2023-09-05 13:24:56",
"Tag": "[Interroll]Chute[108].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Count": 4,
"Description": "Chute 107 has detected Jam condition",
"Duration": "00:14:17",
"EndTimestamp": "2023-09-05 13:54:08",
"StartTimestamp": "2023-09-05 13:24:41",
"Tag": "[Interroll]Chute[107].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFA500",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Count": 4,
"Description": "Chute 110 has detected Jam condition",
"Duration": "00:10:53",
"EndTimestamp": "",
"StartTimestamp": "2023-09-05 13:32:46",
"Tag": "[Interroll]Chute[110].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFA500",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Count": 4,
"Description": "Chute 105 has detected Jam condition",
"Duration": "00:10:53",
"EndTimestamp": "",
"StartTimestamp": "2023-09-05 13:32:45",
"Tag": "[Interroll]Chute[105].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFA500",
"classes": "some-class"
},
"value": {
"Area": "Induct",
"Class": "Error",
"Count": 6,
"Description": "M10 Motor disconnect open",
"Duration": "00:22:31",
"EndTimestamp": "",
"StartTimestamp": "2023-09-05 13:31:37",
"Tag": "[Interroll]Induct[0].Conveyor[0].FLT_Disconnect"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "Sorter",
"Class": "Error",
"Count": 4,
"Description": "Chute 106 has detected Jam condition",
"Duration": "00:14:16",
"EndTimestamp": "2023-09-05 13:54:08",
"StartTimestamp": "2023-09-05 13:25:27",
"Tag": "[Interroll]Chute[106].SignallingJam"
}
},
{
"style": {
"backgroundColor": "#FFA500",
"classes": "some-class"
},
"value": {
"Area": "M1",
"Class": "Error",
"Count": 4,
"Description": "SORTER JAMMED AT CHUTE LOCATION",
"Duration": "00:14:45",
"EndTimestamp": "",
"StartTimestamp": "2023-09-05 13:27:42",
"Tag": "[Interroll]Sorter.FLT_JamChutes"
}
},
{
"style": {
"backgroundColor": "#FFFFFF",
"classes": "some-class"
},
"value": {
"Area": "SEPC1-RE2-5",
"Class": "Error",
"Count": 7,
"Description": "SEPC1-RE2-5 Control station E-Stop Tripped",
"Duration": "00:04:32",
"EndTimestamp": "2023-09-05 13:54:02",
"StartTimestamp": "2023-09-05 13:49:00",
"Tag": "[AB1]SEPC1_RE2_5.HMI.Alarm.Estopped"
}
}
],
"filter": {
"enabled": true,
"results": {
"enabled": true
},
"style": {
"overflow": "visible"
}
},
"footerGroups": [
[]
],
"pager": {
"bottom": false,
"options": [
5,
10,
25,
50,
999
]
},
"selection": {
"enableColumnSelection": true
},
"sortOrder": [
"Count",
"Duration"
],
"virtualized": false
},
"type": "ia.display.table"
},
{
"events": {
"component": {
"onActionPerformed": {
"config": {
"script": "\t\n\tself.getSibling(\"AlarmHitList\").custom.query \u003d 1\n"
},
"scope": "G",
"type": "script"
}
}
},
"meta": {
"name": "Refresh"
},
"position": {
"height": 34,
"width": 120,
"x": 1789,
"y": 6
},
"props": {
"text": "Refresh"
},
"type": "ia.input.button"
}
],
"meta": {
"name": "AlarmHitList"
},
"position": {
"tabIndex": 2
},
"props": {
"style": {
"overflow": "visible"
}
},
"type": "ia.container.coord"
},
{
"children": [
{
"meta": {
"name": "AlarmSummary"
},
"position": {
"height": "100%",
"width": "100%"
},
"propConfig": {
"props.query": {
"binding": {
"config": {
"expression": "now(1000)"
},
"type": "expr"
},
"onChange": {
"enabled": null,
"script": "\tfrom system import date\n\t\n\tfrom datetime import datetime\n\t\n\tfrom com.inductiveautomation.ignition.common.config import BasicProperty\n\t\n\tfrom com.inductiveautomation.ignition.common.alarming.config import CommonAlarmProperties\n\t\n\tp_alarmClass \u003d BasicProperty(\"Class\", BasicProperty().getType())\n\tp_location \u003d BasicProperty(\"Area\", BasicProperty().getType())\n\tp_description \u003d BasicProperty(\"Description\", BasicProperty().getType())\n\tp_tag \u003d BasicProperty(\"Tag\", BasicProperty().getType())\n\t\n\tdef testRow(number,eventTimeStamp,duration,alarmClass,location,description,tag,color):\n\t\t\t return {\n\t\"value\":{\n\t\t \"NumberID\": number,\n\t\t \"EventTimestamp\": eventTimeStamp,\n\t\t \"Duration\": duration,\n\t\t \"Class\": alarmClass,\n\t\t \"Area\": location,\n\t\t \"Description\": description, \n\t\t \"Tag\": tag\n\t\t }, \n\t\t\t \"style\": {\n\t\t \"backgroundColor\": color,\n\t\t \"classes\": \"some-class\"\n\t\t\t }\n\t\t\t } \t\n\t\n\tpar_class \u003d []\n\tif self.parent.parent.parent.getChild(\"DropdownMinClass\").props.value \u003d\u003d \"Error\": par_class \u003d [(\"Class\",\"\u003d\",\"Error\")]\n\telif self.parent.parent.parent.getChild(\"DropdownMinClass\").props.value \u003d\u003d \"Warning\": par_class \u003d [(\"Class\",\"\u003d\",\"Error\"),(\"Class\",\"\u003d\",\"Warning\")]\n\telse: par_class \u003d [(\"Class\",\"\u003d\",\"Error\"),(\"Class\",\"\u003d\",\"Warning\"),(\"Class\",\"\u003d\",\"Message\")]\t \n\t\t \n\tresults \u003d system.alarm.queryStatus(state\u003d[\u0027ActiveUnacked\u0027, \u0027ActiveAcked\u0027],\n\tany_properties\u003dpar_class)\n\t\n\tdata \u003d []\n\t\n\tcolor \u003d \"#FFFFFF\"\n\t\n\tfor alarm in results:\n\t\td \u003d alarm.activeData\n\t\ttry:\n\t\t\tquery \u003d system.db.runQuery(\"SELECT id,eventtime FROM alarm_events where eventid \u003d \" + \"\u0027\" + str(alarm.id) + \"\u0027\",\"MariaDB80\")\n\t\t\tnumberID \u003d query[0][0]\n\t\t\tactTime \u003d date.parse(str(query[0][1]))\n\t\t\talarmClass \u003d d.get(p_alarmClass)\n\t\t\tlocation \u003d d.get(p_location)\n\t\t\tdescription \u003d d.get(p_description)\n\t\t\ttag \u003d d.get(p_tag)\n\t\t\tduration \u003d date.secondsBetween(date.parse(str(query[0][1])),date.now())\n\t\t\t#Number (ID)\n\t\t\tdata.append(testRow(numberID + 30000,\n\t\t\t#Event Timestamp\t \n\t\t\tsystem.date.format(date.parse(str(query[0][1])), \"yyyy-MM-dd HH:mm:ss\"),\n\t\t\t#Duration\n\t\t\tdate.format(date.addSeconds(date.midnight(date.now()),duration),\"HH:mm:ss\"),\n\t\t\t#Class\n\t\t\talarmClass,\n\t\t\t#Location\n\t\t\tlocation,\n\t\t\t#Description\n\t\t\tdescription,\n\t\t\t#Tag\n\t\t\ttag,\n\t\t\t#Color\n\t\t\tcolor))\n\t\texcept:\n\t\t\tsystem.perspective.print(message\u003dalarm.source)\n\t\n\tself.props.data \u003d data"
}
}
},
"props": {
"columns": [
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "NumberID",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "Number (ID)"
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 40
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "EventTimestamp",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "Event Timestamp"
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "descending",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 60
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Duration",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": ""
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 40
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Class",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": ""
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 30
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Area",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": "Location"
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 40
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Description",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": ""
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 250
},
{
"align": "center",
"boolean": "checkbox",
"dateFormat": "MM/DD/YYYY",
"editable": false,
"field": "Tag",
"footer": {
"align": "center",
"justify": "left",
"style": {
"classes": ""
},
"title": ""
},
"header": {
"align": "center",
"justify": "center",
"style": {
"classes": ""
},
"title": ""
},
"justify": "center",
"number": "value",
"numberFormat": "0,0.##",
"progressBar": {
"bar": {
"color": "",
"style": {
"classes": ""
}
},
"max": 100,
"min": 0,
"track": {
"color": "",
"style": {
"classes": ""
}
},
"value": {
"enabled": true,
"format": "0,0.##",
"justify": "center",
"style": {
"classes": ""
}
}
},
"render": "auto",
"resizable": true,
"sort": "none",
"sortable": true,
"strictWidth": false,
"style": {
"classes": ""
},
"toggleSwitch": {
"color": {
"selected": "",
"unselected": ""
}
},
"viewParams": {},
"viewPath": "",
"visible": true,
"width": 200
}
],
"filter": {
"enabled": true
},
"pager": {
"bottom": false
},
"sortOrder": [
"EventTimestamp"
]
},
"type": "ia.display.table"
}
],
"meta": {
"name": "AlarmSummary"
},
"type": "ia.container.coord"
}
],
"meta": {
"name": "TabContainer"
},
"position": {
"height": "100%",
"width": "100%"
},
"propConfig": {
"props.currentTabIndex": {
"binding": {
"config": {
"path": "view.params.tab"
},
"type": "property"
}
}
},
"props": {
"style": {
"fontFamily": "Arial"
},
"tabSize": {
"width": 130
},
"tabs": [
"Alarm Summary",
"Alarm History",
"Alarm Hit List"
]
},
"type": "ia.container.tab"
},
{
"custom": {
"debug": [
[
"2020-03-24 03:58:00",
83.44392609984358,
93.58514404296875,
71.81086730957031
],
[
"2020-03-24 03:59:00",
83.35893577107669,
106.05998229980469,
72.54214477539062
],
[
"2020-03-24 04:00:00",
83.2739454423098,
102.124267578125,
72.18306732177734
],
[
"2020-03-24 04:01:00",
83.26998772600022,
104.7994155883789,
72.2726821899414
],
[
"2020-03-24 04:02:00",
83.09998708000028,
110.67745971679688,
72.70557403564453
],
[
"2020-03-24 04:03:00",
82.95057846075277,
110.90865325927734,
72.86494445800781
],
[
"2020-03-24 04:04:00",
82.87408810123425,
111.18544006347656,
72.739990234375
],
[
"2020-03-24 04:05:00",
82.79759774171573,
110.57137298583984,
72.47943878173828
],
[
"2020-03-24 04:06:00",
82.72110738219722,
111.59486389160156,
72.50711059570312
],
[
"2020-03-24 04:07:00",
82.6446170226787,
110.79205322265625,
72.84617614746094
],
[
"2020-03-24 04:08:00",
82.56812666316019,
112.36724853515625,
72.59688568115234
],
[
"2020-03-24 04:09:00",
82.49163630364167,
111.96199035644531,
71.75237274169922
],
[
"2020-03-24 04:10:00",
82.41514594412317,
114.09909057617188,
72.87260437011719
],
[
"2020-03-24 04:11:00",
82.33865558460465,
113.22314453125,
72.4264144897461
],
[
"2020-03-24 04:12:00",
82.26216522508614,
112.67841339111328,
72.77767944335938
],
[
"2020-03-24 04:13:00",
82.18567486556762,
109.4883041381836,
73.2457504272461
],
[
"2020-03-24 04:14:00",
82.1091845060491,
109.47913360595703,
72.0219955444336
],
[
"2020-03-24 04:15:00",
82.03269414653059,
109.40910339355469,
72.11457061767578
],
[
"2020-03-24 04:16:00",
81.95620378701207,
108.2085189819336,
73.03665924072266
],
[
"2020-03-24 04:17:00",
81.87971342749356,
109.74492645263672,
72.89605712890625
],
[
"2020-03-24 04:18:00",
81.80322306797505,
110.48381042480469,
72.340087890625
],
[
"2020-03-24 04:19:00",
81.72673270845654,
110.1125259399414,
72.04779815673828
],
[
"2020-03-24 04:20:00",
81.65024234893802,
110.58039855957031,
72.02574157714844
],
[
"2020-03-24 04:21:00",
81.5737519894195,
111.26719665527344,
72.68399810791016
],
[
"2020-03-24 04:22:00",
81.57001033599973,
111.0679931640625,
72.2317123413086
],
[
"2020-03-24 04:23:00",
81.40001291999972,
111.84290313720703,
73.5782470703125
],
[
"2020-03-24 04:24:00",
81.22444354734957,
111.08856201171875,
74.54239654541016
],
[
"2020-03-24 04:25:00",
81.13445335130304,
110.7277603149414,
73.62892150878906
],
[
"2020-03-24 04:26:00",
81.04446315525652,
110.72388458251953,
74.79293823242188
],
[
"2020-03-24 04:27:00",
80.95447295921001,
113.21517944335938,
73.95577239990234
],
[
"2020-03-24 04:28:00",
80.86448276316348,
112.6423568725586,
74.46560668945312
],
[
"2020-03-24 04:29:00",
80.77449256711697,
113.47187805175781,
75.20769500732422
],
[
"2020-03-24 04:30:00",
80.68450237107044,
113.81484985351562,
74.11184692382812
],
[
"2020-03-24 04:31:00",
80.59451217502392,
110.26861572265625,
73.92262268066406
],
[
"2020-03-24 04:32:00",
80.50452197897741,
109.19113159179688,
74.61058807373047
],
[
"2020-03-24 04:33:00",
80.41453178293088,
108.94200134277344,
74.5039291381836
],
[
"2020-03-24 04:34:00",
80.32454158688437,
109.96826934814453,
74.46529388427734
],
[
"2020-03-24 04:35:00",
80.23455139083784,
81.94364929199219,
73.67473602294922
],
[
"2020-03-24 04:36:00",
80.14456119479132,
23.80181121826172,
73.68876117466887
],
[
"2020-03-24 04:37:00",
80.0545709987448,
1.4474921226501465,
73.68912506103516
],
[
"2020-03-24 04:38:00",
79.96458080269828,
4.1637725830078125,
73.72541046142578
],
[
"2020-03-24 04:39:00",
79.87459060665176,
26.945161819458008,
74.61903381347656
],
[
"2020-03-24 04:40:00",
79.87000710599979,
34.11628341674805,
73.51866149902344
],
[
"2020-03-24 04:41:00",
79.70000645999983,
27.773473739624023,
74.04241180419922
],
[
"2020-03-24 04:42:00",
79.60965611151889,
27.49029541015625,
73.1905517578125
],
[
"2020-03-24 04:43:00",
79.56329763722199,
34.070072174072266,
73.98297882080078
],
[
"2020-03-24 04:44:00",
79.5169391629251,
33.60432052612305,
74.68580627441406
],
[
"2020-03-24 04:45:00",
79.4705806886282,
33.17567825317383,
73.96578216552734
],
[
"2020-03-24 04:46:00",
79.42422221433131,
33.235443115234375,
74.14202880859375
],
[
"2020-03-24 04:47:00",
79.37786374003441,
33.624229431152344,
73.29328918457031
],
[
"2020-03-24 04:48:00",
79.33150526573752,
33.59697723388672,
73.17694091796875
],
[
"2020-03-24 04:49:00",
79.28514679144062,
33.403076171875,
73.81486511230469
],
[
"2020-03-24 04:50:00",
79.23878831714373,
33.89695739746094,
74.30374145507812
],
[
"2020-03-24 04:51:00",
79.19242984284683,
32.8265266418457,
74.06024169921875
],
[
"2020-03-24 04:52:00",
79.14607136854994,
48.27207946777344,
73.2079086303711
],
[
"2020-03-24 04:53:00",
79.09971289425305,
74.11988830566406,
72.95736694335938
],
[
"2020-03-24 04:54:00",
79.05335441995615,
85.12024688720703,
73.62250518798828
],
[
"2020-03-24 04:55:00",
79.00699594565926,
89.70301055908203,
72.9462661743164
],
[
"2020-03-24 04:56:00",
78.96063747136236,
98.89726257324219,
72.34540557861328
],
[
"2020-03-24 04:57:00",
78.91427899706547,
104.57252502441406,
73.3578872680664
],
[
"2020-03-24 04:58:00",
78.86792052276857,
103.37727355957031,
73.94607543945312
],
[
"2020-03-24 04:59:00",
78.82156204847168,
103.06717681884766,
72.9709701538086
],
[
"2020-03-24 05:00:00",
78.77520357417478,
102.50790405273438,
74.46186065673828
],
[
"2020-03-24 05:01:00",
78.72884509987789,
102.56554412841797,
72.30302429199219
],
[
"2020-03-24 05:02:00",
78.68248662558099,
100.72061157226562,
73.90963745117188
],
[
"2020-03-24 05:03:00",
78.6361281512841,
84.94855499267578,
72.5624771118164
],
[
"2020-03-24 05:04:00",
78.5897696769872,
73.80229949951172,
72.40718078613281
],
[
"2020-03-24 05:05:00",
78.54341120269031,
66.7529296875,
73.5855941772461
],
[
"2020-03-24 05:06:00",
78.49705272839341,
58.3730354309082,
73.1899185180664
],
[
"2020-03-24 05:07:00",
78.45069425409652,
54.12462615966797,
73.07763671875
],
[
"2020-03-24 05:08:00",
78.40433577979962,
51.171958923339844,
73.19320678710938
],
[
"2020-03-24 05:09:00",
78.35797730550273,
48.614585876464844,
72.81364440917969
],
[
"2020-03-24 05:10:00",
78.31161883120583,
55.98033905029297,
74.0353775024414
],
[
"2020-03-24 05:11:00",
78.26526035690894,
55.769962310791016,
74.27434539794922
],
[
"2020-03-24 05:12:00",
78.21890188261204,
55.67626190185547,
72.99474334716797
],
[
"2020-03-24 05:13:00",
78.17254340831515,
53.84586715698242,
73.18851470947266
],
[
"2020-03-24 05:14:00",
78.17000064599996,
49.15884017944336,
72.83944702148438
],
[
"2020-03-24 05:15:00",
78,
48.674129486083984,
72.74655151367188
],
[
"2020-03-24 05:16:00",
77.9366887710829,
48.823998987048924,
73.24293518066406
],
[
"2020-03-24 05:17:00",
77.90413912638326,
48.8282470703125,
72.28050994873047
],
[
"2020-03-24 05:18:00",
77.87158948168361,
49.756980895996094,
72.88276672363281
],
[
"2020-03-24 05:19:00",
77.83903983698399,
49.47259521484375,
73.35757446289062
],
[
"2020-03-24 05:20:00",
77.80649019228434,
49.850311279296875,
73.20963287353516
],
[
"2020-03-24 05:21:00",
77.77394054758471,
49.637855529785156,
72.9081039428711
],
[
"2020-03-24 05:22:00",
77.74139090288507,
49.61250305175781,
72.93186950683594
],
[
"2020-03-24 05:23:00",
77.70884125818544,
48.27946090698242,
74.17268371582031
],
[
"2020-03-24 05:24:00",
77.6762916134858,
48.74678421020508,
73.15660858154297
],
[
"2020-03-24 05:25:00",
77.64374196878616,
48.357120513916016,
72.6622543334961
],
[
"2020-03-24 05:26:00",
77.61119232408653,
49.31953430175781,
72.34400177001953
],
[
"2020-03-24 05:27:00",
77.57864267938689,
49.709964752197266,
72.97113037109375
],
[
"2020-03-24 05:28:00",
77.54609303468726,
50.2484130859375,
72.39154052734375
],
[
"2020-03-24 05:29:00",
77.51354338998762,
50.60381317138672,
72.06515502929688
],
[
"2020-03-24 05:30:00",
77.48099374528799,
50.00936508178711,
56.87029266357422
],
[
"2020-03-24 05:31:00",
77.44844410058835,
49.875885009765625,
16.654312133789062
],
[
"2020-03-24 05:32:00",
77.4158944558887,
48.563663482666016,
18.19554901123047
],
[
"2020-03-24 05:33:00",
77.38334481118908,
48.847572326660156,
18.055583953857422
],
[
"2020-03-24 05:34:00",
77.35079516648943,
48.35354232788086,
18.378847122192383
],
[
"2020-03-24 05:35:00",
77.3182455217898,
48.75905990600586,
17.62409782409668
],
[
"2020-03-24 05:36:00",
77.28569587709016,
48.05728530883789,
18.058086395263672
],
[
"2020-03-24 05:37:00",
77.25314623239053,
54.909175872802734,
17.759536743164062
],
[
"2020-03-24 05:38:00",
77.22059658769089,
54.575439453125,
17.888395309448242
],
[
"2020-03-24 05:39:00",
77.18804694299125,
55.046234130859375,
18.210878372192383
],
[
"2020-03-24 05:40:00",
77.15549729829162,
54.0140495300293,
17.824277877807617
],
[
"2020-03-24 05:41:00",
77.12294765359198,
53.690467834472656,
18.451248168945312
],
[
"2020-03-24 05:42:00",
77.09039800889235,
53.07158279418945,
18.209468841552734
],
[
"2020-03-24 05:43:00",
77.05784836419271,
53.31936264038086,
18.179603576660156
],
[
"2020-03-24 05:44:00",
77.02529871949308,
53.26475143432617,
18.342716217041016
],
[
"2020-03-24 05:45:00",
76.99274907479344,
51.945220947265625,
18.539770126342773
],
[
"2020-03-24 05:46:00",
76.9601994300938,
51.81389617919922,
18.015705108642578
],
[
"2020-03-24 05:47:00",
76.92764978539417,
51.123085021972656,
17.368398666381836
],
[
"2020-03-24 05:48:00",
76.89510014069452,
51.4550666809082,
18.14003562927246
],
[
"2020-03-24 05:49:00",
76.8625504959949,
50.60249710083008,
18.289703369140625
],
[
"2020-03-24 05:50:00",
76.83000085129525,
50.91603088378906,
18.2962646484375
],
[
"2020-03-24 05:51:00",
76.79745120659562,
53.06449508666992,
18.563539505004883
],
[
"2020-03-24 05:52:00",
76.76490156189598,
54.72663497924805,
18.568862915039062
],
[
"2020-03-24 05:53:00",
76.73235191719634,
54.90778732299805,
18.28094482421875
],
[
"2020-03-24 05:54:00",
76.69980227249671,
53.92911911010742,
18.02821159362793
],
[
"2020-03-24 05:55:00",
76.66725262779707,
53.20056915283203,
21.20859718322754
],
[
"2020-03-24 05:56:00",
76.63470298309744,
53.7746696472168,
70.31324768066406
],
[
"2020-03-24 05:57:00",
76.6021533383978,
54.07472610473633,
73.2507553100586
],
[
"2020-03-24 05:58:00",
76.56960369369816,
53.80739974975586,
73.81517791748047
],
[
"2020-03-24 05:59:00",
76.53705404899853,
53.748661041259766,
73.31723022460938
],
[
"2020-03-24 06:00:00",
76.50450440429888,
54.74142837524414,
72.85430145263672
],
[
"2020-03-24 06:01:00",
76.47195475959926,
56.06607437133789,
73.29580688476562
],
[
"2020-03-24 06:02:00",
76.46999418600018,
55.171714782714844,
72.67166195723287
],
[
"2020-03-24 06:03:00",
76.29999354000017,
55.41927719116211,
72.6522445678711
],
[
"2020-03-24 06:04:00",
76.17097911658006,
55.45018005371094,
73.24137115478516
],
[
"2020-03-24 06:05:00",
76.10446483646761,
55.66059112548828,
72.9041976928711
],
[
"2020-03-24 06:06:00",
76.03795055635517,
49.595481872558594,
73.65878295898438
],
[
"2020-03-24 06:07:00",
75.97143627624271,
47.00128173828125,
72.86134338378906
],
[
"2020-03-24 06:08:00",
75.90492199613027,
47.58378601074219,
72.69776153564453
],
[
"2020-03-24 06:09:00",
75.83840771601783,
49.07365417480469,
72.17729187011719
],
[
"2020-03-24 06:10:00",
75.77189343590538,
56.555606842041016,
72.93250274658203
],
[
"2020-03-24 06:11:00",
75.70537915579293,
56.26713180541992,
72.06671905517578
],
[
"2020-03-24 06:12:00",
75.63886487568048,
55.18650817871094,
73.08904266357422
],
[
"2020-03-24 06:13:00",
75.57235059556804,
48.025177001953125,
73.17881774902344
],
[
"2020-03-24 06:14:00",
75.50583631545558,
47.967350006103516,
73.10953521728516
],
[
"2020-03-24 06:15:00",
75.43932203534314,
49.351463317871094,
72.9697265625
],
[
"2020-03-24 06:16:00",
75.3728077552307,
57.63689041137695,
73.93919372558594
],
[
"2020-03-24 06:17:00",
75.30629347511824,
51.609039306640625,
73.03306579589844
],
[
"2020-03-24 06:18:00",
75.2397791950058,
49.73860549926758,
73.2399673461914
],
[
"2020-03-24 06:19:00",
75.17326491489335,
50.75581359863281,
72.73904418945312
],
[
"2020-03-24 06:20:00",
75.1067506347809,
50.66218566894531,
72.50445556640625
],
[
"2020-03-24 06:21:00",
75.04023635466845,
50.81214141845703,
72.9201431274414
],
[
"2020-03-24 06:22:00",
74.97372207455601,
51.4454231262207,
72.74983978271484
],
[
"2020-03-24 06:23:00",
74.90720779444355,
51.69704055786133,
72.99396514892578
],
[
"2020-03-24 06:24:00",
74.84069351433111,
51.35186767578125,
73.40730285644531
],
[
"2020-03-24 06:25:00",
74.77417923421866,
50.72081756591797,
72.23859405517578
],
[
"2020-03-24 06:26:00",
74.76998772600024,
50.91818618774414,
73.011474609375
],
[
"2020-03-24 06:27:00",
74.59998708000028,
50.9371452331543,
73.52397918701172
],
[
"2020-03-24 06:28:00",
74.47115968724424,
51.061458587646484,
73.56307220458984
],
[
"2020-03-24 06:29:00",
74.40464696005053,
50.900325775146484,
73.50645446777344
],
[
"2020-03-24 06:30:00",
74.33813423285682,
51.356689453125,
73.11031341552734
],
[
"2020-03-24 06:31:00",
74.2716215056631,
51.44089126586914,
74.34957122802734
],
[
"2020-03-24 06:32:00",
74.2051087784694,
51.28786849975586,
73.98580169677734
],
[
"2020-03-24 06:33:00",
74.13859605127568,
51.93085537607588,
72.36542510986328
],
[
"2020-03-24 06:34:00",
74.07208332408197,
51.952125549316406,
72.51180267333984
],
[
"2020-03-24 06:35:00",
74.00557059688826,
57.87371063232422,
73.43373107910156
],
[
"2020-03-24 06:36:00",
73.93905786969457,
80.50335693359375,
73.54712677001953
],
[
"2020-03-24 06:37:00",
73.87254514250085,
86.00247192382812,
73.6276626586914
],
[
"2020-03-24 06:38:00",
73.80603241530714,
92.10163116455078,
73.07763671875
],
[
"2020-03-24 06:39:00",
73.73951968811343,
92.22298431396484,
72.73919677734375
],
[
"2020-03-24 06:40:00",
73.67300696091972,
91.8537368774414,
72.59422302246094
],
[
"2020-03-24 06:41:00",
73.60649423372601,
91.79039764404297,
72.58702850341797
],
[
"2020-03-24 06:42:00",
73.5399815065323,
92.08602905273438,
73.7885971069336
],
[
"2020-03-24 06:43:00",
73.47346877933859,
92.87781524658203,
72.7099609375
],
[
"2020-03-24 06:44:00",
73.40695605214488,
96.19808197021484,
73.00537872314453
],
[
"2020-03-24 06:45:00",
73.34044332495118,
96.97959899902344,
73.0341567993164
],
[
"2020-03-24 06:46:00",
73.27393059775747,
92.9488296508789,
73.91197967529297
],
[
"2020-03-24 06:47:00",
73.20741787056376,
93.09352111816406,
72.77579498291016
],
[
"2020-03-24 06:48:00",
73.14090514337005,
91.96395111083984,
71.88639831542969
],
[
"2020-03-24 06:49:00",
73.07439241617634,
92.7508773803711,
73.19898986816406
],
[
"2020-03-24 06:50:00",
73.07001033599973,
91.7613525390625,
73.58168029785156
],
[
"2020-03-24 06:51:00",
72.90001291999972,
90.88325500488281,
73.70819854736328
],
[
"2020-03-24 06:52:00",
72.74429166862062,
90.33417510986328,
72.71105194091797
],
[
"2020-03-24 06:53:00",
72.66377465236994,
95.02799224853516,
75.33968353271484
],
[
"2020-03-24 06:54:00",
72.58325763611924,
96.9925308227539,
74.09574890136719
],
[
"2020-03-24 06:55:00",
72.50274061986855,
96.695068359375,
73.8018798828125
],
[
"2020-03-24 06:56:00",
72.42222360361787,
95.75796508789062,
74.43511199951172
],
[
"2020-03-24 06:57:00",
72.34170658736717,
96.17393493652344,
74.73851776123047
],
[
"2020-03-24 06:58:00",
72.26118957111649,
88.4173812866211,
75.60273742675781
],
[
"2020-03-24 06:59:00",
72.1806725548658,
88.39751434326172,
74.84156799316406
],
[
"2020-03-24 07:00:00",
72.1001555386151,
87.41456604003906,
74.45763397216797
],
[
"2020-03-24 07:01:00",
72.01963852236442,
87.65657806396484,
73.62500762939453
],
[
"2020-03-24 07:02:00",
71.93912150611372,
87.04649353027344,
75.57865142822266
],
[
"2020-03-24 07:03:00",
71.85860448986304,
87.92521667480469,
74.86284637451172
],
[
"2020-03-24 07:04:00",
71.77808747361235,
85.46574401855469,
74.23040008544922
],
[
"2020-03-24 07:05:00",
71.69757045736166,
51.844181060791016,
73.2090072631836
],
[
"2020-03-24 07:06:00",
71.61705344111097,
36.57521057128906,
74.82296752929688
],
[
"2020-03-24 07:07:00",
71.53653642486027,
34.56216812133789,
74.66110229492188
],
[
"2020-03-24 07:08:00",
71.45601940860959,
48.19200897216797,
73.77107238769531
],
[
"2020-03-24 07:09:00",
71.3755023923589,
52.86350631713867,
74.53269958496094
],
[
"2020-03-24 07:10:00",
71.37000710599979,
52.843929290771484,
73.5987319946289
],
[
"2020-03-24 07:11:00",
71.20000645999983,
52.08213424682617,
74.15689849853516
],
[
"2020-03-24 07:12:00",
71.03583251441142,
51.53842544555664,
73.91010284423828
],
[
"2020-03-24 07:13:00",
70.95084242170037,
43.506919860839844,
73.70914459228516
],
[
"2020-03-24 07:14:00",
70.86585232898932,
43.037841796875,
73.2168197631836
],
[
"2020-03-24 07:15:00",
70.78086223627825,
43.77318572998047,
74.06806182861328
],
[
"2020-03-24 07:16:00",
70.6958721435672,
46.766944885253906,
74.05726623535156
],
[
"2020-03-24 07:17:00",
70.61088205085615,
50.872379302978516,
74.08291625976562
],
[
"2020-03-24 07:18:00",
70.5258919581451,
51.395668029785156,
74.64201354980469
],
[
"2020-03-24 07:19:00",
70.44090186543403,
50.60863494873047,
73.44953155517578
],
[
"2020-03-24 07:20:00",
70.35591177272298,
40.730621337890625,
72.79737854003906
],
[
"2020-03-24 07:21:00",
70.27092168001192,
41.385196685791016,
73.6615982055664
],
[
"2020-03-24 07:22:00",
70.18593158730087,
52.25959777832031,
73.92058563232422
],
[
"2020-03-24 07:23:00",
70.10094149458982,
46.88405990600586,
74.61308288574219
],
[
"2020-03-24 07:24:00",
70.01595140187875,
47.141448974609375,
73.66790870618443
],
[
"2020-03-24 07:25:00",
69.9309613091677,
47.107181549072266,
73.63360595703125
],
[
"2020-03-24 07:26:00",
69.84597121645665,
47.4166259765625,
74.238525390625
],
[
"2020-03-24 07:27:00",
69.7609811237456,
46.56296157836914,
73.82565307617188
],
[
"2020-03-24 07:28:00",
69.67599103103453,
46.3474006652832,
72.98832702636719
],
[
"2020-03-24 07:29:00",
69.67000064599995,
47.08136046272777,
73.30158233642578
],
[
"2020-03-24 07:30:00",
69.5,
47.10820770263672,
73.27828216552734
],
[
"2020-03-24 07:31:00",
69.32637243713472,
47.034088134765625,
73.60092163085938
],
[
"2020-03-24 07:32:00",
69.23638277037952,
45.57647705078125,
73.87054443359375
],
[
"2020-03-24 07:33:00",
69.1463931036243,
51.21367645263672,
72.25328826904297
],
[
"2020-03-24 07:34:00",
69.0564034368691,
70.96977996826172,
73.15692138671875
],
[
"2020-03-24 07:35:00",
68.96641377011389,
76.6375961303711,
72.21951293945312
],
[
"2020-03-24 07:36:00",
68.87642410335869,
83.16655731201172,
74.12545776367188
],
[
"2020-03-24 07:37:00",
68.78643443660347,
83.07859802246094,
72.88916991454134
],
[
"2020-03-24 07:38:00",
68.69644476984827,
92.17417907714844,
72.8433609008789
],
[
"2020-03-24 07:39:00",
68.60645510309305,
92.9948959350586,
73.65784454345703
],
[
"2020-03-24 07:40:00",
68.51646543633785,
92.51905822753906,
72.56232452392578
],
[
"2020-03-24 07:41:00",
68.42647576958265,
91.8058090209961,
73.06637573242188
],
[
"2020-03-24 07:42:00",
68.33648610282744,
90.04006958007812,
72.91545104980469
],
[
"2020-03-24 07:43:00",
68.24649643607223,
85.17295837402344,
73.79078674316406
],
[
"2020-03-24 07:44:00",
68.15650676931702,
95.68914794921875,
72.5380859375
],
[
"2020-03-24 07:45:00",
68.06651710256182,
74.87901306152344,
73.2021255493164
],
[
"2020-03-24 07:46:00",
67.9765274358066,
60.12022018432617,
73.76215362548828
],
[
"2020-03-24 07:47:00",
67.96999418600018,
53.05949020385742,
73.28720092773438
],
[
"2020-03-24 07:48:00",
67.79999354000017,
48.9787483215332,
73.20462799072266
],
[
"2020-03-24 07:49:00",
67.60342746002077,
49.55990219116211,
72.59485626220703
],
[
"2020-03-24 07:50:00",
67.50143795130171,
50.27000427246094,
73.38900756835938
],
[
"2020-03-24 07:51:00",
67.39944844258264,
49.79863766947178,
72.78111267089844
],
[
"2020-03-24 07:52:00",
67.29745893386358,
49.78076171875,
73.90713500976562
],
[
"2020-03-24 07:53:00",
67.19546942514451,
50.86861801147461,
38.183509826660156
],
[
"2020-03-24 07:54:00",
67.09347991642545,
51.039466857910156,
17.961437225341797
],
[
"2020-03-24 07:55:00",
66.99149040770638,
51.160526275634766,
19.09199333190918
],
[
"2020-03-24 07:56:00",
66.88950089898731,
50.949893951416016,
18.68396759033203
],
[
"2020-03-24 07:57:00",
66.78751139026825,
51.169769287109375,
17.29629898071289
],
[
"2020-03-24 07:58:00",
66.68552188154918,
50.19011306762695,
18.370710372924805
]
]
},
"events": {
"dom": {
"onClick": {
"config": {
"script": "\tdata \u003d []\n\ttable \u003d []\n\n\n\tif self.getSibling(\"TabContainer\").props.currentTabIndex \u003d\u003d 0:\n\t\tresults \u003d self.parent.getChild(\"TabContainer\").getChild(\"AlarmSummary\").getChild(\"AlarmSummary\").props.filter.results.data\n\t\tif(len(results) \u003e 0):\n\t\t\theaders \u003d [\"Number (ID)\", \"Event TimeStamp\",\"Duration\",\"Class\",\"Location\",\"Description\",\"Tag\"]\n\t\t\tfor result in results:\n\t\t\t\tdata.append([result[\u0027NumberID\u0027],result[\u0027EventTimestamp\u0027],result[\u0027Duration\u0027],result[\u0027Class\u0027],result[\u0027Area\u0027],result[\u0027Description\u0027],result[\u0027Tag\u0027]])\n\t\n\t\telse:\n\t\t\theaders \u003d [\"Number (ID)\", \"Event TimeStamp\",\"Duration\",\"Class\",\"Location\",\"Description\",\"Tag\"]\n\t\t\tfor row in self.parent.getChild(\"TabContainer\").getChild(\"AlarmSummary\").getChild(\"AlarmSummary\").props.data:\n\t\t\t\tdata.append([row[\u0027value\u0027][\u0027NumberID\u0027],row[\u0027value\u0027][\u0027EventTimestamp\u0027],row[\u0027value\u0027][\u0027Duration\u0027],row[\u0027value\u0027][\u0027Class\u0027],row[\u0027value\u0027][\u0027Area\u0027],row[\u0027value\u0027][\u0027Description\u0027],row[\u0027value\u0027][\u0027Tag\u0027]])\n\t\t\n\t\ttable \u003d system.dataset.toDataSet(headers, data)\t\n\t\tcsv \u003d system.dataset.toCSV(table,1,0,1)\n\t\tsystem.perspective.download(filename \u003d \u0027AlarmSummary.csv\u0027, data \u003d csv)\t\n\n\t\n\telif self.getSibling(\"TabContainer\").props.currentTabIndex \u003d\u003d 1:\n\t\tresults \u003d self.parent.getChild(\"TabContainer\").getChild(\"Alarm History\").getChild(\"HistoryAlarm\").props.filter.results.data\n\t\tif(len(results) \u003e 0):\n\t\t\theaders \u003d [\"Number (ID)\", \"Start TimeStamp\", \"End TimeStamp\",\"Duration\",\"Class\",\"Location\",\"Description\",\"Tag\"]\n\t\t\tfor result in results:\n\t\t\t\tdata.append([result[\u0027NumberID\u0027],result[\u0027StartTimestamp\u0027],result[\u0027EndTimestamp\u0027],result[\u0027Duration\u0027],result[\u0027Class\u0027],result[\u0027Area\u0027],result[\u0027Description\u0027],result[\u0027Tag\u0027]])\n\t\t\t\n\t\telse:\n\t\t\theaders \u003d [\"Number (ID)\", \"Start TimeStamp\", \"End TimeStamp\",\"Duration\",\"Class\",\"Location\",\"Description\",\"Tag\"]\n\t\t\tfor row in self.parent.getChild(\"TabContainer\").getChild(\"Alarm History\").getChild(\"HistoryAlarm\").props.data:\n\t\t\t\tdata.append([row[\u0027value\u0027][\u0027NumberID\u0027],row[\u0027value\u0027][\u0027StartTimestamp\u0027],row[\u0027value\u0027][\u0027EndTimestamp\u0027],row[\u0027value\u0027][\u0027Duration\u0027],row[\u0027value\u0027][\u0027Class\u0027],row[\u0027value\u0027][\u0027Area\u0027],row[\u0027value\u0027][\u0027Description\u0027],row[\u0027value\u0027][\u0027Tag\u0027]])\n\t\t\t\n\t\ttable \u003d system.dataset.toDataSet(headers, data)\t\n\t\tcsv \u003d system.dataset.toCSV(table,1,0,1)\n\t\tsystem.perspective.download(filename \u003d \u0027Alarm History.csv\u0027, data \u003d csv)\n\t\n\t\n\telif self.getSibling(\"TabContainer\").props.currentTabIndex \u003d\u003d 2:\n\t\tresults \u003d self.parent.getChild(\"TabContainer\").getChild(\"AlarmHitList\").getChild(\"AlarmHitList\").props.filter.results.data\n\t\tif(len(results) \u003e 0):\n\t\t\theaders \u003d [\"First TimeStamp\", \"Last TimeStamp\",\"Count\", \"Duration\",\"Class\",\"Location\",\"Description\",\"Tag\"]\n\t\t\tfor result in results:\n\t\t\t\tdata.append([result[\u0027StartTimestamp\u0027],result[\u0027EndTimestamp\u0027],result[\u0027Count\u0027],result[\u0027Duration\u0027],result[\u0027Class\u0027],result[\u0027Area\u0027],result[\u0027Description\u0027],result[\u0027Tag\u0027]])\n\t\n\t\telse:\n\t\t\theaders \u003d [\"First TimeStamp\", \"Last TimeStamp\",\"Count\", \"Duration\",\"Class\",\"Location\",\"Description\",\"Tag\"]\n\t\t\tfor row in self.parent.getChild(\"TabContainer\").getChild(\"AlarmHitList\").getChild(\"AlarmHitList\").props.data:\n\t\t\t\tdata.append([row[\u0027value\u0027][\u0027StartTimestamp\u0027],row[\u0027value\u0027][\u0027EndTimestamp\u0027],row[\u0027value\u0027][\u0027Count\u0027],row[\u0027value\u0027][\u0027Duration\u0027],row[\u0027value\u0027][\u0027Class\u0027],row[\u0027value\u0027][\u0027Area\u0027],row[\u0027value\u0027][\u0027Description\u0027],row[\u0027value\u0027][\u0027Tag\u0027]])\n\t\t\t\n\t\ttable \u003d system.dataset.toDataSet(headers, data)\t\n\t\tcsv \u003d system.dataset.toCSV(table,1,0,1)\n\t\tsystem.perspective.download(filename \u003d \u0027Alarm HitList.csv\u0027, data \u003d csv)"
},
"scope": "G",
"type": "script"
}
}
},
"meta": {
"name": "ExporttoCSV",
"tooltip": {
"enabled": true,
"location": "bottom-right",
"style": {
"backgroundColor": "#2B2B2BBF",
"color": "#FFFFFF",
"fontSize": 14,
"textAlign": "left",
"white-space": "pre"
},
"sustain": 2000
}
},
"position": {
"height": 25,
"width": 120,
"x": 1795,
"y": -10
},
"propConfig": {
"meta.tooltip.text": {
"binding": {
"config": {
"expression": "\"About: Export to CSV\"+ \r\n\"\\n\"+\r\n\"\\n\"+\"Which tab with alarms is open that\"+ \r\n\"\\n\"+\"table will be exported to CSV\"+ \r\n\"\\n\"+\"file after clicking on the button.\""
},
"type": "expr"
}
}
},
"props": {
"style": {
"classes": "Button_Action",
"fontFamily": "Arial",
"marginBottom": "2px",
"marginTop": "16px"
},
"text": "Export to CSV"
},
"type": "ia.input.button"
},
{
"meta": {
"name": "LabelMinClass",
"tooltip": {
"enabled": true,
"location": "bottom",
"style": {
"backgroundColor": "#2B2B2BBF",
"color": "#FFFFFF",
"fontSize": 14,
"textAlign": "left",
"white-space": "pre"
}
}
},
"position": {
"height": 25,
"width": 86,
"x": 1540,
"y": 5
},
"propConfig": {
"meta.tooltip.text": {
"binding": {
"config": {
"expression": "\"About: Min Class\"+ \r\n\"\\n\"+\r\n\"\\n\"+\"If selected:\"+ \r\n\"\\n\"+\"Error is displayed by Alarm with class Error.\"+ \r\n\"\\n\"+\"Warning is displayed Alarm with class Error and Warning.\"+ \r\n\"\\n\"+\"Message is displayed by Alarm with class Error, Warning and Message.\""
},
"type": "expr"
}
}
},
"props": {
"text": "Min Class:",
"textStyle": {
"fontFamily": "Arial"
}
},
"type": "ia.display.label"
},
{
"meta": {
"name": "DropdownMinClass",
"tooltip": {
"location": "bottom",
"style": {
"backgroundColor": "#2B2B2BBF",
"color": "#FFFFFF",
"fontSize": 14,
"textAlign": "left",
"white-space": "pre"
},
"sustain": 2000
}
},
"position": {
"height": 25,
"width": 146,
"x": 1628.22,
"y": 5
},
"propConfig": {
"meta.tooltip.text": {
"binding": {
"config": {
"expression": "\"About: Min Class\"+ \r\n\"\\n\"+\r\n\"\\n\"+\"If selected:\"+ \r\n\"\\n\"+\"Error is displayed by Alarm with class Error.\"+ \r\n\"\\n\"+\"Warning is displayed Alarm with class Error and Warning.\"+ \r\n\"\\n\"+\"Message is displayed by Alarm with class Error, Warning and Message.\""
},
"type": "expr"
}
}
},
"props": {
"options": [
{
"label": "Error",
"value": "Error"
},
{
"label": "Warning",
"value": "Warning"
},
{
"label": "Message",
"value": "Message"
}
],
"style": {
"fontFamily": "Arial"
},
"value": "Error"
},
"type": "ia.input.dropdown"
},
{
"children": [
{
"meta": {
"name": "LPeriod"
},
"position": {
"basis": "60px"
},
"props": {
"text": "Period:"
},
"type": "ia.display.label"
},
{
"meta": {
"name": "Period"
},
"position": {
"basis": "160px"
},
"props": {
"options": [
{
"label": "Past 30 Min",
"value": "Past 30 Min"
},
{
"label": "Past Hour",
"value": "Past Hour"
},
{
"label": "Past 2 Hour",
"value": "Past 2 Hour"
},
{
"label": "Past 4 Hour",
"value": "Past 4 Hour"
},
{
"label": "Past 8 Hour",
"value": "Past 8 Hour"
},
{
"label": "Current Day",
"value": "Current Day"
},
{
"label": "Morning",
"value": "Morning"
},
{
"label": "Daylight",
"value": "Daylight"
},
{
"label": "Twilight",
"value": "Twilight"
},
{
"label": "Night",
"value": "Night"
},
{
"label": "Wrap Down",
"value": "Wrap Down"
},
{
"label": "Current Sort",
"value": "Current Sort"
},
{
"label": "Custom",
"value": "Custom"
}
],
"value": "Past 30 Min"
},
"type": "ia.input.dropdown"
},
{
"meta": {
"name": "Spare_0"
},
"position": {
"basis": "18.1px"
},
"type": "ia.display.label"
},
{
"meta": {
"name": "Start Date"
},
"position": {
"basis": "85px"
},
"props": {
"text": "Start Date:"
},
"type": "ia.display.label"
},
{
"custom": {
"Selected": {
"$": [
"ts",
192,
1650086842753
],
"$ts": 1649998620000
}
},
"events": {
"component": {
"onActionPerformed": {
"config": {
"script": "\t\n\tself.custom.Selected \u003d self.props.value"
},
"scope": "G",
"type": "script"
}
}
},
"meta": {
"name": "StartTime"
},
"propConfig": {
"props.enabled": {
"binding": {
"config": {
"expression": "{../Period.props.value} \u003d \"Custom\""
},
"type": "expr"
}
},
"props.maxDate": {
"binding": {
"config": {
"expression": "now()"
},
"type": "expr"
}
},
"props.startDate": {
"binding": {
"config": {
"path": "../Period.props.value"
},
"transforms": [
{
"fallback": "todate(now())",
"inputType": "expression",
"mappings": [
{
"input": "\"Past 30 Min\"",
"output": "todate(dateFormat(dateArithmetic(now(),-30, \"Minute\"), \"yyyy-MM-dd HH:mm:ss\"))"
},
{
"input": "\"Past Hour\"",
"output": "todate(dateFormat(dateArithmetic(now(),-1, \"Hour\"), \"yyyy-MM-dd HH:mm:ss\"))"
},
{
"input": "\"Past 2 Hour\"",
"output": "todate(dateFormat(dateArithmetic(now(),-2, \"Hour\"), \"yyyy-MM-dd HH:mm:ss\"))"
},
{
"input": "\"Past 4 Hour\"",
"output": "todate(dateFormat(dateArithmetic(now(),-4, \"Hour\"), \"yyyy-MM-dd HH:mm:ss\"))"
},
{
"input": "\"Past 8 Hour\"",
"output": "todate(dateFormat(dateArithmetic(now(),-8, \"Hour\"), \"yyyy-MM-dd HH:mm:ss\"))"
},
{
"input": "\"Current Day\"",
"output": "todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 00:00:00\"))"
},
{
"input": "\"Morning\"",
"output": "if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"2:30:00\",\r dateFormat(dateArithmetic(now(0),-1, \"Day\"), \"yyyy-MM-dd 2:30:00\"),todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 2:30:00\")))"
},
{
"input": "\"Daylight\"",
"output": "if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"7:30:00\", todate(dateFormat(dateArithmetic(now(0),-1, \"Day\"), \"yyyy-MM-dd 7:30:00\")),todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 7:30:00\")))"
},
{
"input": "\"Twilight\"",
"output": "if (dateFormat(dateArithmetic(now(),0, \"Hours\"), \"HH:mm:ss\")\u003c\"13:00:00\", todate(dateFormat(dateArithmetic(now(0),-1, \"Day\"), \"yyyy-MM-dd 13:00:00\")),todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 13:00:00\")))"
},
{
"input": "\"Night\"",
"output": "if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"18:30:00\", todate(dateFormat(dateArithmetic(now(0),-1, \"Day\"), \"yyyy-MM-dd 18:30:00\")),todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 18:30:00\")))"
},
{
"input": "\"Wrap Down\"",
"output": "if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"23:30:00\", todate(dateFormat(dateArithmetic(now(0),-1, \"Day\"), \"yyyy-MM-dd 23:30:00\")),todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 23:30:00\")))"
},
{
"input": "\"Current Sort\"",
"output": "if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"7:30:00\", todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 2:30:00\")), \r if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"13:00:00\",todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 7:30:00\")),\r if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"18:30:00\",todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 13:00:00\")),\r if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"23:30:00\",todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 18:30:00\")),\r if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"2:30:00\", todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 23:30:00\")),\r todate(dateFormat(dateArithmetic(now(),0, \"Day\"), \"yyyy-MM-dd HH:mm:ss\")))))))"
},
{
"input": "\"Custom\"",
"output": "{this.props.value}"
}
],
"outputType": "expression",
"type": "map"
}
],
"type": "property"
},
"onChange": {
"enabled": null,
"script": "\t\n\tif self.getSibling(\"Period\").props.value !\u003d \"Custom\":\n\t\tself.props.value \u003d self.props.startDate"
}
},
"props.value": {
"onChange": {
"enabled": null,
"script": "\t\n\tif system.date.secondsBetween(self.props.value,self.getSibling(\"EndTime\").props.value) \u003e 604800:\n\t\tself.getSibling(\"EndTime\").props.value \u003d system.date.addSeconds(self.props.value,604800)"
}
}
},
"props": {
"dismissOnSelect": false,
"formattedValue": "Oct 19, 2023 1:43 PM",
"formattedValues": {
"date": "Mar 26, 2021",
"datetime": "Mar 26, 2021 12:00 AM",
"time": "12:00 AM"
},
"value": {
"$": [
"ts",
192,
1697714006006
],
"$ts": 1697712206000
}
},
"type": "ia.input.date-time-input"
},
{
"meta": {
"name": "Spare"
},
"position": {
"basis": "18.1px"
},
"type": "ia.display.label"
},
{
"meta": {
"name": "End Date"
},
"position": {
"basis": "81px"
},
"props": {
"text": "End Date:"
},
"type": "ia.display.label"
},
{
"custom": {
"Selected": {
"$": [
"ts",
192,
1650086856843
],
"$ts": 1650086779000
}
},
"events": {
"component": {
"onActionPerformed": {
"config": {
"script": "\t\t\n\tself.custom.Selected \u003d self.props.value"
},
"scope": "G",
"type": "script"
}
}
},
"meta": {
"name": "EndTime"
},
"position": {
"basis": "190px"
},
"propConfig": {
"props.enabled": {
"binding": {
"config": {
"expression": "{../Period.props.value} \u003d \"Custom\""
},
"type": "expr"
}
},
"props.endDate": {
"binding": {
"config": {
"path": "../Period.props.value"
},
"transforms": [
{
"fallback": "{this.props.value}",
"inputType": "scalar",
"mappings": [
{
"input": "Past 30 Min",
"output": "todate(dateFormat(dateArithmetic(now(),0, \"Hour\"), \"yyyy-MM-dd HH:mm:ss\"))"
},
{
"input": "Past Hour",
"output": "todate(dateFormat(dateArithmetic(now(),0, \"hour\"), \"yyyy-MM-dd HH:mm:ss\"))"
},
{
"input": "Past 2 Hour",
"output": "todate(dateFormat(dateArithmetic(now(),0, \"hour\"), \"yyyy-MM-dd HH:mm:ss\"))"
},
{
"input": "Past 4 Hour",
"output": "todate(dateFormat(dateArithmetic(now(),0, \"hour\"), \"yyyy-MM-dd HH:mm:ss\"))"
},
{
"input": "Past 8 Hour",
"output": "todate(dateFormat(dateArithmetic(now(),0, \"hour\"), \"yyyy-MM-dd HH:mm:ss\"))"
},
{
"input": "Current Day",
"output": "todate(dateFormat(dateArithmetic(now(),0, \"hour\"), \"yyyy-MM-dd HH:mm:ss\"))"
},
{
"input": "Morning",
"output": "if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"2:30:00\",\r todate(dateFormat(dateArithmetic(now(0),-1, \"Day\"), \"yyyy-MM-dd 7:30:00\")),\r if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"7:30:00\",\r todate(dateFormat(dateArithmetic(now(),0, \"Day\"), \"yyyy-MM-dd HH:mm:ss\")), todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 7:30:00\"))))"
},
{
"input": "Daylight",
"output": "if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"7:30:00\",\r todate(dateFormat(dateArithmetic(now(0),-1, \"Day\"), \"yyyy-MM-dd 13:00:00\")),\r if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"13:00:00\",\r todate(dateFormat(dateArithmetic(now(),0, \"Day\"), \"yyyy-MM-dd HH:mm:ss\")), todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 13:00:00\"))))"
},
{
"input": "Twilight",
"output": "if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"13:00:00\",\r todate(dateFormat(dateArithmetic(now(0),-1, \"Day\"), \"yyyy-MM-dd 18:30:00\")),\r if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"18:30:00\",\r todate(dateFormat(dateArithmetic(now(),0, \"Day\"), \"yyyy-MM-dd HH:mm:ss\")), todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 18:30:00\"))))"
},
{
"input": "Night",
"output": "if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"18:30:00\",\r todate(dateFormat(dateArithmetic(now(0),-1, \"Day\"), \"yyyy-MM-dd 23:30:00\")),\r if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"23:30:00\",\r todate(dateFormat(dateArithmetic(now(),0, \"Day\"), \"yyyy-MM-dd HH:mm:ss\")), todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 23:30:00\"))))"
},
{
"input": "Wrap Down",
"output": "if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"23:30:00\",\r todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 2:30:00\")),\r if (dateFormat(dateArithmetic(now(),0, \"Day\"), \"HH:mm:ss\")\u003c\"2:30:00\",\r todate(dateFormat(dateArithmetic(now(),0, \"Day\"), \"yyyy-MM-dd HH:mm:ss\")), todate(dateFormat(dateArithmetic(now(0),0, \"Day\"), \"yyyy-MM-dd 2:30:00\"))))"
},
{
"input": "Current Sort",
"output": "todate(dateFormat(dateArithmetic(now(),0, \"hour\"), \"yyyy-MM-dd HH:mm:ss\"))"
}
],
"outputType": "expression",
"type": "map"
}
],
"type": "property"
},
"onChange": {
"enabled": null,
"script": "\t\n\tif self.getSibling(\"Period\").props.value !\u003d \"Custom\":\n\t\tself.props.value \u003d self.props.endDate"
}
},
"props.maxDate": {
"binding": {
"config": {
"expression": "if(dateDiff({../StartTime.props.value},now(),\"day\") \u003c 7, now(),dateArithmetic({../StartTime.props.value}, 7, \"days\"))"
},
"type": "expr"
}
},
"props.minDate": {
"binding": {
"config": {
"expression": "{../StartTime.props.value}"
},
"type": "expr"
}
}
},
"props": {
"dismissOnSelect": false,
"formattedValue": "Oct 19, 2023 2:13 PM",
"formattedValues": {
"date": "Mar 29, 2021",
"datetime": "Mar 29, 2021 1:37 PM",
"time": "1:37 PM"
},
"value": {
"$": [
"ts",
192,
1697714006006
],
"$ts": 1697714006000
}
},
"type": "ia.input.date-time-input"
}
],
"meta": {
"name": "Period_not_Global"
},
"position": {
"height": 25,
"width": 793,
"x": 713.982,
"y": 5
},
"propConfig": {
"custom.EndDate": {
"binding": {
"config": {
"path": "./EndTime.props.value"
},
"type": "property"
}
},
"custom.StartDate": {
"binding": {
"config": {
"path": "./StartTime.props.value"
},
"type": "property"
}
},
"meta.visible": {
"binding": {
"config": {
"expression": "if ({../TabContainer.props.currentTabIndex} \u003d 0,\r\n\tFALSE,\r\n\tTRUE)"
},
"type": "expr"
}
}
},
"props": {
"style": {
"fontFamily": "Arial"
}
},
"type": "ia.container.flex"
}
],
"meta": {
"name": "root"
},
"position": {
"x": -218.78125,
"y": -9
},
"type": "ia.container.coord"
}
}