mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-02-03 20:45:00 +01:00
Add custom fields to the 'unicode' function
This commit is contained in:
parent
4130ba18f6
commit
6bad998546
1 changed files with 5 additions and 1 deletions
|
|
@ -338,7 +338,11 @@ def fmt(x, y):
|
|||
fmt('Published', isoformat(self.pubdate))
|
||||
if self.rights is not None:
|
||||
fmt('Rights', unicode(self.rights))
|
||||
# TODO: NEWMETA: What to do about custom fields?
|
||||
for key in self.user_metadata_keys:
|
||||
val = self.get(key, None)
|
||||
if val is not None:
|
||||
(name, val) = self.format_custom_field(key)
|
||||
fmt(name, unicode(val))
|
||||
return u'\n'.join(ans)
|
||||
|
||||
def to_html(self):
|
||||
|
|
|
|||
Loading…
Reference in a new issue