However I get …
2017-07-18 23:17:22 ERROR (MainThread) [homeassistant.config] Invalid config for [automation]: Entity ID {{ trigger.to_state.state }} is an invalid entity id for dictionary value @ data[‘action’][0][‘entity_id’]. Got None. (See ?, line ?). Please check the docs at https://home-assistant.io/components/automation/
Anyone have any ideas how this can be accomplished?
Hmm I’m not sure that would work here as the entity_id is known but with mine it’s determined by the input_select, I’m not setting an attribute of an entity_id, I’m trying to turn on a switch using an input_select, so I don’t think a template will work in this case.
This method is OK for 5 commands but when faced with 15 or 20 for led bulbs for instance it’s a bit of a PIA. I’ll give danichispa’s idea a go later to see if that will work, tho’ I did try it without the data_template bit, so maybe that’s all I needed, I’l report back later