Looking for a GUI node for schedule but can't find what I need

I am contemplating modifying some stuff so I can have a GUI to edit a schedule.

But I can't find a node to do quite what I want.

The best one so far is: node-red-contrib-ui-time-scheduler but it just doesn't quite do all I need.

I need to add new events as needed and also control the payload to be sent.

Suggestions?

As it is I do all that at the edit level. Which isn't a deal breaker but it is (sometimes) annoying.

I'm using the node-red-contrib-ui-time-scheduler as well.

I don't think there is a way in NR that you can add new events in the UI but you most certainly can modify the payload.

I'm controlling all my light events with this UI... you can see that I'm using the EVENT mode and able to update the duration of all my pre-defined events in that UI.

Example:
Event=> Light.Bedroom
@17:43 (time is defined by SUNSET event) my light-ON duration for Bedroom is set to 10min
@19:05 (time is defined by NIGHT event) my light-ON duration for Bedroom duration is set to 20min

I control all my lights that way. It works great form me

1 Like

Could you post the code for that?

Have fun :wink: this is a sample on how I control the lights.

  • Lights can be switched on by Motion Sensor or by Light Switch
  • The lights will stay-on for the assigned duration
  • the duration will be reset if another motion occurs (so the light does not go off if somebody is still in room)
  • The duration is pending on the time of day (longer in the evening and only short time between midnight and morning)
[{"id":"ff74cc32.a408","type":"ui_time_scheduler","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","group":"c17b28c1.a4c7c8","name":"","startDay":"1","refresh":60,"devices":["Kitchen-Fan","Bedroom-Fan","Dog-Heater","Pool"],"onlySendChange":true,"customPayload":false,"eventMode":false,"eventOptions":[],"sendTopic":true,"lat":"-33.3470696","lon":"151.3754588","outputs":5,"order":1,"width":6,"height":4,"x":150,"y":1440,"wires":[["b937e92.1bc8518","6c12b9a4.fdbc58"],["f567f285.0c6a1"],["7431b1d5.76f0d"],["6b239d2c.43b954"],["a326f64d.77aa68"]]},{"id":"bc743ee8.29a16","type":"debug","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"p1","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":510,"y":1520,"wires":[]},{"id":"b937e92.1bc8518","type":"rbe","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","func":"rbe","gap":"","start":"","inout":"out","property":"payload","x":370,"y":1520,"wires":[["bc743ee8.29a16"]]},{"id":"f567f285.0c6a1","type":"rbe","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","func":"rbe","gap":"","start":"","inout":"out","property":"payload","x":370,"y":1600,"wires":[["b4131bdf.c34678","d43eea8.aae3f18"]]},{"id":"6b239d2c.43b954","type":"rbe","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","func":"rbe","gap":"","start":"","inout":"out","property":"payload","x":370,"y":1920,"wires":[["515e951b.449adc","e22331e2.8dfb7"]]},{"id":"7431b1d5.76f0d","type":"rbe","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","func":"rbe","gap":"","start":"","inout":"out","property":"payload","x":370,"y":1760,"wires":[["af60fd9.a5b36","3c5f4d0f.cb01b2"]]},{"id":"41ee30be.b6397","type":"switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","property":"payload","propertyType":"msg","rules":[{"t":"false"},{"t":"true"}],"checkall":"true","repair":false,"outputs":2,"x":850,"y":1760,"wires":[["1ec56c4e.66bce4"],["67a3a0f7.30462"]]},{"id":"6be4babd.0a5d94","type":"change","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"Socket.Study on","rules":[{"t":"set","p":"topic","pt":"msg","to":"zigbee2mqtt/Socket.StudyFan/set","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"ON","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":1800,"y":1980,"wires":[["13640a.3f68fbf7"]]},{"id":"b7f0bd3c.3c538","type":"change","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"Socket.Study off","rules":[{"t":"set","p":"topic","pt":"msg","to":"zigbee2mqtt/Socket.StudyFan/set","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"OFF","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":1800,"y":1900,"wires":[["13640a.3f68fbf7"]]},{"id":"515e951b.449adc","type":"ui_switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","label":"Dog-Heater","tooltip":"","group":"2f47a43f.6dfa4c","order":5,"width":2,"height":1,"passthru":true,"decouple":"false","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"","oncolor":"","offvalue":"false","offvalueType":"bool","officon":"","offcolor":"","x":550,"y":1940,"wires":[["e22331e2.8dfb7"]]},{"id":"af60fd9.a5b36","type":"ui_switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","label":"Bedroom Fan","tooltip":"","group":"2f47a43f.6dfa4c","order":7,"width":2,"height":1,"passthru":true,"decouple":"false","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"","oncolor":"","offvalue":"false","offvalueType":"bool","officon":"","offcolor":"","x":560,"y":1800,"wires":[["3c5f4d0f.cb01b2"]]},{"id":"b4131bdf.c34678","type":"ui_switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","label":"Kitchen Fan","tooltip":"","group":"2f47a43f.6dfa4c","order":3,"width":2,"height":1,"passthru":true,"decouple":"false","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"","oncolor":"","offvalue":"false","offvalueType":"bool","officon":"","offcolor":"","x":550,"y":1620,"wires":[["d43eea8.aae3f18"]]},{"id":"9b7d864b.961c98","type":"change","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"Socket.PoolPump ON","rules":[{"t":"set","p":"topic","pt":"msg","to":"zigbee2mqtt/Socket.PoolPump/set","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"ON","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":1820,"y":2160,"wires":[["717788ae.9c9018"]]},{"id":"1ed65a64.52ca66","type":"change","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"Socket.PoolPump OFF","rules":[{"t":"set","p":"topic","pt":"msg","to":"zigbee2mqtt/Socket.PoolPump/set","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"OFF","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":1820,"y":2080,"wires":[["717788ae.9c9018"]]},{"id":"a326f64d.77aa68","type":"rbe","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","func":"rbe","gap":"","start":"","inout":"out","property":"payload","x":370,"y":2100,"wires":[["15fc6b51.0336e5","3ae44a54.4cbaa6"]]},{"id":"15fc6b51.0336e5","type":"ui_switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","label":"Pool","tooltip":"","group":"2f47a43f.6dfa4c","order":1,"width":2,"height":1,"passthru":true,"decouple":"false","topic":"manual","topicType":"str","style":"","onvalue":"true","onvalueType":"bool","onicon":"","oncolor":"","offvalue":"false","offvalueType":"bool","officon":"","offcolor":"","animate":true,"x":530,"y":2120,"wires":[["3ae44a54.4cbaa6"]]},{"id":"165da741.f864b9","type":"link in","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","links":[],"x":75,"y":1520,"wires":[["b937e92.1bc8518"]]},{"id":"5424b0af.b6d62","type":"link in","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","links":[],"x":75,"y":1600,"wires":[["f567f285.0c6a1"]]},{"id":"f6328d68.a144c","type":"link in","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","links":["e262309a.599ae","1420c3fa.5e908c","b6aba14c.d4acd"],"x":75,"y":1760,"wires":[["7431b1d5.76f0d"]]},{"id":"4ad087d2.4305b8","type":"link in","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"Dog Heater","links":["8c229f09.9f522"],"x":75,"y":1920,"wires":[["6b239d2c.43b954"]]},{"id":"bbf0a20e.69fd","type":"link in","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"Pool","links":["e6d77b7c.11c038","17d28f.d908cd71","9d8902e.6eff7"],"x":75,"y":2100,"wires":[["a326f64d.77aa68"]]},{"id":"b42ecc8a.68f5","type":"change","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"Socket.Kitchen ON","rules":[{"t":"set","p":"topic","pt":"msg","to":"zigbee2mqtt/Socket.Kitchen/set","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"ON","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":1810,"y":1660,"wires":[["22ef243a.a092ec"]]},{"id":"3b64c66a.39f98a","type":"change","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"Socket.Kitchen OFF","rules":[{"t":"set","p":"topic","pt":"msg","to":"zigbee2mqtt/Socket.Kitchen/set","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"OFF","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":1820,"y":1580,"wires":[["22ef243a.a092ec"]]},{"id":"3d617965.1906d6","type":"change","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"Socket.Bedroom OFF","rules":[{"t":"set","p":"topic","pt":"msg","to":"zigbee2mqtt/Socket.Bedroom/set","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"OFF","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":1820,"y":1740,"wires":[["2663fc49.683a34"]]},{"id":"566c807.c18138","type":"change","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"Socket.Bedroom ON","rules":[{"t":"set","p":"topic","pt":"msg","to":"zigbee2mqtt/Socket.Bedroom/set","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"ON","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":1820,"y":1820,"wires":[["2663fc49.683a34"]]},{"id":"1ec56c4e.66bce4","type":"change","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"cancel","rules":[{"t":"set","p":"payload","pt":"msg","to":"cancel","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":1150,"y":1740,"wires":[["3d617965.1906d6","20cb9677.afb43a"]]},{"id":"20cb9677.afb43a","type":"mytimeout","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"OFF-Timer","outtopic":"","outsafe":"on","outwarning":"Warning","outunsafe":"off","warning":"0","timer":"40","ndebug":false,"ignoreCase":false,"repeat":false,"again":false,"x":1470,"y":1760,"wires":[["2fe85abd.e93506"],[]]},{"id":"22ef243a.a092ec","type":"link out","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","links":["46e6cd58.36b5d4"],"x":2015,"y":1620,"wires":[]},{"id":"2663fc49.683a34","type":"link out","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","links":["46e6cd58.36b5d4"],"x":2015,"y":1780,"wires":[]},{"id":"13640a.3f68fbf7","type":"link out","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","links":["46e6cd58.36b5d4"],"x":2015,"y":1940,"wires":[]},{"id":"717788ae.9c9018","type":"link out","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","links":["46e6cd58.36b5d4"],"x":2015,"y":2120,"wires":[]},{"id":"2fe85abd.e93506","type":"switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"off","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"off","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1630,"y":1760,"wires":[["3d617965.1906d6"]]},{"id":"d43eea8.aae3f18","type":"switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","property":"payload","propertyType":"msg","rules":[{"t":"false"},{"t":"true"}],"checkall":"true","repair":false,"outputs":2,"x":850,"y":1600,"wires":[["2f763ed6.55d292"],["48f756d5.70efd8"]]},{"id":"48f756d5.70efd8","type":"switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"scheduled ?","property":"topic","propertyType":"msg","rules":[{"t":"neq","v":"Kitchen-Fan","vt":"str"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":1010,"y":1660,"wires":[["799b2aae.365604"],["b42ecc8a.68f5"]]},{"id":"2f763ed6.55d292","type":"change","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"cancel","rules":[{"t":"set","p":"payload","pt":"msg","to":"cancel","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":1150,"y":1580,"wires":[["dd50b975.c674b8","3b64c66a.39f98a"]]},{"id":"dd50b975.c674b8","type":"mytimeout","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"OFF-Timer","outtopic":"","outsafe":"on","outwarning":"Warning","outunsafe":"off","warning":"0","timer":"40","ndebug":false,"ignoreCase":false,"repeat":false,"again":false,"x":1470,"y":1600,"wires":[["ce4b8e79.0c966"],[]]},{"id":"ce4b8e79.0c966","type":"switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"off","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"off","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1630,"y":1600,"wires":[["3b64c66a.39f98a"]]},{"id":"e22331e2.8dfb7","type":"switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","property":"payload","propertyType":"msg","rules":[{"t":"false"},{"t":"true"}],"checkall":"true","repair":false,"outputs":2,"x":850,"y":1920,"wires":[["e142159a.7435f8","b2586b74.a017d8"],["bad837fb.de6fb8","b2586b74.a017d8"]]},{"id":"e142159a.7435f8","type":"change","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"cancel","rules":[{"t":"set","p":"payload","pt":"msg","to":"cancel","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":1150,"y":1900,"wires":[["10c72828.3b5478","b7f0bd3c.3c538"]]},{"id":"10c72828.3b5478","type":"mytimeout","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"OFF-Timer","outtopic":"","outsafe":"on","outwarning":"Warning","outunsafe":"off","warning":"0","timer":"40","ndebug":false,"ignoreCase":false,"repeat":false,"again":false,"x":1470,"y":1920,"wires":[["52b24f47.1b622"],[]]},{"id":"52b24f47.1b622","type":"switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"off","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"off","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1630,"y":1920,"wires":[["b7f0bd3c.3c538"]]},{"id":"3ae44a54.4cbaa6","type":"switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","property":"payload","propertyType":"msg","rules":[{"t":"false"},{"t":"true"}],"checkall":"true","repair":false,"outputs":2,"x":850,"y":2100,"wires":[["96695aeb.0b2168","da082415.313f08"],["28f04feb.ee7c9","da082415.313f08"]]},{"id":"96695aeb.0b2168","type":"change","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"cancel","rules":[{"t":"set","p":"payload","pt":"msg","to":"cancel","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":1150,"y":2080,"wires":[["2117511c.13182e","1ed65a64.52ca66"]]},{"id":"2117511c.13182e","type":"mytimeout","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"OFF-Timer","outtopic":"","outsafe":"on","outwarning":"Warning","outunsafe":"off","warning":"0","timer":"40","ndebug":false,"ignoreCase":false,"repeat":false,"again":false,"x":1470,"y":2100,"wires":[["8be7980.7793f68"],[]]},{"id":"8be7980.7793f68","type":"switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"off","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"off","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1630,"y":2100,"wires":[["1ed65a64.52ca66","9d8902e.6eff7"]]},{"id":"dbcd21e4.ec6d8","type":"calculator","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"h =>sec","inputMsgField":"payload","outputMsgField":"timeout","operation":"mult","constant":"3600","round":false,"decimals":"0","x":1300,"y":1780,"wires":[["20cb9677.afb43a"]]},{"id":"f481e44f.f128c8","type":"calculator","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"h =>sec","inputMsgField":"payload","outputMsgField":"timeout","operation":"mult","constant":"3600","round":false,"decimals":"0","x":1300,"y":1620,"wires":[["dd50b975.c674b8"]]},{"id":"799b2aae.365604","type":"Thing Get","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","nodeName":"d","name":"Fan.Kitchen","props":[{"msgProp":"payload","thingProp":"state","path":"duration"}],"x":1150,"y":1640,"wires":[["f481e44f.f128c8","b42ecc8a.68f5"]]},{"id":"d1679cb9.28c1f","type":"Thing Get","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","nodeName":"d","name":"Fan.Bedroom","props":[{"msgProp":"payload","thingProp":"state","path":"duration"}],"x":1150,"y":1800,"wires":[["dbcd21e4.ec6d8","566c807.c18138"]]},{"id":"89432a43.f64d08","type":"Thing Get","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","nodeName":"d","name":"Socket.StudyFan","props":[{"msgProp":"payload","thingProp":"state","path":"duration"}],"x":1150,"y":1960,"wires":[["6be4babd.0a5d94","15649039.4ef9f"]]},{"id":"801591b0.e2016","type":"Thing Get","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","nodeName":"d","name":"Socket.PoolPump","props":[{"msgProp":"payload","thingProp":"state","path":"duration"}],"x":1150,"y":2140,"wires":[["9b7d864b.961c98","aeb83077.e43e5"]]},{"id":"15649039.4ef9f","type":"calculator","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"h =>sec","inputMsgField":"payload","outputMsgField":"timeout","operation":"mult","constant":"3600","round":false,"decimals":"0","x":1300,"y":1940,"wires":[["10c72828.3b5478"]]},{"id":"aeb83077.e43e5","type":"calculator","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"h =>sec","inputMsgField":"payload","outputMsgField":"timeout","operation":"mult","constant":"3600","round":false,"decimals":"0","x":1300,"y":2120,"wires":[["2117511c.13182e"]]},{"id":"3c5f4d0f.cb01b2","type":"rbe","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","func":"rbe","gap":"","start":"","inout":"out","property":"payload","x":730,"y":1760,"wires":[["41ee30be.b6397"]]},{"id":"67a3a0f7.30462","type":"switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"scheduled ?","property":"topic","propertyType":"msg","rules":[{"t":"neq","v":"Bedroom-Fan","vt":"str"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":1010,"y":1820,"wires":[["d1679cb9.28c1f"],["566c807.c18138"]]},{"id":"bad837fb.de6fb8","type":"switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"scheduled ?","property":"topic","propertyType":"msg","rules":[{"t":"neq","v":"Dog-Heater","vt":"str"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":1010,"y":1980,"wires":[["89432a43.f64d08"],["6be4babd.0a5d94"]]},{"id":"28f04feb.ee7c9","type":"switch","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"scheduled ?","property":"topic","propertyType":"msg","rules":[{"t":"neq","v":"Pool","vt":"str"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":1010,"y":2160,"wires":[["801591b0.e2016"],["9b7d864b.961c98"]]},{"id":"da082415.313f08","type":"debug","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1010,"y":2060,"wires":[]},{"id":"b2586b74.a017d8","type":"debug","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1010,"y":1880,"wires":[]},{"id":"575b8e7.77f417","type":"debug","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":570,"y":1420,"wires":[]},{"id":"96df2120.c8fbd","type":"inject","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":1510,"y":2040,"wires":[["1ed65a64.52ca66"]]},{"id":"274f9441.fa043c","type":"inject","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":1580,"y":2180,"wires":[["9b7d864b.961c98"]]},{"id":"9d8902e.6eff7","type":"link out","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","links":["bbf0a20e.69fd"],"x":1725,"y":2120,"wires":[]},{"id":"6c12b9a4.fdbc58","type":"json","z":"d630b1b0.d47d4","g":"30f39ff9.5c4da","name":"","property":"payload","action":"","pretty":false,"x":390,"y":1420,"wires":[["575b8e7.77f417"]]},{"id":"c17b28c1.a4c7c8","type":"ui_group","name":"Socket-Schedule","tab":"2936b813.6cde68","order":4,"disp":true,"width":"6","collapse":false},{"id":"2f47a43f.6dfa4c","type":"ui_group","name":"Socket-Timer","tab":"2936b813.6cde68","order":3,"disp":true,"width":6,"collapse":false},{"id":"2936b813.6cde68","type":"ui_tab","name":"Timer","icon":"fa-calendar-o","order":6,"disabled":false,"hidden":false}]

Thanks, but.....

Can I add new items from the GUI side of things?

That is another thing which is killing me.

I have just thought of one way to address that, but it is a bit messy.

You do have the option to input new events via JSON but you have to adhere to the given format. Additionally , i'm unclear on how you want to respond to these new events ... as they are not in your flow

Yeah, but that isn't done from the GUI side of things.

Your example works fine for what you have.

Alas mine, the number of lights to be controlled can vary. Ones taken out, new ones added.

So it NEARLY does what I want, but not quite.

I may have to go with an option of which I thought where I make more than enough entries and ....

That doesn't work, as I can't rename the entries to reflect their function.

:confused:
Work in progress.

Have a read of this thread - a couple of approaches in there

Craig

1 Like

Thanks.

They look interesting.

(If you are still reading this)

This is what I have got for a re-think of how to do what I want.
Yes it isn't as compact as it would be if I used the other nodes.
But if I add a new event, all I need to do is just copy the 3 nodes and create a new entry on the GUI.

So this is what I have as an idea:

[{"id":"d3038088ab491321","type":"ui_text_input","z":"2074fa2103de0d09","name":"","label":"TIME PICKER","tooltip":"","group":"5b9d4910cec81bcd","order":3,"width":"3","height":"1","passthru":true,"mode":"time","delay":300,"topic":"topic","topicType":"msg","x":480,"y":1180,"wires":[["19a76fba46bd82f0"]]},{"id":"19a76fba46bd82f0","type":"ui_dropdown","z":"2074fa2103de0d09","name":"","label":"","tooltip":"","place":"Select option","group":"5b9d4910cec81bcd","order":4,"width":"3","height":"1","passthru":true,"multiple":true,"options":[{"label":"Monday","value":"Monday","type":"str"},{"label":"Tuesday","value":"Tuesday","type":"str"},{"label":"Wednesday","value":"Wednesday","type":"str"},{"label":"Thursday","value":"Thursday","type":"str"},{"label":"Friday","value":"Friday","type":"str"},{"label":"Saturday","value":"Saturday","type":"str"},{"label":"Sunday","value":"Sunday","type":"str"}],"payload":"","topic":"topic","topicType":"msg","x":650,"y":1180,"wires":[["82a9564f77ab4858"]]},{"id":"69174c2ef8941e36","type":"cronplus","z":"2074fa2103de0d09","name":"","outputField":"payload","timeZone":"","outputs":1,"options":[],"x":820,"y":1180,"wires":[[]]},{"id":"5b9d4910cec81bcd","type":"ui_group","name":"Group 4","tab":"59bbef31.24f568","order":4,"disp":true,"width":6},{"id":"59bbef31.24f568","type":"ui_tab","name":"Scheduler Demo","icon":"dashboard","order":37,"disabled":false,"hidden":false}]

So I create an event and send that into the cron-plus node.
But I'm not with it (though I in typical style do it after I post the question) on how to create the message to send into the cron-plus node.
Multiple days are allowed.

Only for the sake of clarity the message for the selected day/s is the name.
That can - of course - be changed.

The other thing that is stumping me is how to concatenate the time and day of the week message/s.

But I think a join node would suffice there.

Andrew, it might be better to describe what features you want.

example 1: Timelinepicker for Node-Red in Dashboard? - #4 by Steve-Mcl

example 2: Dynamic cron schedules / timers via dashboard control (flow) - Node-RED

cron-plus is pretty much limitless in what you can do with it but great flexibility can sometimes make things (seem) more complex.

Status quo I have this dashboard:

This is not quite all that is in the flow.
There is an inject node.

This is a list of shows I watch.

The buttons simply inject a value which changes the channel if I am ahead of the event.
(This is seldom used but is there to also indicate to me which ones I have active.)

Otherwise, the inject node injects the value at the desired time.

That's where the problem is/happens.

If the time changes I have to go in and edit the inject node manually.
I want to edit the time (and day) via the GUI.

the switch node to the right of the button is there if - for what ever reason - I want to disable that event for some days.

So I want to be able to set a time and day of the week (multiple days allowed) so it sets when the event happens.

I have this bit of code, but....

[{"id":"d3038088ab491321","type":"ui_text_input","z":"2074fa2103de0d09","name":"","label":"TIME PICKER","tooltip":"","group":"5b9d4910cec81bcd","order":3,"width":"3","height":"1","passthru":true,"mode":"time","delay":300,"topic":"topic","topicType":"msg","x":340,"y":1320,"wires":[["29d55ed3809edc39"]]},{"id":"19a76fba46bd82f0","type":"ui_dropdown","z":"2074fa2103de0d09","name":"","label":"","tooltip":"","place":"Select option","group":"5b9d4910cec81bcd","order":4,"width":"3","height":"1","passthru":true,"multiple":true,"options":[{"label":"Monday","value":"Monday","type":"str"},{"label":"Tuesday","value":"Tuesday","type":"str"},{"label":"Wednesday","value":"Wednesday","type":"str"},{"label":"Thursday","value":"Thursday","type":"str"},{"label":"Friday","value":"Friday","type":"str"},{"label":"Saturday","value":"Saturday","type":"str"},{"label":"Sunday","value":"Sunday","type":"str"}],"payload":"","topic":"topic","topicType":"msg","x":360,"y":1370,"wires":[["ab5b4c9e0a3a7990"]]},{"id":"29d55ed3809edc39","type":"change","z":"2074fa2103de0d09","name":"set msg.time","rules":[{"t":"move","p":"payload","pt":"msg","to":"time","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":510,"y":1320,"wires":[["d12b994634e02873"]]},{"id":"ab5b4c9e0a3a7990","type":"change","z":"2074fa2103de0d09","name":"set msg.day","rules":[{"t":"move","p":"payload","pt":"msg","to":"day","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":510,"y":1370,"wires":[["c4db5a59c79f4b70","5fd2036054ce8e61"]]},{"id":"d12b994634e02873","type":"moment","z":"2074fa2103de0d09","name":"","topic":"","input":"time","inputType":"msg","inTz":"Australia/Sydney","adjAmount":0,"adjType":"days","adjDir":"add","format":"HH:mm","locale":"en-AU","output":"time","outputType":"msg","outTz":"Australia/Sydney","x":700,"y":1320,"wires":[["ab7b6585c4c5a9f9","19a76fba46bd82f0"]]},{"id":"5b9d4910cec81bcd","type":"ui_group","name":"Group 4","tab":"59bbef31.24f568","order":4,"disp":true,"width":6},{"id":"59bbef31.24f568","type":"ui_tab","name":"Scheduler Demo","icon":"dashboard","order":37,"disabled":false,"hidden":false}]

The TIME PICKER node is giving me grief. (Old problem again) I enter the desired time, but what it shows and what I get are .... very different. So that is painful trying to get it working.

Then a message is created and sent to a/then cron-plus node.
But that is a long way ahead of where I am just now.