From 8fd4f08ae0992e3c092f77905de53462ae0b93f9 Mon Sep 17 00:00:00 2001 From: Marcio Mazza Date: Wed, 16 Mar 2016 19:04:44 -0300 Subject: [PATCH] Usa app_name como namespace no crud --- crud/base.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/crud/base.py b/crud/base.py index cfb223d6d..48bcb1e62 100644 --- a/crud/base.py +++ b/crud/base.py @@ -63,7 +63,9 @@ class BaseMixin(CrispyLayoutFormMixin): return '%s_%s' % (cls.model._meta.model_name, suffix) def resolve_url(self, suffix, args=None): - return reverse(self.url_name(suffix), args=args) + namespace = self.model._meta.app_label + return reverse('%s:%s' % (namespace, self.url_name(suffix)), + args=args) @property def list_url(self):