Add user group selector. Fix #13

This commit is contained in:
thomas committed 2019-12-10 21:38:34 +01:00
1 parent 5495c5ba8c
commit ac934da820
3 files changed
+7 -2

No files matched your search

+2
View File
@@ -33,6 +33,8 @@ class StateSwitch extends LitElement {
case "user":
newstate = this.hass && this.hass.user && this.hass.user.name || undefined;
break;
case "group":
newstate = (this.hass && this.hass.user && this.hass.user.is_admin) ? "admin" : "user";
case "deviceID":
case "browser":
newstate = deviceID;