Open chuckberrypi opened 10 months ago
As an alternative you could use lovelace-auto-entities with lovelace-multiple-entity-row and display an icon with a service action as additional entity in each row.
Custom cards are in the plans, I started them a few months back but then got busy on other projects. It may be a little while until I get the time to complete them, but I absolutely agree they are sorely needed.
I am using Auto Entities for this purpose currently, and it does work OK, so I agree that's an option in the meantime.
As an alternative you could use lovelace-auto-entities with lovelace-multiple-entity-row and display an icon with a service action as additional entity in each row.
@cybe @bmcclure Could either of you by any chance share the yaml of how to achieve this? I'm having trouble properly filling the lovelace-multiple-entity-row inside lovelace-auto-entities and it sounds like you've already managed it 🙂
Ah, I managed to figure it out. So I'll just leave the code here in case it is of help to someone else:
I've given my chore-helpers the label 'chore' and this card shows each chore that is either due today or in the past with a button to complete the chore.
card:
type: entities
title: Todo
filter:
include:
- label: chore
state: < 1
options:
type: custom:multiple-entity-row
secondary_info:
attribute: last_completed
format: relative
entities:
- icon: mdi:check-outline
state_color: true
tap_action:
action: call-service
service: chore_helper.complete
service_data:
entity_id: this.entity_id
confirmation:
text: You sure?```
Checklist
Is your feature request related to a problem? Please describe.
I don't find checking tasks off my list very ergonomical
Describe the solution you'd like
I'd like to be able to add a dashboard that shows a button for each of the chores that are overdue. I'd like to be able to add a dashboard that shows a button for each of the chores that are overdue. Clicking on the button will call the service for completing the chore.
Describe alternatives you've considered
entity filter cards. Apparently it doesn't allow the use of templates. Also tried the regular entity card for chores, but it doesn't seem to have an interface for completing the chore.
Additional context
None