mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-16 05:46:52 +00:00
Merge pull request #98 from CCOSTAN/patch-3
Expanded example for Condition OR.
This commit is contained in:
commit
296e15684c
@ -206,11 +206,16 @@ or off.
|
||||
|
||||
An automation rule can have mulitiple triggers. By default the action will only fire if all conditions
|
||||
pass. An optional key `condition_type: 'or'` can be set on the automation rule to fire action if any
|
||||
condition matches.
|
||||
condition matches. In the example below, the automation would trigger if the time is before 05:00 _OR_ after 20:00.
|
||||
|
||||
```yaml
|
||||
automation:
|
||||
condition_type: or
|
||||
condition:
|
||||
- platform: time
|
||||
before: '05:00'
|
||||
- platform: time
|
||||
after: '20:00'
|
||||
```
|
||||
|
||||
If your triggers and conditions are exactly the same, you can use a shortcut to specify conditions.
|
||||
|
Loading…
x
Reference in New Issue
Block a user