Change html layout

Signed-off-by: Thomas Klaehn <thomas.klaehn@perinet.io>
This commit is contained in:
Thomas Klaehn 2022-03-30 16:53:47 +02:00
parent 0bdcc5a14b
commit 6ebf407e43
3 changed files with 39 additions and 41 deletions

View File

@ -64,7 +64,7 @@ def draw_temperature_image():
color = "#b6b6b6" color = "#b6b6b6"
fig, ax = plt.subplots(1) fig, ax = plt.subplots(1)
fig.set_figwidth(4) fig.set_figwidth(5.5)
fig.set_figheight(2) fig.set_figheight(2)
fig.set_facecolor(background_color) fig.set_facecolor(background_color)

View File

@ -106,7 +106,8 @@ var parse_config = function (event) {
document.getElementById("heat_switch_label").style.visibility = visibility_heat document.getElementById("heat_switch_label").style.visibility = visibility_heat
document.getElementById("heat_switch").style.visibility = visibility_heat document.getElementById("heat_switch").style.visibility = visibility_heat
document.getElementById("heat_auto_switch").value = output; document.getElementById("heat_auto_switch").value = output;
document.getElementById("config_temperatures").style.visibility = visibility document.getElementById("config_temperatures_on").style.visibility = visibility
document.getElementById("config_temperatures_off").style.visibility = visibility
} }
output = "einschalten" output = "einschalten"
visibility = 'hidden' visibility = 'hidden'
@ -124,7 +125,8 @@ var parse_config = function (event) {
document.getElementById("water_switch_label").style.visibility = visibility_water document.getElementById("water_switch_label").style.visibility = visibility_water
document.getElementById("water_switch").style.visibility = visibility_water document.getElementById("water_switch").style.visibility = visibility_water
document.getElementById("water_auto_switch").value = output; document.getElementById("water_auto_switch").value = output;
document.getElementById("water_times").style.visibility = visibility document.getElementById("config_times_before_noon").style.visibility = visibility
document.getElementById("config_times_afternoon").style.visibility = visibility
} }
} }

View File

@ -9,7 +9,6 @@
<body> <body>
<h1>Gewächshaus</h1> <h1>Gewächshaus</h1>
<hr>
<table class="center"> <table class="center">
<tr> <tr>
<td><h3>Temperatur </h3></td> <td><h3>Temperatur </h3></td>
@ -34,50 +33,47 @@
<input id="heat_auto_switch" type="submit" value="" onclick="on_switch_heat_autostate()"></input> <input id="heat_auto_switch" type="submit" value="" onclick="on_switch_heat_autostate()"></input>
</td> </td>
</tr> </tr>
</table> <tr id="config_temperatures_on" style="visibility: hidden;">
</div> <td class="table_left">Einschalttemperatur</td>
<div id="config_temperatures" style="visibility:hidden;"> <td>
<table class="center"> <table class="center">
<tr> <td class="input">
<td>Einschalttemperatur</td> <input id="decrease_on_temperature" type="submit" value="-" onclick="on_decrease_on_temperature()"></input>
<td class="input"> </td>
<input id="decrease_on_temperature" type="submit" value="-" onclick="on_decrease_on_temperature()"></input> <td id="on_temperature"></td>
<td class="input">
<input id="increase_on_temperature" type="submit" value="+" onclick="on_increase_on_temperature()"></input>
</td>
</table>
</td> </td>
<td id="on_temperature"></td> </tr>
<td class="input"> <tr id="config_temperatures_off" style="visibility: hidden;">
<input id="increase_on_temperature" type="submit" value="+" onclick="on_increase_on_temperature()"></input> <td class="table_left">Ausschalttemperatur</td>
<td>
<table class="center">
<td class="input">
<input id="decrease_off_temperature" type="submit" value="-" onclick="on_decrease_off_temperature()"></input>
</td>
<td id="off_temperature"></td>
<td class="input">
<input id="increase_off_temperature" type="submit" value="+" onclick="on_increase_off_temperature()"></input>
</td>
</table>
</td> </td>
</tr> </tr>
<tr> <tr>
<td>Ausschalttemperatur</td> <td class="table_left" id="water_switch_label" style="visibility: hidden;">Bewässerung</td>
<td class="input"> <td class="input">
<input id="decrease_off_temperature" type="submit" value="-" onclick="on_decrease_off_temperature()"></input> <input id="water_switch" style="visibility: hidden;" type="submit" value="" onclick="on_switch_water()"></input>
</td>
<td id="off_temperature"></td>
<td class="input">
<input id="increase_off_temperature" type="submit" value="+" onclick="on_increase_off_temperature()"></input>
</td> </td>
</tr> </tr>
</table>
</div>
<hr>
<table class="center">
<tr>
<td class="table_left" id="water_switch_label" style="visibility: hidden;">Bewässerung</td>
<td class="input">
<input id="water_switch" style="visibility: hidden;" type="submit" value="" onclick="on_switch_water()"></input>
</td>
</tr>
<tr>
<td class="table_left">Zeigesteuerte Bewässerung </td>
<td class="input">
<input id="water_auto_switch" type="submit" value="" onclick="on_switch_water_auto_state()"></input>
</td>
</tr>
</table>
<div id="water_times" style="visibility:hidden;">
<table class="center">
<tr> <tr>
<td class="table_left">Zeigesteuerte Bewässerung </td>
<td class="input">
<input id="water_auto_switch" type="submit" value="" onclick="on_switch_water_auto_state()"></input>
</td>
</tr>
<tr id="config_times_before_noon" style="visibility: hidden;">
<td>Vormittag</td> <td>Vormittag</td>
<td> <td>
<table> <table>
@ -96,7 +92,7 @@
</table> </table>
</td> </td>
</tr> </tr>
<tr> <tr id="config_times_afternoon" style="visibility: hidden;">
<td>Nachmittag</td> <td>Nachmittag</td>
<td> <td>
<table> <table>