final books on shelf fix, start out by title, so books not in series are by title (and those in and out of series are by title until a series is reached, then its by series number until the series is finished, then back to title)
This commit is contained in:
8
main.py
8
main.py
@@ -814,8 +814,12 @@ def rem_parent_books_from_series(pid):
|
||||
@app.route("/books_on_shelf", methods=["GET"])
|
||||
@login_required
|
||||
def books_on_shelf():
|
||||
# start with all books owned, but it includes sub-books, so remove them...
|
||||
books = Book.query.join(Owned).filter(Owned.name=='Currently Owned').all()
|
||||
# start with basic sort by title (we will sort by author at the end) in javascript,
|
||||
# also re-order this list to deal with series ordering - this will leave overall sort by
|
||||
# author, title & the moment we hit a series, the rest of those books are ordered by series
|
||||
|
||||
# start with all books owned by title, but it includes sub-books, so remove them...
|
||||
books = Book.query.join(Owned).filter(Owned.name=='Currently Owned').order_by(Book.title).all()
|
||||
RemSubs(books)
|
||||
|
||||
# because a book can be in multiple series, without any ordering we need to find
|
||||
|
||||
Reference in New Issue
Block a user