Hello,
What am I missing ? Smartphone entities are double and there is no alphabetic sorting :
- type: custom:auto-entities
sort:
method: state
numeric: true
card:
type: entities
filter:
include:
- entity_id: '*battery_level*'
- attributes:
device_class: battery
state_class: measurement
options:
type: custom:mushroom-template-card
primary: '{{ states[''this.entity_id''].attributes.friendly_name }}'
secondary: '{{ states[''this.entity_id''].state }}%'
icon: >-
{% set battery_level = states['this.entity_id'].state
|float(0) %} {% set battery_round = (battery_level / 10)
| int(0) * 10 %} {% if (battery_round >= 100) %}
{{ 'mdi:battery' }}
{% else %}
{% if (battery_round > 0) %}
{{'mdi:battery-' ~ battery_round}}
{% else %}
{{ 'mdi:battery-alert' }}
{% endif %}
{% endif %}
icon_color: >-
{% set battery_level = states['this.entity_id'].state
|int(0) %} {% set battery_round = (battery_level / 10) |
int(0) * 10 %} {% if (battery_level >= 50) %}
{{ 'green' }}
{% else %}
{% if (battery_level > states('input_number.number_batterij_drempel') |int(0)) %}
{{'orange'}}
{% else %}
{{ 'red' }}
{% endif %}
{% endif %}
tap_action:
action: none
double_tap_action:
action: none
exclude:
- attributes:
friendly_name: Temperature Sensor*
- attributes:
friendly_name: Water Leak Sensor*
- attributes:
friendly_name: Door Sensor*
- attributes:
friendly_name: Motion Sensor*
- attributes:
friendly_name: Nest Protect*
sort:
method: name
numeric: false
ignore_case: true