Index: pykota/trunk/pykota/reporters/html.py
===================================================================
--- pykota/trunk/pykota/reporters/html.py (revision 1236)
+++ pykota/trunk/pykota/reporters/html.py (revision 1239)
@@ -22,4 +22,7 @@
 #
 # $Log$
+# Revision 1.2  2003/12/27 15:43:36  uid67467
+# Savannah is back online...
+#
 # Revision 1.1  2003/12/02 14:41:17  jalet
 # And as always, I forgot most of the new files :-)
@@ -38,19 +41,25 @@
         self.report = []
         for printer in self.printers :
-            self.report.append("<h1>%s</h1>" % self.getPrinterTitle(printer))
-            self.report.append("<h2>%s</h2>" % self.getPrinterGraceDelay(printer))
+            self.report.append('<h2 class="printername">%s</h2>' % self.getPrinterTitle(printer))
+            self.report.append('<h3 class="printergracedelay">%s</h3>' % self.getPrinterGraceDelay(printer))
             (pjob, ppage) = self.getPrinterPrices(printer)
-            self.report.append("<h3>%s</h3>" % pjob)
-            self.report.append("<h3>%s</h3>" % ppage)
+            self.report.append('<h4 class="priceperjob">%s</h4>' % pjob)
+            self.report.append('<h4 class="priceperpage">%s</h4>' % ppage)
             total = 0
             totalmoney = 0.0
-            self.report.append('<table border="1">')
+            self.report.append('<table class="pykotatable" border="1">')
             headers = self.getReportHeader().split()
-	    headers.insert(1, "LimitBy")
-            self.report.append('<tr bgcolor="gold">%s</tr>' % "".join(["<th>%s</th>" % h for h in headers]))
+            headers.insert(1, "LimitBy")
+            self.report.append('<tr class="pykotacolsheader">%s</tr>' % "".join(["<th>%s</th>" % h for h in headers]))
+            oddeven = 0
             if self.isgroup :
                 for (group, grouppquota) in self.tool.storage.getPrinterGroupsAndQuotas(printer, self.ugnames) :
+                    oddeven += 1
+                    if oddeven % 1 :
+                        oddevenclass = "odd"
+                    else :    
+                        oddevenclass = "even"
                     (pages, money, name, reached, soft, hard, balance, datelimit, lifepagecounter, lifetimepaid) = self.getQuota(group, grouppquota)
-                    self.report.append("<tr>%s</tr>" % "".join(["<td>%s</td>" % h for h in (name, reached, pagecounter, soft, hard, balance, datelimit or "&nbsp;", lifepagecounter, lifetimepaid)]))
+                    self.report.append('<tr class="%s">%s</tr>' % (oddevenclass, "".join(["<td>%s</td>" % h for h in (name, reached, pagecounter, soft, hard, balance, datelimit or "&nbsp;", lifepagecounter, lifetimepaid)])))
                     total += pages
                     totalmoney += money
@@ -58,15 +67,20 @@
                 # default is user quota report
                 for (user, userpquota) in self.tool.storage.getPrinterUsersAndQuotas(printer, self.ugnames) :
+                    oddeven += 1
+                    if oddeven % 1 :
+                        oddevenclass = "odd"
+                    else :    
+                        oddevenclass = "even"
                     (pages, money, name, reached, pagecounter, soft, hard, balance, datelimit, lifepagecounter, lifetimepaid) = self.getQuota(user, userpquota)
-                    self.report.append("<tr>%s</tr>" % "".join(["<td>%s</td>" % h for h in (name, reached, pagecounter, soft, hard, balance, datelimit or "&nbsp;", lifepagecounter, lifetimepaid)]))
+                    self.report.append('<tr class="%s">%s</tr>' % (oddevenclass, "".join(["<td>%s</td>" % h for h in (name, reached, pagecounter, soft, hard, balance, datelimit or "&nbsp;", lifepagecounter, lifetimepaid)])))
                     total += pages
                     totalmoney += money
             if total or totalmoney :        
                 (tpage, tmoney) = self.getTotals(total, totalmoney)
-                self.report.append('<tr><td colspan="7">&nbsp;</td><td align="right">%s</td><td align="right">%s</td></tr>' % (tpage, tmoney))
-            self.report.append('<tr><td colspan="7">&nbsp;</td><td align="right">%s</td></tr>' % self.getPrinterRealPageCounter(printer))
+                self.report.append('<tr class="totals"><td colspan="7">&nbsp;</td><td align="right">%s</td><td align="right">%s</td></tr>' % (tpage, tmoney))
+            self.report.append('<tr class="realpagecounter"><td colspan="7">&nbsp;</td><td align="right">%s</td></tr>' % self.getPrinterRealPageCounter(printer))
             self.report.append('</table>')
         if self.isgroup :    
-            self.report.append("<p>%s</p>" % _("Totals may be inaccurate if some users are members of several groups."))
+            self.report.append('<p class="warning">%s</p>' % _("Totals may be inaccurate if some users are members of several groups."))
         return "\n".join(self.report)    
                         
