Merge pull request 'D2C Chutes' (#130) from d2c-chutes into main

Reviewed-on: #130
This commit is contained in:
gigi.mamaladze 2025-06-20 13:55:00 +00:00
commit d72618affd
8 changed files with 3895 additions and 139 deletions

View File

@ -33,6 +33,38 @@
"viewPath": "Detailed-Views/MCM03 Non Con"
},
"/DetailedView/MCM04 Bulk Inbound Problem Solve, Fluid Outbound and Problem Solve": {
"docks": {
"right": [
{
"anchor": "fixed",
"autoBreakpoint": 480,
"content": "cover",
"handle": "hide",
"iconUrl": "",
"id": "Docked-East-SNP",
"modal": false,
"resizable": false,
"show": "onDemand",
"size": 400,
"viewParams": {},
"viewPath": "PopUp-Views/Controller-Equipment/Information-Docked-East-StatusNonPowered"
},
{
"anchor": "fixed",
"autoBreakpoint": 480,
"content": "cover",
"handle": "hide",
"iconUrl": "",
"id": "Docked-East-JR",
"modal": false,
"resizable": false,
"show": "onDemand",
"size": 400,
"viewParams": {},
"viewPath": "PopUp-Views/Controller-Equipment/Information-Docked-East-JR-PB"
}
]
},
"title": "",
"viewPath": "Detailed-Views/MCM04 North Bulk Inbound, Fluid Outbound and Problem Solve"
},
@ -143,6 +175,48 @@
"size": 400,
"viewParams": {},
"viewPath": "PopUp-Views/Controller-Equipment/Information-Docked-East"
},
{
"anchor": "fixed",
"autoBreakpoint": 480,
"content": "cover",
"handle": "hide",
"iconUrl": "",
"id": "Docked-East-SNP",
"modal": false,
"resizable": false,
"show": "onDemand",
"size": 400,
"viewParams": {},
"viewPath": "PopUp-Views/Controller-Equipment/Information-Docked-East-StatusNonPowered"
},
{
"anchor": "fixed",
"autoBreakpoint": 480,
"content": "cover",
"handle": "hide",
"iconUrl": "",
"id": "Docked-East-JR",
"modal": false,
"resizable": false,
"show": "onDemand",
"size": 400,
"viewParams": {},
"viewPath": "PopUp-Views/Controller-Equipment/Information-Docked-East-JR-PB"
},
{
"anchor": "fixed",
"autoBreakpoint": 480,
"content": "cover",
"handle": "hide",
"iconUrl": "",
"id": "Docked-East-VFD",
"modal": false,
"resizable": false,
"show": "onDemand",
"size": 400,
"viewParams": {},
"viewPath": "PopUp-Views/Controller-Equipment/Information-Docked-East-VFD"
}
],
"top": [

View File

@ -966,7 +966,7 @@
"forceFaultStatus": null,
"forceRunningStatus": null,
"tagProps": [
"System/MCM04/StatusNonPowered_NS/S011055",
"/System/D2C/D2C_Chute_2",
"value",
"value",
"value",
@ -1001,7 +1001,7 @@
"forceFaultStatus": null,
"forceRunningStatus": null,
"tagProps": [
"System/MCM04/StatusNonPowered_NS/S011053",
"/System/D2C/D2C_Chute_3",
"value",
"value",
"value",
@ -1036,7 +1036,7 @@
"forceFaultStatus": null,
"forceRunningStatus": null,
"tagProps": [
"System/MCM04/StatusNonPowered_NS/S011051",
"/System/D2C/D2C_Chute_4",
"value",
"value",
"value",
@ -13296,7 +13296,7 @@
"forceFaultStatus": null,
"forceRunningStatus": null,
"tagProps": [
"System/MCM04/StatusNonPowered_NS/S011057",
"/System/D2C/D2C_Chute_1",
"value",
"value",
"value",
@ -13938,7 +13938,7 @@
"forceFaultStatus": null,
"forceRunningStatus": null,
"tagProps": [
"System/MCM04/Estop/S011051_JR1",
"System/Station/JR/S011051_JR1",
"value",
"value",
"value",

View File

@ -133,6 +133,20 @@
"size": 400,
"viewParams": {},
"viewPath": "PopUp-Views/Controller-Equipment/Information-Docked-East-VFD"
},
{
"anchor": "fixed",
"autoBreakpoint": 480,
"content": "cover",
"handle": "hide",
"iconUrl": "",
"id": "Docked-East-SNP",
"modal": false,
"resizable": false,
"show": "onDemand",
"size": 400,
"viewParams": {},
"viewPath": "PopUp-Views/Controller-Equipment/Information-Docked-East-StatusNonPowered"
}
],
"top": [

View File

@ -571,7 +571,7 @@
"component": {
"onActionPerformed": {
"config": {
"script": "\ttag_name \u003d self.view.params.tagProps[0]\n\ttag_path \u003d \"[\" + self.session.custom.fc+ \"_SCADA_TAG_PROVIDER]\"+tag_name+\"/Maintenance/Start_PB\"\n\tsystem.tag.writeBlocking([tag_path],[True])"
"script": "\ttag_name \u003d self.view.params.tagProps[0]\n\ttag_path \u003d \"[\" + self.session.custom.fc+ \"_SCADA_TAG_PROVIDER]\"+tag_name+\"/Start_PB\"\n\tsystem.tag.writeBlocking([tag_path],[True])"
},
"scope": "G",
"type": "script"

View File

@ -1,14 +1,6 @@
{
"custom": {
"PLC_list": [
"MCM01",
"MCM02",
"MCM03",
"MCM04",
"MCM05",
"MCM06",
"MCM07"
],
"PLC_list": null,
"running_state": -1,
"state": 0,
"views_data": []
@ -179,7 +171,7 @@
"dom": {
"onClick": {
"config": {
"script": "\tsystem.perspective.closeDock(\u0027Docked-East-JR\u0027)\n\tself.getSibling(\"tabs\").props.currentTabIndex \u003d 0"
"script": "\tsystem.perspective.closeDock(\u0027Docked-East-SNP\u0027)\n\tself.getSibling(\"tabs\").props.currentTabIndex \u003d 0"
},
"scope": "G",
"type": "script"
@ -330,7 +322,7 @@
"children": [
{
"meta": {
"name": "NameField"
"name": "Name"
},
"position": {
"basis": "50%",
@ -379,7 +371,7 @@
}
],
"meta": {
"name": "Name"
"name": "Property"
},
"position": {
"basis": "35px"
@ -410,7 +402,7 @@
"children": [
{
"meta": {
"name": "Disabled"
"name": "Name"
},
"position": {
"basis": "50%",
@ -426,7 +418,7 @@
},
{
"meta": {
"name": "PB_Light"
"name": "Disabled"
},
"position": {
"basis": "50%",
@ -528,7 +520,7 @@
}
],
"meta": {
"name": "Name"
"name": "Property"
},
"position": {
"basis": "35px",
@ -559,7 +551,7 @@
"children": [
{
"meta": {
"name": "Full"
"name": "Name"
},
"position": {
"basis": "50%",
@ -575,7 +567,7 @@
},
{
"meta": {
"name": "PB_Light"
"name": "Full"
},
"position": {
"basis": "50%",
@ -677,7 +669,7 @@
}
],
"meta": {
"name": "Name"
"name": "Property"
},
"position": {
"basis": "35px",
@ -708,7 +700,7 @@
"children": [
{
"meta": {
"name": "Half Full"
"name": "Name"
},
"position": {
"basis": "50%",
@ -724,7 +716,7 @@
},
{
"meta": {
"name": "PB_Light"
"name": "Half Full"
},
"position": {
"basis": "50%",
@ -826,7 +818,7 @@
}
],
"meta": {
"name": "Name"
"name": "Property"
},
"position": {
"basis": "35px",
@ -857,7 +849,7 @@
"children": [
{
"meta": {
"name": "Jam"
"name": "Name"
},
"position": {
"basis": "50%",
@ -873,7 +865,7 @@
},
{
"meta": {
"name": "PB_Light"
"name": "Jam"
},
"position": {
"basis": "50%",
@ -975,7 +967,7 @@
}
],
"meta": {
"name": "Name"
"name": "Property"
},
"position": {
"basis": "35px",
@ -999,6 +991,372 @@
"direction": "column"
},
"type": "ia.container.flex"
},
{
"children": [
{
"children": [
{
"meta": {
"name": "Name"
},
"position": {
"basis": "50%",
"grow": 1
},
"props": {
"style": {
"paddingLeft": 20
},
"text": "NO CONTAINER"
},
"type": "ia.display.label"
},
{
"meta": {
"name": "No Container"
},
"position": {
"basis": "50%",
"grow": 1
},
"propConfig": {
"props.style.backgroundColor": {
"binding": {
"config": {
"path": "this.props.text"
},
"transforms": [
{
"fallback": "#000000",
"inputType": "scalar",
"mappings": [
{
"input": "NO CONTAINER",
"output": "#FFFFFF"
},
{
"input": "CONTAINER PRESENT",
"output": "#D5D5D5"
}
],
"outputType": "color",
"type": "map"
}
],
"type": "property"
}
},
"props.text": {
"binding": {
"config": {
"fallbackDelay": 2.5,
"mode": "indirect",
"references": {
"0": "{view.params.tagProps[0]}",
"fc": "{session.custom.fc}"
},
"tagPath": "[{fc}_SCADA_TAG_PROVIDER]{0}/Alarm/No Container"
},
"transforms": [
{
"expression": "coalesce({value},{view.params.forceFaultStatus},0)",
"type": "expression"
},
{
"fallback": "CONTAINER PRESENT",
"inputType": "scalar",
"mappings": [
{
"input": 1,
"output": "NO CONTAINER"
}
],
"outputType": "scalar",
"type": "map"
}
],
"type": "tag"
}
},
"props.textStyle.color": {
"binding": {
"config": {
"path": "this.props.text"
},
"transforms": [
{
"fallback": "#000000",
"inputType": "scalar",
"mappings": [
{
"input": "NO CONTAINER",
"output": "#FF4487"
},
{
"input": "CONTAINER PRESENT",
"output": "#47FF47"
}
],
"outputType": "color",
"type": "map"
}
],
"type": "property"
}
}
},
"props": {
"style": {
"classes": "Text-Styles/Ariel-Bold-12pt",
"paddingLeft": 10
}
},
"type": "ia.display.label"
}
],
"meta": {
"name": "Property"
},
"position": {
"basis": "35px",
"shrink": 2
},
"props": {
"style": {
"classes": "PopUp-Styles/InfoLabel"
}
},
"type": "ia.container.flex"
}
],
"meta": {
"name": "No Container"
},
"position": {
"basis": "35px"
},
"propConfig": {
"meta.visible": {
"binding": {
"config": {
"fallbackDelay": 2.5,
"mode": "indirect",
"references": {
"0": "{view.params.tagProps[0]}",
"fc": "{session.custom.fc}"
},
"tagPath": "[{fc}_SCADA_TAG_PROVIDER]{0}/Chute_Type"
},
"transforms": [
{
"expression": "coalesce({value},{view.params.forceFaultStatus},0)",
"type": "expression"
},
{
"fallback": false,
"inputType": "scalar",
"mappings": [
{
"input": 1,
"output": true
}
],
"outputType": "scalar",
"type": "map"
}
],
"type": "tag"
}
}
},
"props": {
"direction": "column"
},
"type": "ia.container.flex"
},
{
"children": [
{
"children": [
{
"meta": {
"name": "Name"
},
"position": {
"basis": "50%",
"grow": 1
},
"props": {
"style": {
"paddingLeft": 20
},
"text": "READY TO BE ENABLED"
},
"type": "ia.display.label"
},
{
"meta": {
"name": "Ready To Be Enabled"
},
"position": {
"basis": "50%",
"grow": 1
},
"propConfig": {
"props.style.backgroundColor": {
"binding": {
"config": {
"path": "this.props.text"
},
"transforms": [
{
"fallback": "#000000",
"inputType": "scalar",
"mappings": [
{
"input": "READY",
"output": "#FFFFFF"
},
{
"input": "ENABLED",
"output": "#D5D5D5"
}
],
"outputType": "color",
"type": "map"
}
],
"type": "property"
}
},
"props.text": {
"binding": {
"config": {
"fallbackDelay": 2.5,
"mode": "indirect",
"references": {
"0": "{view.params.tagProps[0]}",
"fc": "{session.custom.fc}"
},
"tagPath": "[{fc}_SCADA_TAG_PROVIDER]{0}/STATE"
},
"transforms": [
{
"expression": "coalesce({value},{view.params.forceFaultStatus},0)",
"type": "expression"
},
{
"fallback": "ENABLED",
"inputType": "scalar",
"mappings": [
{
"input": 6,
"output": "READY"
}
],
"outputType": "scalar",
"type": "map"
}
],
"type": "tag"
}
},
"props.textStyle.color": {
"binding": {
"config": {
"path": "this.props.text"
},
"transforms": [
{
"fallback": "#000000",
"inputType": "scalar",
"mappings": [
{
"input": "READY",
"output": "#92FF00"
},
{
"input": "ENABLED",
"output": "#47FF47"
}
],
"outputType": "color",
"type": "map"
}
],
"type": "property"
}
}
},
"props": {
"style": {
"classes": "Text-Styles/Ariel-Bold-12pt",
"paddingLeft": 10
}
},
"type": "ia.display.label"
}
],
"meta": {
"name": "Property"
},
"position": {
"basis": "35px",
"shrink": 2
},
"props": {
"style": {
"classes": "PopUp-Styles/InfoLabel"
}
},
"type": "ia.container.flex"
}
],
"meta": {
"name": "Ready To Be Enabled"
},
"position": {
"basis": "35px"
},
"propConfig": {
"meta.visible": {
"binding": {
"config": {
"fallbackDelay": 2.5,
"mode": "indirect",
"references": {
"0": "{view.params.tagProps[0]}",
"fc": "{session.custom.fc}"
},
"tagPath": "[{fc}_SCADA_TAG_PROVIDER]{0}/Chute_Type"
},
"transforms": [
{
"expression": "coalesce({value},{view.params.forceFaultStatus},0)",
"type": "expression"
},
{
"fallback": false,
"inputType": "scalar",
"mappings": [
{
"input": 1,
"output": true
}
],
"outputType": "scalar",
"type": "map"
}
],
"type": "tag"
}
}
},
"props": {
"direction": "column"
},
"type": "ia.container.flex"
}
],
"meta": {
@ -1026,7 +1384,7 @@
"component": {
"onActionPerformed": {
"config": {
"script": "\ttag_name \u003d self.view.params.tagProps[0]\n\ttag_path \u003d \"[\" + self.session.custom.fc+ \"_SCADA_TAG_PROVIDER]\"+tag_name+\"/Enable_Chute_Pressed\"\n\tsystem.tag.writeBlocking([tag_path],[True])"
"script": "\ttag_name \u003d self.view.params.tagProps[0]\n\ttag_path \u003d \"[\" + self.session.custom.fc+ \"_SCADA_TAG_PROVIDER]\"+tag_name+\"/Enable_Chute_Pressed\"\n\tsystem.tag.writeBlocking([tag_path],[True])\n\ttag_path2 \u003d \"[\" + self.session.custom.fc+ \"_SCADA_TAG_PROVIDER]\"+tag_name+\"/GS_PB_Pressed\"\n\tsystem.tag.writeBlocking([tag_path2],[True])\t"
},
"scope": "G",
"type": "script"

View File

@ -2,19 +2,20 @@
"custom": {
"alarm_message": null,
"disconnected": true,
"plc": "value",
"plc": "System",
"priority": 0,
"priority_string": "Medium",
"searchId": "PLC01",
"state": 0,
"state_string": "Disabled"
"state_string": "Disabled",
"type": 0
},
"params": {
"directionLeft": false,
"forceFaultStatus": null,
"forceRunningStatus": null,
"tagProps": [
"value",
"System/D2C/D2C_Chute_1",
"value",
"value",
"value",
@ -66,78 +67,22 @@
"custom.priority": {
"binding": {
"config": {
"path": "view.custom.state"
"expression": "if(\r\n {view.custom.type} \u003d 0,\r\n if(\r\n {view.custom.state} \u003d 0 || {view.custom.state} \u003d 1 || {view.custom.state} \u003d 2 || {view.custom.state} \u003d 3 || {view.custom.state} \u003d 4,\r\n {view.custom.state},\r\n 0\r\n ),\r\n if(\r\n {view.custom.state} \u003d 0 || {view.custom.state} \u003d 1 || {view.custom.state} \u003d 2 || {view.custom.state} \u003d 3 || {view.custom.state} \u003d 4 || {view.custom.state} \u003d 5 || {view.custom.state} \u003d 6,\r\n {view.custom.state},\r\n 0\r\n )\r\n)\r\n"
},
"transforms": [
{
"fallback": 0,
"inputType": "scalar",
"mappings": [
{
"input": 1,
"output": 1
},
{
"input": 2,
"output": 2
},
{
"input": 3,
"output": 3
},
{
"input": 4,
"output": 4
},
{
"input": 0,
"output": 0
}
],
"outputType": "scalar",
"type": "map"
}
],
"type": "property"
"type": "expr"
},
"persistent": true
},
"custom.priority_string": {
"binding": {
"config": {
"path": "view.custom.state"
"expression": "if({view.custom.type} \u003d 1,\r\n case({view.custom.state},\r\n 0, \u0027Medium\u0027,\r\n 1, \u0027No Active Alarms\u0027,\r\n 2, \u0027High\u0027,\r\n 3, \u0027High\u0027,\r\n 4, \u0027High\u0027,\r\n 5, \u0027Low\u0027,\r\n 6, \u0027Low\u0027,\r\n \u0027Unknown\u0027\r\n ),\r\n if({view.custom.type} \u003d 0,\r\n case({view.custom.state},\r\n 0, \u0027Medium\u0027,\r\n 1, \u0027No Active Alarms\u0027,\r\n 2, \u0027High\u0027,\r\n 3, \u0027High\u0027,\r\n 4, \u0027High\u0027,\r\n \u0027Unknown\u0027\r\n ),\r\n \u0027Unknown\u0027\r\n )\r\n)"
},
"transforms": [
{
"fallback": "Unknown",
"inputType": "scalar",
"mappings": [
{
"input": 0,
"output": "Medium"
},
{
"input": 1,
"output": "No Active Alarms"
},
{
"input": 2,
"output": "High"
},
{
"input": 3,
"output": "High"
},
{
"input": 4,
"output": "High"
}
],
"outputType": "scalar",
"type": "map"
}
],
"type": "property"
"type": "expr"
},
"onChange": {
"enabled": null,
"script": "\tif self.custom.priority not in [1, 2, 3, 4, 5, 6, 0]:\n\t self.custom.priority_string \u003d \"Unknown\""
},
"persistent": true
},
@ -174,12 +119,33 @@
"custom.state_string": {
"binding": {
"config": {
"expression": "case({view.custom.state},\r\n0, \"Disabled\",\r\n1, \"Enabled\",\r\n2, \"Half Full\",\r\n3, \"Full\",\r\n4, \"Jammed\",\r\n\"Unknown\")"
"expression": "if({view.custom.type} \u003d 1,\r\n case({view.custom.state},\r\n 0, \u0027Disabled\u0027,\r\n 1, \u0027Enabled\u0027,\r\n 2, \u0027Half Full\u0027,\r\n 3, \u0027Full\u0027,\r\n 4, \u0027Jammed\u0027,\r\n 5, \u0027No Container\u0027,\r\n 6, \u0027Ready To Be Enabled\u0027,\r\n \u0027Unknown\u0027\r\n ),\r\n if({view.custom.type} \u003d 0,\r\n case({view.custom.state},\r\n 0, \u0027Disabled\u0027,\r\n 1, \u0027Enabled\u0027,\r\n 2, \u0027Half Full\u0027,\r\n 3, \u0027Full\u0027,\r\n 4, \u0027Jammed\u0027,\r\n \u0027Unknown\u0027\r\n ),\r\n \u0027Unknown\u0027\r\n )\r\n)"
},
"type": "expr"
},
"persistent": true
},
"custom.type": {
"binding": {
"config": {
"fallbackDelay": 2.5,
"mode": "indirect",
"references": {
"0": "{view.params.tagProps[0]}",
"fc": "{session.custom.fc}"
},
"tagPath": "[{fc}_SCADA_TAG_PROVIDER]{0}/Chute_Type"
},
"transforms": [
{
"expression": "coalesce({value},{view.params.forceFaultStatus},0)",
"type": "expression"
}
],
"type": "tag"
},
"persistent": true
},
"params.directionLeft": {
"paramDirection": "input",
"persistent": true
@ -230,39 +196,9 @@
"props.elements[0].fill.paint": {
"binding": {
"config": {
"path": "view.custom.state"
"expression": "if({view.custom.type} \u003d 1,\r\n case({view.custom.state},\r\n 0, \u0027#FFFFFF\u0027,\r\n 1, \u0027#C9FCC0\u0027,\r\n 2, \u0027#7F83FF\u0027,\r\n 3, \u0027#0008FF\u0027,\r\n 4, \u0027#FF8C00\u0027,\r\n 5, \u0027#FF4487\u0027,\r\n 6, \u0027#92FF00\u0027,\r\n \u0027#FFFFFF\u0027\r\n ),\r\n if({view.custom.type} \u003d 0,\r\n case({view.custom.state},\r\n 0, \u0027#FFFFFF\u0027,\r\n 1, \u0027#C9FCC0\u0027,\r\n 2, \u0027#7F83FF\u0027,\r\n 3, \u0027#0008FF\u0027,\r\n 4, \u0027#FF8C00\u0027,\r\n \u0027#FFFFFF\u0027\r\n ),\r\n \u0027#FFFFFF\u0027\r\n )\r\n)"
},
"transforms": [
{
"fallback": "#FFFFFF",
"inputType": "scalar",
"mappings": [
{
"input": 0,
"output": "#FFFFFF"
},
{
"input": 1,
"output": "#C9FCC0"
},
{
"input": 2,
"output": "#7F83FF"
},
{
"input": 3,
"output": "#0008FF"
},
{
"input": 4,
"output": "#FF8C00"
}
],
"outputType": "color",
"type": "map"
}
],
"type": "property"
"type": "expr"
}
}
},
@ -296,14 +232,6 @@
"scope": "G",
"type": "script"
},
"onDoubleClick": {
"config": {
"script": "\ttagProps \u003d self.view.params.tagProps\n\tsystem.perspective.openPopup(\"StatusPopUP\", \"PopUp-Views/Controller-Equipment/Information\", params \u003d{\"tagProps\":tagProps})\n\t"
},
"enabled": false,
"scope": "G",
"type": "script"
},
"onMouseEnter": {
"config": {
"script": "\tfrom time import sleep\n\t\n\talarm \u003d []\n\tmessage \u003d None\n\t\n\tsleep(0.5)\n\t\n\tif system.tag.exists(\"System/aws_data\"):\n\t\tif self.view.params.tagProps[0] !\u003d \"\":\n\t\t\ttags_to_read \u003d system.tag.readBlocking(\"System/aws_data\")\n\t\t\tdecode_alarm_data \u003d system.util.jsonDecode(tags_to_read[0].value)\n\t\t\talarm \u003d [decode_alarm_data[i] for i in decode_alarm_data\n\t\t\t\t\tif decode_alarm_data[i][\u0027sourceId\u0027].startswith(self.view.params.tagProps[0])]\n\t\tif alarm:\n\t\t\talarm \u003d sorted(alarm, key \u003d lambda t:t[\u0027timestamp\u0027], reverse\u003dTrue)\n\t\t\tmessage \u003d max(alarm, key \u003d lambda p:p[\u0027priority\u0027]).get(\u0027message\u0027)\n\t\t\tif len(alarm) \u003e 1:\n\t\t\t\tmessage +\u003d \" (+\" + str(len(alarm)-1) + \")\"\n\tself.view.custom.alarm_message \u003d message"
@ -351,6 +279,14 @@
{
"input": 0,
"output": "Alarms-Styles/Medium"
},
{
"input": 5,
"output": "Alarms-Styles/Low"
},
{
"input": 6,
"output": "Alarms-Styles/Low"
}
],
"outputType": "style-list",

1685
tags/Simulation/D2C.json Normal file

File diff suppressed because it is too large Load Diff

1689
tags/Simulation/tags.json Normal file

File diff suppressed because it is too large Load Diff