When interaction with buttons/switches/sliders in the interface, a confirmation dialog would be extremely useful. While it would be nice to be able to configure it on a per-component interface, it would suffice to have it global.
Right now, I’ve had a hard time using the interface from my phone, as I accidentally end up opening my garage doors as I scroll.
I think that this should be a per entity thing. I don’t want confirmation for lights, but I would really like it for things like system reboot or garage doors as you said.
customize:
switch.telldus_tzwp100_plugin_switch_switch_10_0:
friendly_name: Media center power
icon: mdi:power
confirmation_dialog: Are you sure you want to power off the entire media center?
If confirmation_dialog is defined a dialog will appear asking you to confirm the action with a custom message.
I also accidentally opened my door. It wasn’t the garage door, but way worst… was the door that grant access to my 2 dogs and they slept on the couch that night… wife wasn’t happy!! this should be top priority!!
I also think this is VERY important! I have several actions I don’t want to call without confirmation, just because I accidentally clicked the buttons with my big fingers.
It would be even better, if you can run a script before switching off - or add some conditions:
User clicks power off (e.g. computer with Lightify plug)
HA checks, if sensor.computer says that the computer is not running
If computer is still running HA asks if you really want to power off the Lightify plug
Most of that you can already do using automations. Only the confirmation dialog would be missing, and automations don’t have if/else functionality. They (sadly) only support “if yes…then”.
But at least for the if / else stuff you could use AppDaemon and maybe even the new Python Scripts component.
Thinking of it, you could still probably get everything you want by using a Telegram bot which would notify you, and from there you could confirm. Although I have to admit, that it would be much more complicated that way. But in theory it should be possible already with Telegram instead of an extra WebUI confirmation dialog.
My (ugly) workaround is using two input booleans and only doing the action (opening the door or rebooting the system) when the are pressed. Both have an automation to reset them to OFF after 2 seconds or so.
My use case is a bit different than the ideia I wrote on the previous post: I have a script which reboots the RaspberryPi, and only want the script to run if an Input Boolean is previously turned on. So, the input boolean:
input_boolean:
allow_system_reboot:
initial: off
The scrip that reboots the Pi has a condition to check that the input boolean is On, and won’t run the shell_command if the condition is false:
Just adding in my 2 cents that i have smoke sensors that also work as sirens. If you click wrong at night, someone is going to be very unhappy. Same goes for the door opener option. Almost exactly like above, i thought a “confirmation: ‘Are you sure you want to open the door’” would be really nice.
So I ended up using Alarm Panel with a single digit code as follows, the code is the confirm as you cannot accidently enter the code
IN
configuration.yaml
alarm_control_panel:
platform: manual
name: “Front Door Lock”
pending_time: 2
code: “1”
in
automation.yaml
##############################################################################################
################################### Alarm Panel to open Front Door ########################
##############################################################################################
alias: alarm open front door
trigger:
platform: state
entity_id: alarm_control_panel.front_door_lock
to: pending
action:
It would also be nice to have an error message if the command fails. My radio thermostat can time out sometimes when trying to change anything and there is no error message - it just never updates and you have to know to try again. Not sure if that should be a separate feature request…
I agree. I was initially thinking a custom cover control would be best, but a simple dialogue box is what is needed. On HA, for a cover/garage door, actual status (closed/open/closing/opening) is more useful than them all.
I also think this would be an important feature for switches.
Especially after accidentally turning off all smart switches while I was away, including the modem, so non reversible, and the fridge/freezer plug. Oops.
I was scrolling on the phone screen and I accidentally pressed the off in the All Switches panel.
I have since learned to not have the modem on a smart switch, but it would still be good to be able to customize switches with a confirmation dialogue natively.
Custom ui has this feature, without the confirmation dialog, but with a lock on the switch that has to be pressed once to remove lock before pressing again for actually moving switch. Easy setup and either do all entities, all lights etc or per entity.