Skip to content

Commit

Permalink
1.5.11
Browse files Browse the repository at this point in the history
Fixed 'Value of capability changed' flow card for compound devices.
  • Loading branch information
RonnyWinkler committed Nov 30, 2023
1 parent 9557f60 commit 6997741
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 5 deletions.
4 changes: 4 additions & 0 deletions .homeychangelog.json
Original file line number Diff line number Diff line change
Expand Up @@ -526,6 +526,10 @@
"1.5.10": {
"en": "Added flow action for light device to select light effect.",
"de": "Flow-Aktion für Licht ergänzt zur Auswahl eines Lichteffektes."
},
"1.5.11": {
"en": "Fixed 'Value of capability changed' flow card for compound devices.",
"de": "'Wert des Attributes geändert' Flow-Karte korrigiert für Compound-Geräte"
}

}
2 changes: 1 addition & 1 deletion .homeycompose/app.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"id": "io.home-assistant.community",
"version": "1.5.10",
"version": "1.5.11",
"compatibility": ">=8.1.0",
"sdk": 3,
"brandColor": "#0DA6EA",
Expand Down
2 changes: 1 addition & 1 deletion app.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"_comment": "This file is generated. Please edit .homeycompose/app.json instead.",
"id": "io.home-assistant.community",
"version": "1.5.10",
"version": "1.5.11",
"compatibility": ">=8.1.0",
"sdk": 3,
"brandColor": "#0DA6EA",
Expand Down
14 changes: 13 additions & 1 deletion drivers/compound/device.js
Original file line number Diff line number Diff line change
Expand Up @@ -211,17 +211,29 @@ class CompoundDevice extends BaseDevice {
capability: key,
value_string: '',
value_number: 0,
value_boolean: false
value_boolean: false,
value_string_old: '',
value_number_old: 0,
value_boolean_old: false
};
switch (this.getCapabilityType(key)){
case "string":
tokens.value_string = value;
if (oldValue != undefined){
tokens.value_string_old = oldValue;
}
break;
case "number":
tokens.value_number = value;
if (oldValue != undefined){
tokens.value_number_old = oldValue;
}
break;
case "boolean":
tokens.value_boolean = value;
if (oldValue != undefined){
tokens.value_boolean_old = oldValue;
}
break;
}
if (this.homey.app){
Expand Down
2 changes: 1 addition & 1 deletion locales/de.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"pair": {
"title": {
"ready": "Fertig",
"device_added": "Gerät wurde hinzugefügt",
"device_added": "Gerät wird hinzugefügt",
"icon": "Icon"
},
"list_devices":{
Expand Down
2 changes: 1 addition & 1 deletion locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"pair": {
"title": {
"ready": "Ready",
"device_added": "Device was added",
"device_added": "Device is added",
"icon": "Icon"
},
"list_devices":{
Expand Down

0 comments on commit 6997741

Please sign in to comment.