sorry for highjacking that thread, but I think it fits...
In the following flow, the everything on button only works once, after the "preset" state changed. I need the join node to work overtime since the input "preset" wont change everytime.
[{"id":"f5bb4a2d.bf9378","type":"function","z":"bd967441.f24678","name":"","func":"if (msg.active === true && msg.everyON === true) {\nmsg.payload = true;\n return [msg];\n} else {\n return [null];\n}","outputs":1,"noerr":0,"x":970,"y":180,"wires":[["9492465c.2145"]]},{"id":"3a48fc9.35c8584","type":"mqtt in","z":"bd967441.f24678","name":"","topic":"Test","qos":"2","broker":"aa21acb8.2e7348","x":330,"y":120,"wires":[["72762b6e.0e8364"]]},{"id":"36a9ab32.03bee4","type":"mqtt out","z":"bd967441.f24678","name":"","topic":"Test","qos":"2","retain":"","broker":"aa21acb8.2e7348","x":790,"y":120,"wires":[]},{"id":"ce858d97.bcc4c8","type":"join","z":"bd967441.f24678","name":"","mode":"custom","build":"array","property":"","propertyType":"full","key":"topic","joiner":"\\n","joinerType":"str","accumulate":false,"timeout":"","count":"","reduceRight":false,"reduceExp":"","reduceInit":"","reduceInitType":"","reduceFixup":"","x":810,"y":180,"wires":[["f5bb4a2d.bf9378"]]},{"id":"d512897d.c5a0c","type":"ui_template","z":"bd967441.f24678","group":"7581546f.42c224","name":"Preset","order":2,"width":"5","height":"2","format":"<md-button\n class=\"vibrate filled bigfont\"\n ng-style=\"{background: !msg.payload ? 'grey' : 'green' }\"\n ng-click=\"msg.topic = 'preset';msg.active = !msg.payload;msg.payload = !msg.payload;send(msg)\"\n > \n Preset<br/>\n </md-button>","storeOutMessages":false,"fwdInMessages":false,"templateScope":"local","x":590,"y":120,"wires":[["36a9ab32.03bee4","ce858d97.bcc4c8"]]},{"id":"72762b6e.0e8364","type":"json","z":"bd967441.f24678","name":"","pretty":false,"x":470,"y":120,"wires":[["d512897d.c5a0c"]]},{"id":"9dbf4373.38f538","type":"ui_toast","z":"bd967441.f24678","position":"dialog","displayTime":"3","highlight":"","outputs":1,"ok":"Yes","cancel":"No","topic":"","name":"","x":310,"y":180,"wires":[["99f13b9c.0700c"]],"icon":"node-red/light.png"},{"id":"a08f1ec1.23b7c","type":"ui_template","z":"bd967441.f24678","group":"7581546f.42c224","name":"Everything ON","order":1,"width":"6","height":"3","format":"<md-button\n class=\"vibrate filled bigfont\"\n ng-style=\"{background: 'grey'}\"\n ng-click=\"msg.topic = ''; msg.payload = 'Everything ON?';send(msg)\"\n>\n Everything ON\n</md-button>","storeOutMessages":false,"fwdInMessages":false,"templateScope":"local","x":140,"y":180,"wires":[["9dbf4373.38f538"]]},{"id":"99f13b9c.0700c","type":"function","z":"bd967441.f24678","name":"convert output based on actState","func":"if (msg.payload == \"Yes\") {\n msg.everyON = true,\n msg.topic = \"EverythingOn\",\n msg.complete = true\n return [msg]\n} else {\n return [null];\n}","outputs":1,"noerr":0,"x":540,"y":180,"wires":[["ce858d97.bcc4c8"]]},{"id":"9492465c.2145","type":"debug","z":"bd967441.f24678","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":1120,"y":180,"wires":[]},{"id":"aa21acb8.2e7348","type":"mqtt-broker","z":"","broker":"localhost","port":"1883","clientid":"","usetls":false,"compatmode":true,"keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthRetain":"false","birthPayload":"","willTopic":"","willQos":"0","willRetain":"false","willPayload":""},{"id":"7581546f.42c224","type":"ui_group","z":"","name":"Utilities","tab":"a577685a.d0bd48","order":3,"disp":true,"width":"6","collapse":false},{"id":"a577685a.d0bd48","type":"ui_tab","z":"","name":"Arbeitszimmer","icon":"dashboard","order":3}]
Thank you....