Hallo,
was muss ich in meinem bestehenden Code einfügen, damit die Tage in der Wetterwarnung in Deutsch angezeigt werden?
Hier mein Code:
{% set level_colors = {0:'#c5e566', 1:'#ffeb3b', 2:'#fb8c00', 3:'#e53935', 4:'#880e4f', 20:'#fe68fe', 50:'#fe68fe'} %}
{% set current_count = state_attr("sensor.dwd_weather_warnings_105978000_aktuelle_warnstufe", "warning_count") %}
{% set advance_count = state_attr("sensor.dwd_weather_warnings_105978000_vorwarnstufe", "warning_count") %}
{% if ((current_count == 0 or current_count == None) and (advance_count == 0 or advance_count == None)) %}
*<font color={{ level_colors[0] }}>Keine Warnungen</font>*
{% else %}
{% for i in range(current_count) %}
{% set headline = state_attr("sensor.dwd_weather_warnings_105978000_aktuelle_warnstufe", "warning_" ~ loop.index ~ "_headline") %}
{% set description = state_attr("sensor.dwd_weather_warnings_105978000_aktuelle_warnstufe", "warning_" ~ loop.index ~ "_description") %}
{% set level = state_attr("sensor.dwd_weather_warnings_105978000_aktuelle_warnstufe", "warning_" ~ loop.index ~ "_level") %}
{% set time_start = state_attr("sensor.dwd_weather_warnings_105978000_aktuelle_warnstufe", "warning_" ~ loop.index ~ "_start") %}
{% set time_end = state_attr("sensor.dwd_weather_warnings_105978000_aktuelle_warnstufe", "warning_" ~ loop.index ~ "_end") %}
**<font color={{ level_colors[level] }}>{{ headline }}</font>**
{{ time_start.strftime("%a %H:%M") ~ " - " ~ time_end.strftime("%a %H:%M") }}
{{ description|trim }}
{% if not loop.last %}
***
{% endif %}
{% endfor %}
{% if ((current_count != 0) and (advance_count != 0)) %}***{% endif %}
{% for i in range(advance_count) %}
{% set headline = state_attr("sensor.dwd_weather_warnings_105978000_vorwarnstufe", "warning_" ~ loop.index ~ "_headline") %}
{% set description = state_attr("sensor.dwd_weather_warnings_105978000_vorwarnstufe", "warning_" ~ loop.index ~ "_description") %}
{% set level = state_attr("sensor.dwd_weather_warnings_105978000_vorwarnstufe", "warning_" ~ loop.index ~ "_level") %}
{% set time_start = state_attr("sensor.dwd_weather_warnings_105978000_vorwarnstufe", "warning_" ~ loop.index ~ "_start") %}
{% set time_end = state_attr("sensor.dwd_weather_warnings_105978000_vorwarnstufe", "warning_" ~ loop.index ~ "_end") %}
*<font color={{ level_colors[level] }}>{{ headline }}</font>*
{{ time_start.strftime("%a %H:%M") ~ " - " ~ time_end.strftime("%a %H:%M") }}
{{ description|trim }}
{% if not loop.last %}***{% endif %}
{% endfor %}
{% endif %}