Fix MCM color
This commit is contained in:
parent
061ea0e091
commit
ba62855d1f
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"custom": {
|
"custom": {
|
||||||
"disconnected": false,
|
"disconnected": true,
|
||||||
"plc": "MCM",
|
"plc": "MCM",
|
||||||
"priority": 0,
|
"priority": 0,
|
||||||
"priority_string": "No Active Alarms",
|
"priority_string": "No Active Alarms",
|
||||||
@ -202,7 +202,7 @@
|
|||||||
"props.elements[0].fill.paint": {
|
"props.elements[0].fill.paint": {
|
||||||
"binding": {
|
"binding": {
|
||||||
"config": {
|
"config": {
|
||||||
"expression": "if(\r\n {view.custom.disconnected},\r\n \"#FFFFFF\",\r\n switch(\r\n toInt({view.custom.state}),\r\n 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, \r\n \"#B3B3B3\", \"#FF0000\", \"#FF0000\", \"#FF0000\", \"#FF8C00\",\r\n \"#FF8C00\", \"#FF0000\", \"#FF0000\", \"#FF0000\", \"#00FF00\",\r\n \"#FFFF00\"\r\n )\r\n)\r\n"
|
"expression": "if(\r\n {view.custom.disconnected},\r\n \"#000000\",\r\n switch(\r\n toInt({view.custom.state}),\r\n 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, \r\n \"#B3B3B3\", \"#FF0000\", \"#FF0000\", \"#FF0000\", \"#FF8C00\",\r\n \"#FF8C00\", \"#FF0000\", \"#FF0000\", \"#FF0000\", \"#00FF00\",\r\n \"#FFFF00\"\r\n )\r\n)\r\n"
|
||||||
},
|
},
|
||||||
"type": "expr"
|
"type": "expr"
|
||||||
},
|
},
|
||||||
@ -210,6 +210,28 @@
|
|||||||
"enabled": false,
|
"enabled": false,
|
||||||
"script": ""
|
"script": ""
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"props.elements[1].style.fill": {
|
||||||
|
"binding": {
|
||||||
|
"config": {
|
||||||
|
"path": "view.custom.disconnected"
|
||||||
|
},
|
||||||
|
"transforms": [
|
||||||
|
{
|
||||||
|
"fallback": "#000000",
|
||||||
|
"inputType": "scalar",
|
||||||
|
"mappings": [
|
||||||
|
{
|
||||||
|
"input": true,
|
||||||
|
"output": "#FFFFFF"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"outputType": "color",
|
||||||
|
"type": "map"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"type": "property"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"props": {
|
"props": {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user