common/uilib.py
branchstable
changeset 4247 b1d79216d930
parent 4212 ab6573088b4a
child 4252 6c4f109c2b03
equal deleted inserted replaced
4246:c95b8c7e5fb2 4247:b1d79216d930
    37         return u''
    37         return u''
    38     if attrtype == 'String':
    38     if attrtype == 'String':
    39         # don't translate empty value if you don't want strange results
    39         # don't translate empty value if you don't want strange results
    40         if props is not None and value and props.get('internationalizable'):
    40         if props is not None and value and props.get('internationalizable'):
    41             return req._(value)
    41             return req._(value)
    42 
       
    43         return value
    42         return value
    44     if attrtype == 'Date':
    43     if attrtype == 'Date':
    45         return ustrftime(value, req.property_value('ui.date-format'))
    44         return ustrftime(value, req.property_value('ui.date-format'))
    46     if attrtype == 'Time':
    45     if attrtype == 'Time':
    47         return ustrftime(value, req.property_value('ui.time-format'))
    46         return ustrftime(value, req.property_value('ui.time-format'))