Bugfix for showing series coatining only one book in list view containing having this book no series_index value set

This commit is contained in:
Ozzie Isaacs
2023-08-30 20:23:40 +02:00
parent fab35e69ec
commit 5509d4598b
2 changed files with 123 additions and 166 deletions

View File

@@ -1014,7 +1014,7 @@ def series_list():
func.max(db.Books.series_index), db.Books.id)
.join(db.books_series_link).join(db.Series).filter(calibre_db.common_filters())
.group_by(text('books_series_link.series'))
.having(func.max(db.Books.series_index))
.having(or_(func.max(db.Books.series_index), db.Books.series_index==""))
.order_by(order)
.all())
return render_title_template('grid.html', entries=entries, folder='web.books_list', charlist=char_list,