Simplify code in books.views.bulk_actions