Compare commits
2 Commits
7ee779cfe4
...
66b69199d6
| Author | SHA1 | Date | |
|---|---|---|---|
| 66b69199d6 | |||
| 0cdfc2b1ee |
@@ -1,5 +1,5 @@
|
|||||||
- platform: template
|
- platform: template
|
||||||
sensors:
|
sensors:
|
||||||
living_room_tv_source:
|
living_room_tv_source:
|
||||||
value_template: '{{ states.media_player.stue_2.attributes["source"] }}'
|
value_template: '{{ state_attr('media_player.stue_2','source') | default('unknown') }}'
|
||||||
friendly_name: 'Living Room TV Source'
|
friendly_name: 'Living Room TV Source'
|
||||||
|
|||||||
@@ -1,138 +0,0 @@
|
|||||||
- platform: rest
|
|
||||||
resource: !secret mealie_api_URL_mealplan
|
|
||||||
name: mealie_mealplan_day0
|
|
||||||
scan_interval: 900
|
|
||||||
headers:
|
|
||||||
Authorization: ClausMealieHA !secret mealie_api_token
|
|
||||||
params:
|
|
||||||
start: >
|
|
||||||
{{ now().strftime('%Y-%m-%d') }}
|
|
||||||
limit: >
|
|
||||||
{{ now().strftime('%Y-%m-%d') }}
|
|
||||||
json_attributes_path: "$.[0].recipe"
|
|
||||||
json_attributes:
|
|
||||||
- id
|
|
||||||
- name
|
|
||||||
- slug
|
|
||||||
- image
|
|
||||||
value_template: "{{ value_json.date }}"
|
|
||||||
|
|
||||||
# Tomorrow
|
|
||||||
- platform: rest
|
|
||||||
resource: !secret mealie_api_URL_mealplan
|
|
||||||
name: mealie_mealplan_day1
|
|
||||||
scan_interval: 900
|
|
||||||
headers:
|
|
||||||
Authorization: ClausMealieHA !secret mealie_api_token
|
|
||||||
params:
|
|
||||||
start: >
|
|
||||||
{{ (now() + timedelta(days = 1)).strftime('%Y-%m-%d') }}
|
|
||||||
limit: >
|
|
||||||
{{ (now() + timedelta(days = 1)).strftime('%Y-%m-%d') }}
|
|
||||||
json_attributes_path: "$.[0].recipe"
|
|
||||||
json_attributes:
|
|
||||||
- id
|
|
||||||
- name
|
|
||||||
- slug
|
|
||||||
- image
|
|
||||||
value_template: "{{ value_json.date }}"
|
|
||||||
|
|
||||||
# Day 2
|
|
||||||
- platform: rest
|
|
||||||
resource: !secret mealie_api_URL_mealplan
|
|
||||||
name: mealie_mealplan_day2
|
|
||||||
scan_interval: 900
|
|
||||||
headers:
|
|
||||||
Authorization: ClausMealieHA !secret mealie_api_token
|
|
||||||
params:
|
|
||||||
start: >
|
|
||||||
{{ (now() + timedelta(days = 2)).strftime('%Y-%m-%d') }}
|
|
||||||
limit: >
|
|
||||||
{{ (now() + timedelta(days = 2)).strftime('%Y-%m-%d') }}
|
|
||||||
json_attributes_path: "$.[0].recipe"
|
|
||||||
json_attributes:
|
|
||||||
- id
|
|
||||||
- name
|
|
||||||
- slug
|
|
||||||
- image
|
|
||||||
value_template: "{{ value_json.date }}"
|
|
||||||
|
|
||||||
# Day 3
|
|
||||||
- platform: rest
|
|
||||||
resource: !secret mealie_api_URL_mealplan
|
|
||||||
name: mealie_mealplan_day3
|
|
||||||
scan_interval: 900
|
|
||||||
headers:
|
|
||||||
Authorization: ClausMealieHA !secret mealie_api_token
|
|
||||||
params:
|
|
||||||
start: >
|
|
||||||
{{ (now() + timedelta(days = 3)).strftime('%Y-%m-%d') }}
|
|
||||||
limit: >
|
|
||||||
{{ (now() + timedelta(days = 3)).strftime('%Y-%m-%d') }}
|
|
||||||
json_attributes_path: "$.[0].recipe"
|
|
||||||
json_attributes:
|
|
||||||
- id
|
|
||||||
- name
|
|
||||||
- slug
|
|
||||||
- image
|
|
||||||
value_template: "{{ value_json.date }}"
|
|
||||||
|
|
||||||
# Day 4
|
|
||||||
- platform: rest
|
|
||||||
resource: !secret mealie_api_URL_mealplan
|
|
||||||
name: mealie_mealplan_day4
|
|
||||||
scan_interval: 900
|
|
||||||
headers:
|
|
||||||
Authorization: ClausMealieHA !secret mealie_api_token
|
|
||||||
params:
|
|
||||||
start: >
|
|
||||||
{{ (now() + timedelta(days = 4)).strftime('%Y-%m-%d') }}
|
|
||||||
limit: >
|
|
||||||
{{ (now() + timedelta(days = 4)).strftime('%Y-%m-%d') }}
|
|
||||||
json_attributes_path: "$.[0].recipe"
|
|
||||||
json_attributes:
|
|
||||||
- id
|
|
||||||
- name
|
|
||||||
- slug
|
|
||||||
- image
|
|
||||||
value_template: "{{ value_json.date }}"
|
|
||||||
|
|
||||||
# Day 5
|
|
||||||
- platform: rest
|
|
||||||
resource: !secret mealie_api_URL_mealplan
|
|
||||||
name: mealie_mealplan_day5
|
|
||||||
scan_interval: 900
|
|
||||||
headers:
|
|
||||||
Authorization: ClausMealieHA !secret mealie_api_token
|
|
||||||
params:
|
|
||||||
start: >
|
|
||||||
{{ (now() + timedelta(days = 5)).strftime('%Y-%m-%d') }}
|
|
||||||
limit: >
|
|
||||||
{{ (now() + timedelta(days = 5)).strftime('%Y-%m-%d') }}
|
|
||||||
json_attributes_path: "$.[0].recipe"
|
|
||||||
json_attributes:
|
|
||||||
- id
|
|
||||||
- name
|
|
||||||
- slug
|
|
||||||
- image
|
|
||||||
value_template: "{{ value_json.date }}"
|
|
||||||
|
|
||||||
# Day 6
|
|
||||||
- platform: rest
|
|
||||||
resource: !secret mealie_api_URL_mealplan
|
|
||||||
name: mealie_mealplan_day6
|
|
||||||
scan_interval: 900
|
|
||||||
headers:
|
|
||||||
Authorization: ClausMealieHA !secret mealie_api_token
|
|
||||||
params:
|
|
||||||
start: >
|
|
||||||
{{ (now() + timedelta(days = 6)).strftime('%Y-%m-%d') }}
|
|
||||||
limit: >
|
|
||||||
{{ (now() + timedelta(days = 6)).strftime('%Y-%m-%d') }}
|
|
||||||
json_attributes_path: "$.[0].recipe"
|
|
||||||
json_attributes:
|
|
||||||
- id
|
|
||||||
- name
|
|
||||||
- slug
|
|
||||||
- image
|
|
||||||
value_template: "{{ value_json.date }}"
|
|
||||||
|
|||||||
Reference in New Issue
Block a user