Re: FormMixin success_url should accept callable

2012-04-08 Thread Andrew Ingram
Hi Martin, There are (as of Django 1.4) already two solutions to this: 1 - override get_success_url(). the default behaviour of this method is to just return self.success_urll, but obviously it can be modified to return whatever you like 2 - use reverse_lazy (Django 1.4) instead of reverse

FormMixin success_url should accept callable

2012-04-08 Thread Martin Tiršel
Hello, I just started to use class based views and I came to the CreateView and success_url argument. This argument has to be string what leads to typing URLs in views instead of using reverse() function (you have no access to urls through reverese() in view initialization). I think (if