Removed "from" if all variations have the same price

This commit is contained in:
Raphael Michel
2015-06-16 21:05:13 +02:00
parent 4adea8ccd0
commit 00dab77c92
2 changed files with 8 additions and 3 deletions

View File

@@ -54,6 +54,7 @@ class EventIndex(EventViewMixin, CartDisplayMixin, TemplateView):
var.price = var.get('price', item.default_price)
if len(item.available_variations) > 0:
item.min_price = min([v.price for v in item.available_variations])
item.max_price = max([v.price for v in item.available_variations])
items = [item for item in items if len(item.available_variations) > 0]