Skip to content

Commit 215d9fd

Browse files
committed
- Changed: Alert sensor, removed level notation in user interface
1 parent 55df2c9 commit 215d9fd

File tree

6 files changed

+10
-11
lines changed

6 files changed

+10
-11
lines changed

History.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ Version 2.3xxx
3030
- Implemented: Waterflow sensor
3131
- Implemented: Wind Beaufort scale
3232
- Implemented: Wind Graph, option to delete a short-log data point
33+
- Changed: Alert sensor, removed level notation in user interface
3334
- Changed: EventSystem, don't process unused devices
3435
- Changed: Fritzbox, Now updating text sensor on connect/disconnect
3536
- Changed: OpenZWave, Control Panel log starts displaying from the end when entering for the first time

main/WebServer.cpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9444,12 +9444,10 @@ namespace http {
94449444
}
94459445
else if (dSubType == sTypeAlert)
94469446
{
9447-
sprintf(szData, "Level: %d", nValue);
9448-
root["result"][ii]["Data"] = szData;
94499447
if (!sValue.empty())
9450-
root["result"][ii]["Desc"] = sValue;
9448+
root["result"][ii]["Data"] = sValue;
94519449
else
9452-
root["result"][ii]["Desc"] = Get_Alert_Desc(nValue);
9450+
root["result"][ii]["Data"] = Get_Alert_Desc(nValue);
94539451
root["result"][ii]["TypeImg"] = "Alert";
94549452
root["result"][ii]["Level"] = nValue;
94559453
root["result"][ii]["HaveTimeout"] = false;

www/app/DashboardController.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1310,7 +1310,7 @@ define(['app'], function (app) {
13101310
}
13111311
}
13121312
else if (item.SubType=="Alert") {
1313-
status=item.Data + " (" + item.Desc + ")" + ' <img src="images/Alert48_' + item.Level + '.png" height="16" width="16">';
1313+
status=item.Data + ' <img src="images/Alert48_' + item.Level + '.png" height="16" width="16">';
13141314
}
13151315
else if ((item.Type == "Thermostat")&&(item.SubType=="SetPoint")) {
13161316
status+=item.Data + '\u00B0 ' + $scope.config.TempSign;
@@ -1391,7 +1391,7 @@ define(['app'], function (app) {
13911391
status=item.Data;
13921392
}
13931393
else if (item.SubType=="Alert") {
1394-
status=item.Data + " (" + item.Desc + ")";
1394+
status=item.Data;
13951395
img='<img src="images/Alert48_' + item.Level + '.png" height="40" width="40">';
13961396
}
13971397
else if (item.Type == "Lux") {
@@ -3179,7 +3179,7 @@ define(['app'], function (app) {
31793179
}
31803180
}
31813181
else if (item.SubType=="Alert") {
3182-
status=item.Data + " (" + item.Desc + ")" + ' <img src="images/Alert48_' + item.Level + '.png" height="16" width="16">';
3182+
status=item.Data + ' <img src="images/Alert48_' + item.Level + '.png" height="16" width="16">';
31833183
}
31843184
else if ((item.Type == "Thermostat")&&(item.SubType=="SetPoint")) {
31853185
status=' <button class="btn btn-mini btn-info" type="button" onclick="ShowSetpointPopup(event, ' + item.idx + ', ShowFavorites, ' + item.Protected + ', ' + item.Data + ',true);">' + item.Data + '\u00B0 ' + $scope.config.TempSign +'</button> ';
@@ -3383,7 +3383,7 @@ define(['app'], function (app) {
33833383
}
33843384
else if (item.SubType=="Alert") {
33853385
xhtm+='Alert48_' + item.Level + '.png" class="lcursor" onclick="ShowTextLog(\'#dashcontent\',\'ShowFavorites\',' + item.idx + ',\'' + escape(item.Name) + '\');" height="40" width="40"></td>\n';
3386-
status=item.Data + " (" + item.Desc + ")";
3386+
status=item.Data;
33873387
}
33883388
else if (item.SubType=="Pressure") {
33893389
xhtm+='gauge48.png" class="lcursor" onclick="ShowGeneralGraph(\'#dashcontent\',\'ShowFavorites\',' + item.idx + ',\'' + escape(item.Name) + '\',' + item.SwitchTypeVal +', \'' + item.SubType + '\');" height="40" width="40"></td>\n';

www/app/UtilityController.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -726,7 +726,7 @@ define(['app'], function (app) {
726726
status=item.Data;
727727
}
728728
else if (item.SubType == "Alert") {
729-
status=item.Data + " (" + item.Desc + ")";
729+
status=item.Data;
730730
img='<img src="images/Alert48_' + item.Level + '.png" height="48" width="48">';
731731
}
732732
else if (item.Type == "Lux") {
@@ -1065,7 +1065,7 @@ define(['app'], function (app) {
10651065
}
10661066
else if (item.SubType == "Alert") {
10671067
xhtm+='Alert48_' + item.Level + '.png" height="48" width="48"></td>\n';
1068-
status=item.Data + " (" + item.Desc + ")";
1068+
status=item.Data;
10691069
}
10701070
else if (item.SubType == "Pressure") {
10711071
xhtm+='gauge48.png" height="48" width="48"></td>\n';

www/html5.appcache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
CACHE MANIFEST
2-
# ref 1173
2+
# ref 1175
33

44
CACHE:
55
# CSS

www/js/domoticzdevices.js.gz

-54 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)