mirror of
https://github.com/jwinterm/modoboa.git
synced 2026-10-17 05:41:25 +02:00
Don't display column's name by default if not label is defined.
fixes #223
This commit is contained in:
@@ -18,9 +18,7 @@ class Qtable(tables.Table):
|
||||
|
||||
type = tables.Column(
|
||||
"type", align="center", width="30px",
|
||||
label="<input type='checkbox' name='toggleselect' id='toggleselect' />",
|
||||
sortable=False
|
||||
)
|
||||
)
|
||||
rstatus = tables.ImgColumn("rstatus", width='25px')
|
||||
from_ = tables.Column("from", label=ugettext_lazy("From"), limit=30)
|
||||
subject = tables.Column("subject", label=ugettext_lazy("Subject"), limit=40)
|
||||
|
||||
@@ -29,8 +29,8 @@ class Column(object):
|
||||
try:
|
||||
label = getattr(self, "label")
|
||||
except AttributeError:
|
||||
label = getattr(self, "name")
|
||||
return label.encode("utf-8")
|
||||
return u''
|
||||
return label
|
||||
|
||||
def transform(self, row, col, table):
|
||||
if "class" in row.keys():
|
||||
|
||||
Reference in New Issue
Block a user