From cd02f1b58164156b26399d5aa3701a2ca446c956 Mon Sep 17 00:00:00 2001 From: Tony Stork Date: Wed, 4 Oct 2023 18:55:44 -0400 Subject: [PATCH] Fix halloween mode not being reset, close #14 --- flows.json | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/flows.json b/flows.json index 821df9f..017927f 100644 --- a/flows.json +++ b/flows.json @@ -1198,7 +1198,9 @@ "f5fb96bf1a33b3cd" ], "x": 54, - "y": 19 + "y": 19, + "w": 1492, + "h": 282 }, { "id": "0c81dfaed25d225c", @@ -14348,7 +14350,7 @@ "z": "b5717a86ce55bc29", "g": "eeafd13be593ae69", "name": "Shut Off", - "func": "const states = global.get('homeassistant.homeAssistant.states')\nconst frontPorchToggle = states['input_boolean.front_porch_light_on'].state\nconst deliveryMode = states['input_boolean.delivery_mode'].state\nconst holidaymode = states['input_boolean.holiday_mode'].state\nconst currentholiday = states['input_select.holiday_animation'].state\nconst holiday = currentholiday.toLowerCase()\n\nif (frontPorchToggle === 'on' && deliveryMode === 'off') {\n if (holidaymode === 'on') {\n node.status({fill:\"blue\",shape:\"dot\",text:\"Holiday On\"})\n node.send([msg,null])\n } else {\n node.status({fill:\"green\",shape:\"dot\",text:\"Holiday Off\"})\n node.send([null,msg])\n }\n} else if (frontPorchToggle === 'off') {\n node.status({fill:\"red\",shape:\"ring\",text:\"Blocked (Automation Off\"})\n} else if (deliveryMode === 'on') {\n node.status({fill:\"red\",shape:\"ring\",text:\"Blocked (Delivery Mode)\"})\n}", + "func": "const states = global.get('homeassistant.homeAssistant.states')\nconst frontPorchToggle = states['input_boolean.front_porch_light_on'].state\nconst deliveryMode = states['input_boolean.delivery_mode'].state\nconst holidaymode = states['input_boolean.holiday_mode'].state\nconst currentholiday = states['input_select.holiday_animation'].state\nconst holiday = currentholiday.toLowerCase()\n\nif (frontPorchToggle === 'on' && deliveryMode === 'off') {\n if (holidaymode === 'on') {\n msg.holiday = holiday\n node.status({fill:\"blue\",shape:\"dot\",text:\"Holiday On\"})\n node.send([msg,null])\n } else {\n node.status({fill:\"green\",shape:\"dot\",text:\"Holiday Off\"})\n node.send([null,msg])\n }\n} else if (frontPorchToggle === 'off') {\n node.status({fill:\"red\",shape:\"ring\",text:\"Blocked (Automation Off\"})\n} else if (deliveryMode === 'on') {\n node.status({fill:\"red\",shape:\"ring\",text:\"Blocked (Delivery Mode)\"})\n}", "outputs": 2, "timeout": "", "noerr": 0,