Add order for shelf books to satisfy warning
I believe this will sort books by order they were added to the shelf, which seems reasonable. Should add some tests to make sure though.
This commit is contained in:
@ -281,4 +281,6 @@ class OrderedCollectionMixin(OrderedCollectionPageMixin):
|
||||
|
||||
def to_activity(self, **kwargs):
|
||||
''' an ordered collection of the specified model queryset '''
|
||||
if not self.collection_queryset.ordered:
|
||||
raise RuntimeError('collection_queryset must be ordered')
|
||||
return self.to_ordered_collection(self.collection_queryset, **kwargs)
|
||||
|
Reference in New Issue
Block a user