Fixed template (#4745)

The example notify is invalid, missing the required `data_template:` line
This commit is contained in:
DubhAd 2018-02-25 08:51:41 +00:00 committed by Fabian Affolter
parent fb973c743c
commit 8763565cc1

View File

@ -43,12 +43,13 @@ script:
msg_who_is_home: msg_who_is_home:
sequence: sequence:
- service: notify.notify - service: notify.notify
message: > data_template:
{% raw %}{% if is_state('device_tracker.paulus', 'home') %} message: >
Ha, Paulus is home! {% raw %}{% if is_state('device_tracker.paulus', 'home') %}
{% else %} Ha, Paulus is home!
Paulus is at {{ states('device_tracker.paulus') }}. {% else %}
{% endif %}{% endraw %} Paulus is at {{ states('device_tracker.paulus') }}.
{% endif %}{% endraw %}
``` ```
[Jinja2](http://jinja.pocoo.org/) supports a wide variety of operations: [Jinja2](http://jinja.pocoo.org/) supports a wide variety of operations: