Page 1 of 2

How to make schedule conditional?

Posted: 29 Nov 2018 16:38
by msambol
I would like to have a virtual button which I can use to indicate when I am travelling away from home, and use it to pause my scheduled events like turning on lights and opening window shutters. I thought I could use the dummy device for this, but I can not find a way to make scheduled events conditional, or to pause the schedules.

Can anyone recommend a way to do this?

Re: How to make schedule conditional?

Posted: 02 Dec 2018 16:05
by PoltoS
Your Schedule can run a scene that can be a trigger for logical rule that depends on the Dummy device.

A bit overcomplicated, but works ;)

Re: How to make schedule conditional?

Posted: 02 Dec 2018 19:45
by msambol
Thank you for responding. Yes that is over complicated, but I'll take what I can get. I didn't realize a rule can trigger on a scene, will try.

Stuff like this will unfortunately keep non technical people away from this platform.

Re: How to make schedule conditional?

Posted: 04 Dec 2018 00:37
by PoltoS
Show me where you can easily do such a specific things.

Z-Way style is to allow it complicated and if the request becomes popular, make an app for that

Re: How to make schedule conditional?

Posted: 17 Feb 2019 13:07
by tomshuette
Year, more and more Apps :)

But we lost the overview

We Need a Tool to show the interconnection and Logic over all

Re: How to make schedule conditional?

Posted: 17 Feb 2019 16:09
by piet66
Here a tool which may help a little bit.
You can display the interconnections as graphics, but not the rules :cry: .

Extract the contents of the zip file to z-way-server/htdocs/smarthome/user/.
Call it, logged in as administrator, with http://<your ip>:8083/smarthome/user/MxInfo and click onto dependencies.html.

Attachment removed, will upload new version.

Re: How to make schedule conditional?

Posted: 17 Feb 2019 20:07
by PoltoS
Wow! Nice tool for inspection of the API content.

But I get few errors:
js/dependencies.min.js:1 Uncaught TypeError: Cannot read property 'indexOf' of undefined
at js/dependencies.min.js:1
at Array.forEach (<anonymous>)
at Object.success (js/dependencies.min.js:1)
at u (jquery.min.js:2)
at Object.fireWith [as resolveWith] (jquery.min.js:2)
at k (jquery.min.js:2)
at XMLHttpRequest.<anonymous> (jquery.min.js:2)

:1 Uncaught TypeError: Cannot read property 'getAttribute' of undefined
at http://192.168.0.32:8083/smarthome/user/MxInfo/:1:249
at Array.sort (native)
at srt (http://192.168.0.32:8083/smarthome/user/MxInfo/:1:147)
at window.onload (http://192.168.0.32:8083/smarthome/user/MxInfo/:1:704)

Also not sure why do you need this: http://192.168.0.32:8083/smarthome/user ... asses.html
Just to inspect the xml in more comfort?

And ZWave_cmd_classes.xml and cmd_classes.json are already in the UI source tree. You are better to use them from Z-Way not to bring 2 Mb more (this is critical on small platforms)

If people will like it, may be it is worth to include in standard package with a contrinution notice? What do you think? You can make it as PR.

Re: How to make schedule conditional?

Posted: 17 Feb 2019 20:13
by PoltoS
And one more:
configjson.js:342 Uncaught TypeError: Cannot read property 'forEach' of undefined
at configjson.js:342
at Array.forEach (<anonymous>)
at buildDevArrays (configjson.js:338)
at Object.success (configjson.js:267)
at u (jquery.min.js:2)
at Object.fireWith [as resolveWith] (jquery.min.js:2)
at k (jquery.min.js:2)
at XMLHttpRequest.<anonymous> (jquery.min.js:2)

Re: How to make schedule conditional?

Posted: 17 Feb 2019 20:20
by micky1500
A Wow from me too.
I'm finding out what is hidden away using this.
I don't see any Dependencies, but the other tools are great.
I don't get any errors. On 2.3.8 with Jessie Build.

Thanks piet66

Re: How to make schedule conditional?

Posted: 17 Feb 2019 22:33
by piet66
Hi PoltoS,
I'm getting none of your errors. Running on Raspi Jessi with Z-Way 2.3.7, browser is Firefox. Must be anything different on your machine.

You can easily delete those functions you don't want to use to save space. I did it for me and for me they were useful.

You can include it in standard package, if it's working. But not all functions are useful for all people. And I don't know how to make it as PR.

Hi micky,
attached a screenshot of a dependencies graph.