add: default styles
This commit is contained in:
parent
a41a541baf
commit
0a1ba00684
1 changed files with 4 additions and 2 deletions
|
@ -25,7 +25,7 @@ from zope import component
|
|||
from zope.i18n.locales import locales
|
||||
from zope.schema.interfaces import IVocabularyFactory, IContextSourceBinder
|
||||
|
||||
from cybertools.composer.report.field import Field
|
||||
from cybertools.composer.report.field import Field, TableCellStyle
|
||||
from cybertools.composer.report.result import ResultSet
|
||||
from cybertools.util.date import timeStamp2Date
|
||||
from loops.common import baseObject
|
||||
|
@ -47,7 +47,9 @@ class DecimalField(Field):
|
|||
format = 'decimal'
|
||||
pattern = u'#,##0.00;-#,##0.00'
|
||||
renderer = 'right'
|
||||
style = {'text-align':'right'}
|
||||
styleData = {'text-align':'right'}
|
||||
decimalStyleData = dict(Field.style.data, **styleData)
|
||||
style = TableCellStyle(**decimalStyleData)
|
||||
|
||||
def getDisplayValue(self, row):
|
||||
value = self.getRawValue(row)
|
||||
|
|
Loading…
Add table
Reference in a new issue