entities/__init__.py
changeset 10411 4ee15441f2eb
parent 10251 2daa5c6dea4d
parent 10396 33e44293b0eb
child 10612 84468b90e9c1
child 10839 166c6f7b1be4
equal deleted inserted replaced
10410:eb681a030699 10411:4ee15441f2eb
    66         """return a suitable *unicode* title for this entity"""
    66         """return a suitable *unicode* title for this entity"""
    67         for rschema, attrschema in self.e_schema.attribute_definitions():
    67         for rschema, attrschema in self.e_schema.attribute_definitions():
    68             if rschema.meta:
    68             if rschema.meta:
    69                 continue
    69                 continue
    70             value = self.cw_attr_value(rschema.type)
    70             value = self.cw_attr_value(rschema.type)
    71             if value:
    71             if value is not None:
    72                 # make the value printable (dates, floats, bytes, etc.)
    72                 # make the value printable (dates, floats, bytes, etc.)
    73                 return self.printable_value(rschema.type, value, attrschema.type,
    73                 return self.printable_value(rschema.type, value, attrschema.type,
    74                                             format='text/plain')
    74                                             format='text/plain')
    75         return u'%s #%s' % (self.dc_type(), self.eid)
    75         return u'%s #%s' % (self.dc_type(), self.eid)
    76 
    76