Improve node status on Tina Work node in presence flow

This commit is contained in:
2025-03-23 13:44:51 -04:00
parent 8a1e0558e8
commit 9d5252c7e4

View File

@ -5,6 +5,9 @@ const tinawork = msg.tinawork
if (tinawork === 'on' && workEndZone === 'on') {
node.status({fill:"green",shape:"dot",text:"Activated"})
return[msg,null]
} else if (tinawork === 'on' && workEndZone === 'off') {
node.status({fill:"yellow",shape:"dot",text:"Not time to leave yet"})
return null
} else if (tinawork === 'off') {
node.status({fill:"yellow",shape:"dot",text:"No Work Today"})
return null