Conditional Server Actions

Posted on
Tue Jan 26, 2021 1:01 pm
grayner01 offline
Posts: 3
Joined: Dec 15, 2020

Conditional Server Actions

I have many use cases where the program would be greatly simplified if I could conditionally execute a server action. Notionally the function would be a server action that has a 'Condition' tab very similar to the 'Condition' tab on triggers. The difference is that the 'Trigger' is the calling of the server action.

I have many tedious operations (100+ external sensors) where I only want certain actions associated with each individual trigger to happen at certain times of the day. If I could have the 'Condition' option, I would simply call the server action (from each individual 100+ unique possible trigger actions) and it would only execute when my conditions were met (such as time window in a day). I know that I could create a unique trigger variable for each possible 100+ unique trigger condition and do it that way, but the maintenance for a common server action becomes untenable.

How can I do a conditional server action? Is it possible to add this feature to server actions?

Gary.

Posted on
Wed Jan 27, 2021 11:06 am
jay (support) offline
Site Admin
User avatar
Posts: 18219
Joined: Mar 19, 2008
Location: Austin, Texas

Re: Conditional Server Actions

A UI for this is on the feature request list for consideration in a future version.

The current implementation is to have an action group, which is called for all your different scenarios, execute a script that would encapsulate your conditional logic and only execute the appropriate actions.

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 2 guests

cron