]> git.phdru.name Git - m_librarian.git/blobdiff - m_librarian/db.py
Feat(db): Add book.author_list property
[m_librarian.git] / m_librarian / db.py
index 9081a422e0389b0da6f60c7cb94487b8ca3ed061..0350aaed08218525160589058d34c47b42b48483 100755 (executable)
@@ -76,6 +76,10 @@ class Book(SQLObject):
     def author1(self):
         return self.authors[0].fullname
 
+    @property
+    def author_list(self):
+        return u', '.join([a.fullname for a in self.authors])
+
 
 class BookGenre(SQLObject):
     class sqlmeta: