Standardize some entity constants naming
This commit is contained in:
@ -27,8 +27,8 @@ node.log("Master Bedroom Climate: Constants Set")
|
||||
|
||||
// Define some entity IDs
|
||||
|
||||
const masterBedroomAircon = ["climate.master_bedroom_aircon"]
|
||||
const masterBedroomFan = ["fan.master_bedroom_fan"]
|
||||
const airconEntity = ["climate.master_bedroom_aircon"]
|
||||
const fanEntity = ["fan.master_bedroom_fan"]
|
||||
const peopleIDs = ["input_boolean.tony_awake", "input_boolean.tina_awake"]
|
||||
|
||||
// Helper function to convert a string to title case
|
||||
@ -200,7 +200,7 @@ let sendFan = {
|
||||
"payload": {
|
||||
"action": `fan.${setFan}`,
|
||||
"target": {
|
||||
"entity_id": masterBedroomFan
|
||||
"entity_id": fanEntity
|
||||
},
|
||||
"data": {}
|
||||
}
|
||||
@ -264,7 +264,7 @@ let sendHvac = {
|
||||
"payload": {
|
||||
"action": "climate.set_hvac_mode",
|
||||
"target": {
|
||||
"entity_id": masterBedroomAircon
|
||||
"entity_id": airconEntity
|
||||
},
|
||||
"data": {
|
||||
"hvac_mode": setHvac
|
||||
@ -276,7 +276,7 @@ let sendTemp = {
|
||||
"payload": {
|
||||
"action": "climate.set_temperature",
|
||||
"target": {
|
||||
"entity_id": masterBedroomAircon
|
||||
"entity_id": airconEntity
|
||||
},
|
||||
"data": {
|
||||
"temperature": setTemp
|
||||
@ -298,7 +298,7 @@ let sendAcFan = {
|
||||
"payload": {
|
||||
"action": "climate.set_fan_mode",
|
||||
"target": {
|
||||
"entity_id": masterBedroomAircon
|
||||
"entity_id": airconEntity
|
||||
},
|
||||
"data": {
|
||||
"fan_mode": "auto"
|
||||
|
Reference in New Issue
Block a user