I've been adding #tags to my auth urls to redirect traffic after signups 
and resets. This keeps most of the routing intact, but gives you a hook to 
redirect on in a later stage.
However, I'm not using django-registration so I can't give you any examples.

On Friday, September 5, 2014 11:23:54 PM UTC+2, Lee Hinde wrote:
>
> I have three primary levels of access in my project.
>
> The public at /  
> Instructors at /instructor/
> Staff at /staff/
>
> The issue is with the password reset process.
>
> If someone comes to /instructor/ and then goes through the password reset 
> process I want them to end up at /instructor/ when they're done. Currently 
> I've got everyone going to 
> / because I'd rather confuse staff and instructors than the public.  
>
> I'm not sure how to carry their original intended url / level through to 
> the end of the reset process. I am loath to touch contrib.auth.views.py 
> for fear of introducing some obscure, or not so obscure, bug.  Users can be 
> authorized to all three levels so monitoring their user level doesn't work.
>
> I'm using django registration, hence registration/auth_urls.py and it 
> occurred to me to just duplicate (or triplicate) the pertinent urls so that 
> password/reset/complete/ becomes instructor/password/reset/complete/ and I 
> could pass the appropriate next url to extra_context. But that doesn't seem 
> very DRY so I thought I'd check in here to see if there was a better way.
>
> Thanks.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/a8aed0ee-21e3-4bdd-ada3-cecf332ae876%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to