luci-app-bmx7: fix displaying values 4554/head
authorDaniel Golle <daniel@makrotopia.org>
Thu, 29 Oct 2020 16:29:20 +0000 (17:29 +0100)
committerDaniel Golle <daniel@makrotopia.org>
Thu, 29 Oct 2020 17:03:55 +0000 (17:03 +0000)
Suggested-by: FreifunkUFO <ufo@rund.freifunk.net>
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
applications/luci-app-bmx7/root/usr/lib/lua/luci/view/admin_status/index/bmx7_nodes.htm
applications/luci-app-bmx7/root/usr/lib/lua/luci/view/bmx7/nodes_j.htm
applications/luci-app-bmx7/root/usr/lib/lua/luci/view/bmx7/status_j.htm
applications/luci-app-bmx7/root/usr/lib/lua/luci/view/bmx7/tunnels_j.htm
applications/luci-app-bmx7/root/www/cgi-bin/bmx7-info

index 8a6aefaa20564fff3249e0b800051f4f4bb1e0a3..32a3a965cef9dab11a4c7744c7733938755d4458 100644 (file)
@@ -20,7 +20,7 @@
 
 <script type="text/javascript" src="<%=resource%>/bmx7/js/polling.js"></script>
 <script type="text/javascript">//<![CDATA[
-               new TablePooler(10,"/cgi-bin/bmx7-info", {'$originators':''}, "nodes_div", function(st){
+               new TablePooler(10,"/cgi-bin/bmx7-info", {'originators':''}, "nodes_div", function(st){
                        var originators = st.originators;
                        var res = Array();
                        originators.forEach(function(originator,i){
index a631c93e89732966aa71518141d0f04f562801c5..16522b962c9d2a34b234549abe4a6a57ed87d58b 100644 (file)
@@ -92,7 +92,7 @@
                var displayExtraInfo = function ( id ) {
                        document.getElementById('extra-info').innerHTML = document.getElementById(id).innerHTML;
                }
-               new TablePooler(5,"/cgi-bin/bmx7-info", {'$originators':''}, "nodes_div", function(st){
+               new TablePooler(5,"/cgi-bin/bmx7-info", {'originators':''}, "nodes_div", function(st){
                        var infoicon = "<%=resource%>/bmx7/world_small.png";
                        var originators = st.originators;
                        var res = Array();
index 8ecae656f73c3f442b7eeb7d2c7a092389005a0d..a3249a2b14526037bb392833aab983754be29924 100644 (file)
 </div>
 
 <script type="text/javascript">//<![CDATA[
-       new TablePooler(1,"/cgi-bin/bmx7-info", {'$info':''}, "config_div", function(st){
+       new TablePooler(10,"/cgi-bin/bmx7-info", {'info':''}, "config_div", function(st){
                var res = Array();
                var sta = st.info[0].status;
                res.push([sta.shortId, sta.name, sta.primaryIp, sta.nodeKey, sta.shortDhash, sta.revision]);
                return res;
        });
 
-       new TablePooler(1,"/cgi-bin/bmx7-info", {'$info':''}, "status_div", function(st){
+       new TablePooler(10,"/cgi-bin/bmx7-info", {'info':''}, "status_div", function(st){
                var res = Array();
                var sta = st.info[0].status;
                var mem = st.info[3].memory.bmx7;
                return res;
        });
 
-       new TablePooler(1,"/cgi-bin/bmx7-info", {'$info':''}, "ifaces_div", function(st){
+       new TablePooler(10,"/cgi-bin/bmx7-info", {'info':''}, "ifaces_div", function(st){
                var res = Array();
                var ifaces = st.info[1].interfaces;
 
                return res;
        });
 
-       new TablePooler(1,"/cgi-bin/bmx7-info", {'$info':''}, "links_div", function(st){
+       new TablePooler(10,"/cgi-bin/bmx7-info", {'info':''}, "links_div", function(st){
                var res = Array();
                links = st.info[2].links;
 
index 9348e7c610606bd7bf368d1e7ca5fb89e88d9da9..0b9662df8ca354aec423b249ccac3822e0551b90 100644 (file)
@@ -51,7 +51,7 @@
 </div>
 
 <script type="text/javascript">//<![CDATA[
-               new TablePooler(5,"/cgi-bin/bmx7-info", {'$tunnels':''}, "tunnels_div", function(st){
+               new TablePooler(5,"/cgi-bin/bmx7-info", {'tunnels':''}, "tunnels_div", function(st){
         var tunicon = "<%=resource%>/icons/tunnel.png";
         var tunicon_dis = "<%=resource%>/icons/tunnel_disabled.png";
         var applyicon = "<%=resource%>/cbi/apply.gif";
index 7388ed12c37e384fadab3e5a8c969d5e2ab78a51..327e3f0f169f4c275f61d0262ac926aff02d026d 100755 (executable)
@@ -90,7 +90,7 @@ if [ "${QUERY##*/}" == "all" ]; then
        QALL=1
 fi
 
-if [ "$QUERY" == '$info' ]; then
+if [ "$QUERY" == 'info' ]; then
        echo '{ "info": [ '
        print_query status
        echo -n ","
@@ -100,7 +100,7 @@ if [ "$QUERY" == '$info' ]; then
        echo "] }"
 fi
 
-if [ "$QUERY" == '$neighbours' ]; then
+if [ "$QUERY" == 'neighbours' ]; then
        QALL=1
        echo '{ "neighbours": [ '
        echo '{ "originators": '
@@ -111,11 +111,11 @@ if [ "$QUERY" == '$neighbours' ]; then
        echo "} ] }"
        exit 0
 
-else if [ "$QUERY" == '$tunnels' ]; then
+else if [ "$QUERY" == 'tunnels' ]; then
        bmx7 -c --jshow tunnels /r=0
        exit 0
 
-       else if [ "$QUERY" == '$originators' ]; then
+       else if [ "$QUERY" == 'originators' ]; then
                bmx7 -c --jshow originators /r=0
                exit 0