Har et eksempel i samme kategori.
{
"Id": "fpR5mfMEmEvmAOn",
"ClassId": "fpR5mfMEmEvmAOn",
"Author": "",
"Version": 0,
"CreatedAt": "2021-06-27T20:40:39.096487151+02:00",
"UpdatedAt": "2021-06-30T23:48:31.656129247+02:00",
"Name": "Lekkasjealarm",
"Group": "Varsler",
"Description": "Kutter strøm til vaskemaskin og oppvaskmaskin ved lekkasje",
"Nodes": [
{
"Id": "1",
"Type": "trigger",
"Label": "Lekkasjesensor",
"SuccessTransition": "2",
"TimeoutTransition": "",
"ErrorTransition": "",
"Address": "pt:j1/mt:evt/rt:dev/rn:zw/ad:1/sv:alarm_water/ad:28_0",
"Service": "alarm_water",
"ServiceInterface": "evt.alarm.report",
"Config": {
"ConnectorID": "",
"InputVariableType": "",
"IsValueFilterEnabled": false,
"LookupServiceNameAndLocation": false,
"PropFilterName": "",
"PropFilterValue": "",
"RegisterAsVirtualService": false,
"Timeout": 0,
"ValueFilter": {
"Value": null,
"ValueType": ""
},
"ValueJPath": "",
"ValueJPathResultType": "",
"VirtualServiceGroup": "",
"VirtualServiceProps": null
},
"Ui": {
"nodeType": "",
"x": 309,
"y": 116
},
"TypeAlias": "Trigger"
},
{
"Id": "2",
"Type": "transform",
"Label": "",
"SuccessTransition": "3",
"TimeoutTransition": "",
"ErrorTransition": "",
"Address": "",
"Service": "",
"ServiceInterface": "",
"Config": {
"Expression": "",
"IsRVariableGlobal": false,
"IsTargetVariableGlobal": false,
"IsTargetVariableInMemory": true,
"LVariableName": "",
"RValue": {
"Value": 0,
"ValueType": "str_map"
},
"RVariableName": "",
"Rtype": "var",
"TargetVariableName": "",
"TargetVariableType": "",
"Template": "",
"TransformType": "jpath",
"ValueMapping": [],
"XPathMapping": [
{
"IsTargetVariableGlobal": true,
"IsTargetVariableInMemory": false,
"Path": "$.val.status",
"TargetVariableName": "kitchen_leak",
"TargetVariableType": "string",
"UpdateInputVariable": false
}
]
},
"Ui": {
"nodeType": "",
"x": 306,
"y": 322
},
"TypeAlias": "Transform"
},
{
"Id": "3",
"Type": "if",
"Label": "alarm aktiv",
"SuccessTransition": "",
"TimeoutTransition": "",
"ErrorTransition": "",
"Address": "",
"Service": "",
"ServiceInterface": "",
"Config": {
"Expression": [
{
"BooleanOperator": "",
"LeftVariableIsGlobal": true,
"LeftVariableName": "kitchen_leak",
"Operand": "eq",
"RightVariable": {
"Value": "activ",
"ValueType": "string"
}
}
],
"FalseTransition": "6",
"TrueTransition": "4"
},
"Ui": {
"nodeType": "",
"x": 297,
"y": 489
},
"TypeAlias": "If condition"
},
{
"Id": "4",
"Type": "action",
"Label": "Slå av varskemaskin",
"SuccessTransition": "5",
"TimeoutTransition": "",
"ErrorTransition": "",
"Address": "pt:j1/mt:cmd/rt:dev/rn:zw/ad:1/sv:out_bin_switch/ad:106_0",
"Service": "out_bin_switch",
"ServiceInterface": "cmd.binary.set",
"Config": {
"DefaultValue": {
"Value": false,
"ValueType": "bool"
},
"IsVariableGlobal": false,
"Props": {},
"RegisterAsVirtualService": false,
"ResponseToTopic": "",
"VariableName": "",
"VirtualServiceGroup": "",
"VirtualServiceProps": {}
},
"Ui": {
"nodeType": "",
"x": 144,
"y": 659
},
"TypeAlias": "Action"
},
{
"Id": "5",
"Type": "action",
"Label": "Slå av oppvaskmaskin",
"SuccessTransition": "10",
"TimeoutTransition": "",
"ErrorTransition": "",
"Address": "pt:j1/mt:cmd/rt:dev/rn:zw/ad:1/sv:out_bin_switch/ad:105_0",
"Service": "out_bin_switch",
"ServiceInterface": "cmd.binary.set",
"Config": {
"DefaultValue": {
"Value": false,
"ValueType": "bool"
},
"IsVariableGlobal": false,
"Props": {},
"RegisterAsVirtualService": false,
"ResponseToTopic": "",
"VariableName": "",
"VirtualServiceGroup": "",
"VirtualServiceProps": {}
},
"Ui": {
"nodeType": "",
"x": 132,
"y": 815
},
"TypeAlias": "Action"
},
{
"Id": "6",
"Type": "if",
"Label": "alarm deaktiv",
"SuccessTransition": "",
"TimeoutTransition": "",
"ErrorTransition": "",
"Address": "",
"Service": "",
"ServiceInterface": "",
"Config": {
"Expression": [
{
"BooleanOperator": "",
"LeftVariableIsGlobal": true,
"LeftVariableName": "kitchen_leak",
"Operand": "eq",
"RightVariable": {
"Value": "deactiv",
"ValueType": "string"
}
}
],
"FalseTransition": "",
"TrueTransition": "7"
},
"Ui": {
"nodeType": "",
"x": 482,
"y": 670
},
"TypeAlias": "If condition"
},
{
"Id": "7",
"Type": "action",
"Label": "Slå på varskemaskin",
"SuccessTransition": "8",
"TimeoutTransition": "",
"ErrorTransition": "",
"Address": "pt:j1/mt:cmd/rt:dev/rn:zw/ad:1/sv:out_bin_switch/ad:106_0",
"Service": "out_bin_switch",
"ServiceInterface": "cmd.binary.set",
"Config": {
"DefaultValue": {
"Value": true,
"ValueType": "bool"
},
"IsVariableGlobal": false,
"Props": {},
"RegisterAsVirtualService": false,
"ResponseToTopic": "",
"VariableName": "",
"VirtualServiceGroup": "",
"VirtualServiceProps": {}
},
"Ui": {
"nodeType": "",
"x": 488,
"y": 835
},
"TypeAlias": "Action"
},
{
"Id": "8",
"Type": "action",
"Label": "Slå på oppvaskmaskin",
"SuccessTransition": "",
"TimeoutTransition": "",
"ErrorTransition": "",
"Address": "pt:j1/mt:cmd/rt:dev/rn:zw/ad:1/sv:out_bin_switch/ad:105_0",
"Service": "out_bin_switch",
"ServiceInterface": "cmd.binary.set",
"Config": {
"DefaultValue": {
"Value": true,
"ValueType": "bool"
},
"IsVariableGlobal": false,
"Props": {},
"RegisterAsVirtualService": false,
"ResponseToTopic": "",
"VariableName": "",
"VirtualServiceGroup": "",
"VirtualServiceProps": {}
},
"Ui": {
"nodeType": "",
"x": 481,
"y": 1017
},
"TypeAlias": "Action"
},
{
"Id": "10",
"Type": "action",
"Label": "NodeRED notification",
"SuccessTransition": "",
"TimeoutTransition": "",
"ErrorTransition": "",
"Address": "Address: pt:j1/mt:cmd/rt:dev/rn:flow/ad:1/sv:pz_tts/ad:fpR5mfMEmEvmAOn_0",
"Service": "pz_tts",
"ServiceInterface": "cmd.binary.set",
"Config": {
"DefaultValue": {
"Value": true,
"ValueType": "bool"
},
"IsVariableGlobal": false,
"Props": {},
"RegisterAsVirtualService": true,
"ResponseToTopic": "",
"VariableName": "",
"VirtualServiceGroup": "ch_0",
"VirtualServiceProps": {}
},
"Ui": {
"nodeType": "",
"x": 128,
"y": 987
},
"TypeAlias": "Action"
}
],
"Settings": null,
"IsDisabled": false,
"IsDefault": false,
"ParallelExecution": "parallel"
}