1
0
mirror of https://github.com/beestat/app.git synced 2026-05-13 10:52:29 -04:00

Mostly migrated from heat_auxiliary to auxiliary_heat naming convention for #331

This commit is contained in:
Jon Ziebell
2021-02-20 21:43:51 -05:00
parent 808fc3580f
commit 5fffa7686a
4 changed files with 33 additions and 9 deletions
+2 -2
View File
@@ -49,7 +49,7 @@ class thermostat extends cora\crud {
$generated_columns = [];
if(isset($attributes['system_type2']) === true) {
foreach(['heat', 'heat_auxiliary', 'cool'] as $mode) {
foreach(['heat', 'heat_auxiliary', 'auxiliary_heat', 'cool'] as $mode) {
if($attributes['system_type2']['reported'][$mode]['equipment'] !== null) {
$generated_columns['system_type_' . $mode] = $attributes['system_type2']['reported'][$mode]['equipment'];
} else {
@@ -104,7 +104,7 @@ class thermostat extends cora\crud {
$thermostat = $this->get($thermostat_id);
foreach($system_types as $system_type => $value) {
if(in_array($system_type, ['heat', 'heat_auxiliary', 'cool']) === true) {
if(in_array($system_type, ['heat', 'heat_auxiliary', 'auxiliary_heat', 'cool']) === true) {
$thermostat['system_type2']['reported'][$system_type]['equipment'] = $value;
}
}