Tips & Tricks: Dashboard Card to Show Pending Approvals - ad-ha/kidschores-ha GitHub Wiki
Here is a card to show outstanding approvals.
type: grid
square: false
columns: 1
cards:
- type: heading
heading: PARENT Required Actions
heading_style: title
- type: custom:mushroom-template-card
primary: |
{{ states('sensor.pending_reward_approvals') | title }} Approvals
icon: mdi:gift-open-outline
multiline_secondary: true
secondary: >
------------------------------------------------
{% for kid, rewards in
states.sensor.pending_reward_approvals.attributes.items() if kid not in
['icon', 'friendly_name'] -%}
{{ kid }}:
{% for reward in rewards -%}
{{ reward.reward_name }} (Claimed on: {{ reward['Redeemed on'] | as_timestamp | timestamp_custom('%Y-%m-%d %H:%M', true) }})
{% endfor %}
{% endfor %}
- type: custom:mushroom-template-card
primary: |
{{ states('sensor.pending_chore_approvals') | title }} Approvals
icon: mdi:clipboard-check-outline
multiline_secondary: true
secondary: >
------------------------------------------------
{% for kid, chores in
states.sensor.pending_chore_approvals.attributes.items() if kid not in
['icon', 'friendly_name'] -%}
{{ kid }}:
{% for chore in chores -%}
{{ chore.chore_name }} (Claimed on: {{ chore['Claimed on'] | as_timestamp | timestamp_custom('%Y-%m-%d %H:%M', true) }})
{% endfor %}
{% endfor %}