Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to select object-based Attribute? #87

Open
ChristophCaina opened this issue Sep 16, 2022 · 2 comments
Open

How to select object-based Attribute? #87

ChristophCaina opened this issue Sep 16, 2022 · 2 comments

Comments

@ChristophCaina
Copy link

Hi,
I've just switched from the attribues card to the flex-table-card in the hope, it would allow me to fix one of my current issues...
Unfortunately, it seems that I am not able to wirte down my yaml in a way that I can do, what I want ... maybe, someone can give me some help?

I have a sensor with the following attributes:

engine:
  engine_type: iV
  power_in_kw: 132
  battery_capacity_kwh: 62
model: ŠKODA Enyaq 60 iV 60/2022-05-17
assumed_state: true
icon: mdi:information-outline
friendly_name: Enyaq iV60 Car Info

Now, I want to display engine.power_in_kw as well as engine.battery_capacity within the flex table.

it should be something like that:

power_in_kw 132
battery_capacity_kwh 62
@Veejer
Copy link
Contributor

Veejer commented Sep 16, 2022

I have run into the same issue. See #86
In the meantime, you can do something like this:

data: engine
modify: x.power_in_kw

@daringer
Copy link
Collaborator

daringer commented Sep 3, 2023

actually this should work:

data: engine.engine_type 

it might be needed to put a 0 in between:

data: engine.0.engine_type 

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

3 participants