We need to START the med scripts by incrementing the counter

Doing it at the end means things that should happen on the third reminder will not actually happen until the fourth.

#205
This commit is contained in:
2024-07-30 20:04:27 -04:00
parent d9d249048f
commit 17da9c4ef9

View File

@ -1647,6 +1647,12 @@ tony_morning_meds:
icon: mdi:medication icon: mdi:medication
mode: restart mode: restart
sequence: sequence:
- service: counter.increment
metadata: {}
data: {}
target:
entity_id: counter.tony_morning_meds_reminder_count
alias: Increment morning reminder counter
- service: script.text_notify - service: script.text_notify
data: data:
type: alert type: alert
@ -1688,17 +1694,17 @@ tony_morning_meds:
message: Tony, you need to take your morning meds. This is reminder number message: Tony, you need to take your morning meds. This is reminder number
{{ states('counter.tony_morning_meds_reminder_count') }} for today. {{ states('counter.tony_morning_meds_reminder_count') }} for today.
alias: Send TTS notification alias: Send TTS notification
- service: counter.increment
metadata: {}
data: {}
target:
entity_id: counter.tony_morning_meds_reminder_count
alias: Increment morning reminder counter
tony_night_meds: tony_night_meds:
alias: Tony Night Meds alias: Tony Night Meds
icon: mdi:medication icon: mdi:medication
mode: restart mode: restart
sequence: sequence:
- service: counter.increment
metadata: {}
data: {}
target:
entity_id: counter.tony_night_meds_reminder_count
alias: Increment night reminder counter
- service: script.text_notify - service: script.text_notify
data: data:
type: alert type: alert
@ -1740,12 +1746,6 @@ tony_night_meds:
message: Tony, you need to take your night meds. This is reminder number message: Tony, you need to take your night meds. This is reminder number
{{ states('counter.tony_night_meds_reminder_count') }} for today. {{ states('counter.tony_night_meds_reminder_count') }} for today.
alias: Send TTS notification alias: Send TTS notification
- service: counter.increment
metadata: {}
data: {}
target:
entity_id: counter.tony_night_meds_reminder_count
alias: Increment night reminder counter
tony_stream_today: tony_stream_today:
alias: Tony Stream Today alias: Tony Stream Today
sequence: sequence:
@ -1897,6 +1897,12 @@ tony_afternoon_meds:
icon: mdi:medication icon: mdi:medication
mode: restart mode: restart
sequence: sequence:
- service: counter.increment
metadata: {}
data: {}
target:
entity_id: counter.tony_afternoon_meds_reminder_count
alias: Increment afternoon reminder counter
- service: script.text_notify - service: script.text_notify
data: data:
type: alert type: alert
@ -1938,12 +1944,6 @@ tony_afternoon_meds:
message: Tony, you need to take your afternoon meds. This is reminder number message: Tony, you need to take your afternoon meds. This is reminder number
{{ states('counter.tony_afternoon_meds_reminder_count') }} for today. {{ states('counter.tony_afternoon_meds_reminder_count') }} for today.
alias: Send TTS notification alias: Send TTS notification
- service: counter.increment
metadata: {}
data: {}
target:
entity_id: counter.tony_afternoon_meds_reminder_count
alias: Increment afternoon reminder counter
tony_ibuprofen: tony_ibuprofen:
alias: Tony Ibuprofen alias: Tony Ibuprofen
sequence: sequence: