From a18a5eff3ccdefd31242acfaadf08a62cc30c2d7 Mon Sep 17 00:00:00 2001 From: Jeremy Willans Date: Wed, 30 Jun 2021 11:51:00 +1000 Subject: [PATCH] add room check before selective clean --- vacuum.yaml | 30 ++++++++++++++++++------------ 1 file changed, 18 insertions(+), 12 deletions(-) diff --git a/vacuum.yaml b/vacuum.yaml index 1f6214d..22e936b 100644 --- a/vacuum.yaml +++ b/vacuum.yaml @@ -404,17 +404,17 @@ input_text: group: vacuum_rooms: entities: - - input_boolean.vacuum_clean_kitchen - - input_boolean.vacuum_clean_entry - - input_boolean.vacuum_clean_hall - - input_boolean.vacuum_clean_living_room - - input_boolean.vacuum_clean_bathroom - - input_boolean.vacuum_clean_bedroom - - input_boolean.vacuum_clean_wardrobe - - input_boolean.vacuum_clean_master_ensuite - - input_boolean.vacuum_clean_master_bedroom - - input_boolean.vacuum_clean_table - - input_boolean.vacuum_clean_zone_fridge + - input_boolean.vacuum_clean_kitchen + - input_boolean.vacuum_clean_entry + - input_boolean.vacuum_clean_hall + - input_boolean.vacuum_clean_living_room + - input_boolean.vacuum_clean_bathroom + - input_boolean.vacuum_clean_bedroom + - input_boolean.vacuum_clean_wardrobe + - input_boolean.vacuum_clean_master_ensuite + - input_boolean.vacuum_clean_master_bedroom + - input_boolean.vacuum_clean_table + - input_boolean.vacuum_clean_zone_fridge ################################### # Automation @@ -425,7 +425,13 @@ automation: - alias: Vacuum Clean Rooms trigger: - platform: event - event_type: initiate_vacuum_clean + event_type: initiate_vacuum_clean + condition: + condition: not + conditions: + - condition: state + entity_id: input_text.vacuum_rooms + state: '' action: - service: rest_command.vacuum_clean data_template: