sort by name too

This commit is contained in:
Thomas Steen Rasmussen 2016-08-15 18:25:38 +02:00
parent 91610014e4
commit 5543b68bb1

View file

@ -171,7 +171,7 @@ class ShopIndexView(ListView):
def get_queryset(self):
queryset = super(ShopIndexView, self).get_queryset()
return queryset.order_by('category__name', 'price')
return queryset.order_by('category__name', 'price', 'name')
def get_context_data(self, **kwargs):
context = super(ShopIndexView, self).get_context_data(**kwargs)