NEW template integration help

Hi everyone,

can you take a look over it?
I want to compare two objects.
So compare two different entities.
Thank you

  - sensor:
      - name: "Zimmerreinigung"
        state: >
          {% if is_state('sensor.xiaomi_cloud_map_extractor_vacuum_room', '16') %}
            Gäste WC
          {% elif is_state('sensor.xiaomi_cloud_map_extractor_vacuum_room', '17') %}
            Vorratskammer
          {% elif is_state('sensor.xiaomi_cloud_map_extractor_vacuum_room', '18') == is_state('sensor.xiaomi_vacuum_cleaner_status', 'Charging')  %}
            Laden
          {% elif is_state('sensor.xiaomi_cloud_map_extractor_vacuum_room', '19') %}
            Küche
          {% elif is_state('sensor.xiaomi_cloud_map_extractor_vacuum_room', '20') %}
            Küche Essbereich
          {% elif is_state('sensor.xiaomi_cloud_map_extractor_vacuum_room', '21') %}
            Wohnzimmer
          {% elif is_state('sensor.xiaomi_cloud_map_extractor_vacuum_room', '22') %}
            Wohnzimmer Essbereich
          {% else %}
            Flur
          {% endif %}

You want to compare those entities or you want that if room=18 AND status=charging?

room=18 AND status=charging
But the status are different entities.

sensor.xiaomi_cloud_map_extractor_vacuum_room', '18'
sensor.xiaomi_vacuum_cleaner_status', 'Charging'

Try this:

          {% elif (is_state('sensor.xiaomi_cloud_map_extractor_vacuum_room', '18') and is_state('sensor.xiaomi_vacuum_cleaner_status', 'Charging'))  %}
            Laden

This should do your AND.