I would like to use the increase of the shopping list items as a condition to trigger an action.
The number of the state changes but I’m puzzled on how to use this.
Any help is highly appreciated!
TIA
I would like to use the increase of the shopping list items as a condition to trigger an action.
The number of the state changes but I’m puzzled on how to use this.
Any help is highly appreciated!
TIA
Do you mean like…
condition: template
value_template: "{{ trigger.to_state.state|int > trigger.from_state.state|int }}"
… or something else ?
Hi Didgeridrew, thanks for jumping in!
I’m bending my head how to use this but cannot see it. ![]()
Sorry if my question is unclear…
What I’m trying to achieve is when a voice command is given to add an item to the shopping list, I would like to have a popup with the shopping list.
The popup is not a problem but I cannot find a way to use the increase of number of items as a trigger to show this popup.
Owkay, I got it:
trigger: state
entity_id:
- todo.shopping_list
not_from:
- unavailable
not_to:
- unavailable
This seems to work so far, got it from one of your answers! ![]()
I also tried to use your example as a condition but that didn’t work.
It’s not exactly what I was looking for since removing an item also triggers but that’s not a biggy.