Stylize the results box a bit more so it's more visible.
[invirt/packages/invirt-web.git] / code / templates / list.mako
index c3167cb..90953f0 100644 (file)
@@ -80,8 +80,12 @@ ${self.fn.cdromList(defaults.cdrom, "$('cd_or_auto_cd').checked = true;$('autoin
 % endif
 </%def>
 
-<%def name="machineRow(machine)">
-      <tr> 
+<%def name="machineRow(machine, dark)">
+      <tr\
+% if dark:
+ class="stripedrow" \
+% endif
+> 
        <td rowspan="2">
        % if machine.uptime and installing[machine]:
        <img src="static/power_installing.png" alt="Installing..." />
@@ -122,7 +126,11 @@ ${has_vnc[machine]}
 % endif
 </td>
       </tr>
-      <tr>
+      <tr\
+% if dark:
+ class="stripedrow" \
+% endif
+>
         <td colspan="7" style="padding-left: 1em; color: #666">${machine.description|self.fn.module.nl2br}</td>
       </tr>
 </%def>
@@ -139,17 +147,10 @@ ${has_vnc[machine]}
        <th>Uptime</th>
        <th>VNC</th>
       </tr>
-% for machine in machines:
-       ${machineRow(machine)}
+% for n, machine in enumerate(machines):
+       ${machineRow(machine, (n%2)==0)}
 % endfor
     </table>
-    <script type="text/javascript" src="/static/stripe.js"></script>
-    <script type="text/javascript">
-        document.observe("dom:loaded", function() {
-            stripe($('machinelist').getElementsByTagName('table')[0],
-                   'stripedrow');
-        });
-    </script>
 </%def>
 
 <p style="font-size: 125%;"><a href="http://${config.web.hostname}">What is XVM?</a></p>