missing import; use reverse_lazy

This commit is contained in:
Thomas Steen Rasmussen 2016-05-16 17:11:07 +02:00
parent db597a4a36
commit ba01e103a3

View file

@ -4,6 +4,7 @@ from django.contrib.postgres.fields import DateTimeRangeField, JSONField
from django.utils.text import slugify
from django.utils.translation import ugettext_lazy as _
from django.utils import timezone
from django.core.urlresolvers import reverse_lazy
from bornhack.utils import CreatedUpdatedModel, UUIDModel
from .managers import ProductQuerySet
@ -85,7 +86,7 @@ class Order(CreatedUpdatedModel):
)['sum']
def get_absolute_url(self):
return reverse('order_detail', kwargs={'pk': self.pk})
return reverse_lazy('order_detail', kwargs={'pk': self.pk})
class ProductCategory(CreatedUpdatedModel, UUIDModel):