database access for rooms and mqtt client + generator

This commit is contained in:
2025-12-09 09:07:07 +01:00
parent 75f4b7e1eb
commit 0a7b029141
16 changed files with 486 additions and 96 deletions

View File

@@ -1,19 +1,30 @@
function tableSearch(){
var table, input, tr, td, row_content;
table = document.getElementById("tableRooms");
input = document.getElementById("tableRoomSearch").value.toUpperCase();
tr = table.getElementsByTagName("tr");
var table, input, tr, td, row_content;
table = document.getElementById("tableRooms");
input = document.getElementById("tableRoomSearch").value.toUpperCase();
tr = table.getElementsByTagName("tr");
for (let i = 0; i < tr.length; i++) {
td = tr[i].getElementsByTagName("td")[0];
if(td){
row_content = td.textContent || td.innerText;
if (row_content.toUpperCase().indexOf(input) > -1) {
tr[i].style.display = "";
}
else{
tr[i].style.display ="none";
}
}
for (let i = 0; i < tr.length; i++) {
td = tr[i].getElementsByTagName("td")[0];
if(td){
row_content = td.textContent || td.innerText;
if (row_content.toUpperCase().indexOf(input) > -1) {
tr[i].style.display = "";
}
}
else{
tr[i].style.display ="none";
}
}
}
}
function toggleRoomDropdown() {
document.getElementById("rooms-unrolled").style.display = "inline";
document.getElementById("rooms-rolled").style.display = "none";
}
function untoggleRoomDropdown() {
document.getElementById("rooms-rolled").style.display = "inline";
document.getElementById("rooms-unrolled").style.display = "none";
}

View File

@@ -90,3 +90,9 @@ tbody tr{
.rooms-table input{
width: 90%;
}
.current-readings .data-valid,
.current-readings .data-late,
.current-readings .data-missing{
padding: 0.2em 1em;
}