Open ronniebee opened 4 years ago
First of all, thanks for this awesome little mod, it's great. I'm also struggle with time zone and formatting. What i'm trying to achieve is using the next_sunset
or next_sunrise
attributes display, depending on which one comes first, for instance "Sunset at 20:00" or "Sunrise at 06:00". I've not been able to combine if/else-dependent text with attribute data. And also formatting, i'd prefer a short readable "20:00" over "2020-04-13 18:00:00+00:00". This might be me not understanding how to apply the right properties, but this is where i'm at atm. What i've got so far, only full date/time without text:
secondary_info: >-
[[ if({entity}.attributes.next_rising > {entity}.attributes.next_setting,
sun.sun.attributes.next_rising, sun.sun.attributes.next_setting ) ]]
It would be really nice to be able to format date/time.
Came here looking for the answer to this exact same question. It's been three years. Did any of you figure it out?
Templating is done by jinja and core HA extensions. Address all your questions to jinja and HA developers.
Great card! Many thanks!! I have a question, which timezone is being used? I use GMT+1 (local time) but the time being displayed GMT+0:00 (so one hour too early). I changed my ubuntu TZ into:
But still no result.. What to do?