Revert "dashboard: support temp alert field variants"

This reverts commit 9c1f5338c7.
This commit is contained in:
2026-06-19 01:58:34 -06:00
parent f4c6623334
commit 2aac72616c
2 changed files with 2 additions and 16 deletions
@@ -1,6 +1,6 @@
#pragma once #pragma once
static const char *DASHBOARD_VERSION = "0.1.116-temp-alert-field-parsing"; static const char *DASHBOARD_VERSION = "0.1.114-websocket-roadmap";
// Update these if your Cargo ESP AP credentials are different. // Update these if your Cargo ESP AP credentials are different.
//static const char *CARGO_WIFI_SSID = "OverlandController"; //static const char *CARGO_WIFI_SSID = "OverlandController";
@@ -1464,21 +1464,7 @@ static void parse_status_json(const String &body)
} }
float temp_f = (float)(temp["temperature_f"] | 0.0); float temp_f = (float)(temp["temperature_f"] | 0.0);
bool high_alert = temp["high_alert"] | false;
bool high_alert =
(temp["high_alert"] | false) ||
(temp["alert"] | false) ||
(temp["alarm"] | false) ||
(temp["high_alarm"] | false) ||
(temp["temp_high"] | false);
if (!temp["high_threshold_f"].isNull()) {
high_alert = high_alert || temp_f >= (float)(temp["high_threshold_f"] | 9999.0);
}
if (!temp["alarm_threshold_f"].isNull()) {
high_alert = high_alert || temp_f >= (float)(temp["alarm_threshold_f"] | 9999.0);
}
if (weather) { if (weather) {
outside_status = "OUT "; outside_status = "OUT ";