Procházet zdrojové kódy

Cleanup web UI (#2378)

* fix wrong index on backup log

* remove no longer used files/functions

* improve logging on Alignment Mark Update

---------

Co-authored-by: CaCO3 <caco@ruinelli.ch>
CaCO3 před 2 roky
rodič
revize
9a07f271ff

+ 1 - 1
sd-card/html/backup.html

@@ -105,7 +105,7 @@ function fetchFiles(urls, filesData, index, retry, zipFilename) {
 
 //    console.log(url + " started (" + index + "/" + urls.length + ")");
     if (retry == 0) {
-        setStatus("&nbsp;- " + getFilenameFromUrl(urls[index]) + " (" + index + "/" + urls.length + ")...");
+        setStatus("&nbsp;- " + getFilenameFromUrl(urls[index]) + " (" + (index+1) + "/" + urls.length + ")...");
     }
     else {
         setStatus("<span style=\"color: gray\">&nbsp;&nbsp;&nbsp;Retrying (" + retry + ")...</span>");

+ 1 - 7
sd-card/html/common.js

@@ -1,13 +1,7 @@
  
 /* The UI can also be run locally, but you have to set the IP of your devide accordingly.
  * And you also might have to disable CORS in your webbrowser! */
-var domainname_for_testing = "192.168.178.23";
-
-
-
-function gethost_Version(){
-    return "1.0.0 - 20200910";
-}
+var domainname_for_testing = "192.168.1.153";
 
 
 /* Returns the domainname with prepended protocol.

+ 0 - 41
sd-card/html/gethost.js

@@ -1,41 +0,0 @@
-
-function gethost_Version(){
-    return "1.0.0 - 20200910";
-}
-
-
-function getbasepath(){
-    var host = window.location.hostname;
-    if (((host == "127.0.0.1") || (host == "localhost") || (host == "")) 
-//       && ((window.location.port == "80") || (window.location.port == ""))
-       )
-    
-    {
-//        host = "http://192.168.2.219";          // jomjol interner test
-//        host = "http://192.168.178.46";          // jomjol interner test
-        host = "http://192.168.178.44";          // jomjol interner Real
-//        host = "http://192.168.43.191";
-//        host = ".";                           // jomjol interner localhost   
-
-    }
-    else
-    {
-        host = window.location.protocol + "//" + host;
-        if (window.location.port != "") {
-            host = host + ":" + window.location.port;
-        }
-    }
-
-    return host;
-}
-
-function UpdatePage(_dosession = true){
-    var zw = location.href;
-    zw = zw.substr(0, zw.indexOf("?"));
-    if (_dosession) {
-        window.location = zw + '?session=' + Math.floor((Math.random() * 1000000) + 1); 
-    }
-    else {
-        window.location = zw; 
-    }
-}

+ 2 - 2
sd-card/html/readconfigcommon.js

@@ -264,7 +264,7 @@ function MakeContrastImageZW(zw, _enhance, _domainname){
           return true;
      }
      else {
-          firework.launch("Device is busy, please try again when the round got completed!", 'warning', 10000);
+          firework.launch("Device is busy, please try again when the Digitalization Round got completed!", 'warning', 10000);
           return false;
      }
 }
@@ -293,7 +293,7 @@ function MakeRefZW(zw, _domainname){
           return true;
      }
      else {
-          firework.launch("Device is busy, please try again when the round got completed!", 'warning', 10000);
+          firework.launch("Device is busy, please try again when the Digitalization Round got completed!", 'warning', 10000);
           return false;
      }
 }

+ 1 - 0
sd-card/html/wlan_config.html

@@ -3,6 +3,7 @@
         <link href="firework.css?v=$COMMIT_HASH" rel="stylesheet">
         <script type="text/javascript" src="jquery-3.6.0.min.js?v=$COMMIT_HASH"></script>  
         <script type="text/javascript" src="firework.js?v=$COMMIT_HASH"></script>
+        <script type="text/javascript" src="/common.js?v=$COMMIT_HASH"> 
     </head>
 <body>
     <table>