This commit is contained in:
jomjol
2020-09-10 08:47:20 +02:00
parent 14705d0601
commit ac3edc9bec
4 changed files with 24 additions and 13 deletions

View File

@@ -29,7 +29,11 @@ A 3d-printable housing can be found here: https://www.thingiverse.com/thing:4571
##### Rolling - (2020-09-09)
##### Rolling - (2020-09-10)
* update ROI-configurator, in case of no ROIs defined
2020-09-10
* Update to new and modern layout (thanks to michaeljoos in iobroker-thread)
* incorporated "Take Picture" to make new reference image

View File

@@ -58,7 +58,6 @@ void doInit(void)
bool doflow(void)
{
int i;
std::string zw_time = gettimestring("%Y%m%d-%H%M%S");
printf("doflow - start %s\n", zw_time.c_str());
flowisrunning = true;
@@ -131,9 +130,8 @@ esp_err_t handler_doflow(httpd_req_t *req)
esp_err_t handler_wasserzaehler(httpd_req_t *req)
{
LogFile.WriteToFile("handler_wasserzaehler");
const char* resp_str;
string zw;
bool _rawValue = false;
string zw;
printf("handler_wasserzaehler uri:\n"); printf(req->uri); printf("\n");
@@ -213,9 +211,6 @@ esp_err_t handler_wasserzaehler(httpd_req_t *req)
esp_err_t handler_editflow(httpd_req_t *req)
{
LogFile.WriteToFile("handler_editflow");
const char* resp_str;
string zw;
bool _rawValue = false;
printf("handler_editflow uri: "); printf(req->uri); printf("\n");

View File

@@ -23,8 +23,8 @@
<table>
<tr>
<td>
<input type="submit" name="newROI" onclick="newROI()" value="New ROI (after current)">
<input type="submit" name="deleteROI" onclick="deleteROI()" value="Delete ROI">
<input type="submit" id= "newROI" name="newROI" onclick="newROI()" value="New ROI (after current)">
<input type="submit" id= "deleteROI" name="deleteROI" onclick="deleteROI()" value="Delete ROI">
</td>
</tr>
@@ -68,7 +68,7 @@
</tr>
<tr>
<td>
<input type="submit" name="saveroi" onclick="SaveToConfig()" value="Save all to Config.ini">
<input type="submit" id="saveroi" name="saveroi" onclick="SaveToConfig()" value="Save all to Config.ini">
</td>
</tr>
</table>
@@ -159,6 +159,12 @@ function SaveToConfig(){
function UpdateROIs(){
if (ROIInfo.length == 0){
alert("There are no ROIs defined.\nPlease first define minimum one ROI in the config.ini by hand.\n");
document.getElementById("newROI").disabled = true;
document.getElementById("deleteROI").disabled = true;
document.getElementById("index").disabled = true;
document.getElementById("saveroi").disabled = true;
document.getElementById("moveNext").disabled = true;
document.getElementById("movePrevious").disabled = true;
return;
}

View File

@@ -23,8 +23,8 @@
<table>
<tr>
<td>
<input type="submit" name="newROI" onclick="newROI()" value="New ROI (after current)">
<input type="submit" name="deleteROI" onclick="deleteROI()" value="Delete ROI">
<input type="submit" id="newROI" name="newROI" onclick="newROI()" value="New ROI (after current)">
<input type="submit" id="deleteROI" name="deleteROI" onclick="deleteROI()" value="Delete ROI">
</td>
</tr>
@@ -68,7 +68,7 @@
</tr>
<tr>
<td>
<input type="submit" name="saveroi" onclick="SaveToConfig()" value="Save all to Config.ini">
<input type="submit" id="saveroi" name="saveroi" onclick="SaveToConfig()" value="Save all to Config.ini">
</td>
</tr>
</table>
@@ -159,6 +159,12 @@ function SaveToConfig(){
function UpdateROIs(){
if (ROIInfo.length == 0){
alert("There are no ROIs defined.\nPlease first define minimum one ROI in the config.ini by hand.\n");
document.getElementById("newROI").disabled = true;
document.getElementById("deleteROI").disabled = true;
document.getElementById("index").disabled = true;
document.getElementById("saveroi").disabled = true;
document.getElementById("moveNext").disabled = true;
document.getElementById("movePrevious").disabled = true;
return;
}