diff options
Diffstat (limited to 'saleor/product/templatetags/sort_by.py')
-rw-r--r-- | saleor/product/templatetags/sort_by.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/saleor/product/templatetags/sort_by.py b/saleor/product/templatetags/sort_by.py index 8b590a3e..58395c07 100644 --- a/saleor/product/templatetags/sort_by.py +++ b/saleor/product/templatetags/sort_by.py @@ -5,7 +5,7 @@ register = template.Library() @register.inclusion_tag('category/_sort_by.html', takes_context=True) def sort_by(context, attribute): - context['label'] = attribute['label'] - context['ascending_attribute'] = attribute['value'] - context['descending_attribute'] = '-' + str(attribute['value']) - return context + return {'request': context['request'], + 'label': attribute['label'], + 'ascending_attribute': attribute['value'], + 'descending_attribute': '-' + str(attribute['value'])} |