]> git.phdru.name Git - m_librarian.git/blobdiff - m_librarian/wx/ListAuthors.py
Feat(wx/books): List books for an author
[m_librarian.git] / m_librarian / wx / ListAuthors.py
index 96f5e8ba56e942bf8977adc2c8beda5b5097a3f4..15cb59cf3c45c6054a7d9234745c6631b02bf557 100644 (file)
@@ -2,6 +2,7 @@
 
 import wx, wx.grid  # noqa: E401 multiple imports on one line
 from ..compat import string_type, unicode_type
+from ..search import books_by_author
 from ..translations import translations
 from .AWindow import AWindow
 from .ListBooks import ListBooksWindow
@@ -67,7 +68,8 @@ class ListAuthorsPanel(wx.Panel):
     def listBooks(self, row):
         authors = self.search_authors_results['authors']
         author = authors[row]
-        ListBooksWindow(self, author)
+        _books_by_author = books_by_author(author.id)
+        ListBooksWindow(self, _books_by_author)
 
     def OnDClick(self, event):
         row = event.GetRow()