greater flexibility for row customization by using css

This commit is contained in:
Paolo Caruccio
2014-02-06 16:25:42 +01:00
parent 4c3ab339cd
commit ff17b551b4
+4 -2
View File
@@ -2914,6 +2914,8 @@ class SQLTABLE(TABLE):
renderstyle=False, renderstyle=False,
cid=None, cid=None,
colgroup=False, colgroup=False,
even_row_cls='even',
odd_row_cls='odd',
**attributes **attributes
): ):
@@ -2978,9 +2980,9 @@ class SQLTABLE(TABLE):
for (rc, record) in enumerate(sqlrows): for (rc, record) in enumerate(sqlrows):
row = [] row = []
if rc % 2 == 0: if rc % 2 == 0:
_class = 'even' _class = even_row_cls
else: else:
_class = 'odd' _class = odd_row_cls
if not selectid is None: # new implement if not selectid is None: # new implement
if record.get('id') == selectid: if record.get('id') == selectid: