added extlink icon for links that point to either PLCwww or Zabbix web pages.
authorStephen Soltesz <soltesz@cs.princeton.edu>
Fri, 5 Dec 2008 00:01:37 +0000 (00:01 +0000)
committerStephen Soltesz <soltesz@cs.princeton.edu>
Fri, 5 Dec 2008 00:01:37 +0000 (00:01 +0000)
web/MonitorWeb/monitorweb/controllers.py
web/MonitorWeb/monitorweb/static/css/style.css
web/MonitorWeb/monitorweb/static/images/extlink.gif [new file with mode: 0644]
web/MonitorWeb/monitorweb/templates/pcuview.kid

index 95d9740..9202cac 100644 (file)
@@ -152,10 +152,10 @@ class Root(controllers.RootController):
                for node in fbquery:
 
                        # NOTE: count filter
-                       if pcu.reboot_trial_status == str(0):
+                       if node.reboot_trial_status == str(0):
                                filtercount['ok'] += 1
-                       elif pcu.reboot_trial_status == 'NetDown' or pcu.reboot_trial_status == 'Not_Run':
-                               filtercount[pcu.reboot_trial_status] += 1
+                       elif node.reboot_trial_status == 'NetDown' or node.reboot_trial_status == 'Not_Run':
+                               filtercount[node.reboot_trial_status] += 1
                        else:
                                filtercount['pending'] += 1
 
index 5a6b72c..64370c6 100644 (file)
@@ -30,6 +30,14 @@ a.link, a, a.active {
   color: #369;\r
 }\r
 \r
+/*@media screen {*/\r
+ a.ext-link .icon {\r
+  background: URL(../images/extlink.gif) left center no-repeat;\r
+  padding-left: 16px;\r
+ }\r
+ /** html a.ext-link .icon { display: inline-block; }*/\r
+/*}*/\r
+\r
 #portopen     { background-color: lightgreen; }\r
 #portclosed   { background-color: indianred; }\r
 #portfiltered { background-color: gold; }\r
diff --git a/web/MonitorWeb/monitorweb/static/images/extlink.gif b/web/MonitorWeb/monitorweb/static/images/extlink.gif
new file mode 100644 (file)
index 0000000..d47e14c
Binary files /dev/null and b/web/MonitorWeb/monitorweb/static/images/extlink.gif differ
index e060b77..4946fc9 100644 (file)
@@ -32,9 +32,15 @@ def pcu_link(pcu):
                        <tbody>
                                <tr py:for="i,node in enumerate(pcuquery)" class="${i%2 and 'odd' or 'even'}" >
                                        <td></td>
-                                       <td><a href="${plc_site_link(node.plc_pcu_stats)}">${node.loginbase}</a></td>
+                                       <td><a class="ext-link" href="${plc_site_link(node.plc_pcu_stats)}">
+                                                       <span class="icon">${node.loginbase}</span>
+                                               </a>
+                                       </td>
                                        <td nowrap="true" >
-                                               <a href="${pcu_link(node.plc_pcu_stats)}">${pcu_name(node.plc_pcu_stats)}</a></td>
+                                               <a class="ext-link" href="${pcu_link(node.plc_pcu_stats)}">
+                                                       <span class="icon">${pcu_name(node.plc_pcu_stats)}</span>
+                                               </a>
+                                       </td>
                                        <td py:content="node.entry_complete"></td>
                                        <td id="dns-${node.dns_status}" py:content="node.dns_status"></td>
                                        <td>
@@ -47,9 +53,14 @@ def pcu_link(pcu):
                                </tr>
                        </tbody>
                </table>
+       <h3>Controls</h3>
+               ... node list ...
+               <br/>
+               form for reboot
+
+       <h3>Legend</h3>
 
-       <h3>Legends</h3>
-       <table border="1" align="center">
+       <table border="1" align="center" width="80%">
                <tr><th colspan="2">Legend for 'DNS Status'</th></tr>
 
                <tr><td id="dns-DNS-OK">DNS-OK</td>