Thursday, July 23, 2015

Re: Why is Admin login template at admin/login.html instead of registration/login.html?

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBCAAGBQJVsSNFAAoJEC0ft5FqUuEhMRIQAIyLrOWUguxLpdwosnB7acP/
TyCKXtIZTWU2zEYmYBRZLJadhOGVdag7KSJMe+U19MXipgdFhGPlu0FMVNxTZ9IO
l0TpdBhSCRLVbS9OR5m4vq7/Wh8Cf4tetBhbeMYQzsDM1RaQe7faDBG3sqpiYtro
EZsvWo+Uxlf3h+wyCT3fn5Y22lUredBh0Vuwcw/U2up0gN4Q+XtOChAElj20TSDl
vQOW7EW9WWcmEpxQNjtTFSWITHC3aa1JWUON7giXDEJlkT3Yg+gS7Sjd4vcgv1UU
AAOztoLRIXdLtlfx0jHCnqgllLGEOCdBADfSMfnZneQAKrb3fQXeyqMXemnIzOKd
/sOeYXDAyC8rUdxYQQp2ifBfSVwg9FRmHETmqgTsEUFEvfqK+fw88O/fIQRm3eN0
irgUhfscqBiQ8LuLsT3lOcVZ45jAwQDmr09oj1J2xpvew/M2Ep3gXSToK76w2HZO
1oQRibZlCh9Csa9sYI1ED/xlgX0U6OWeMgMtXmErQ6YuLYJ12WU1fphBiV/I1dVu
bgHSGHyAxmqck54aIbAsYiRmUZlhRbftP4YHb7TXgLOdisffdClRzXT8LXYS82l+
Gs0mxOoV6WqhYmD0YTVuk5AW7hcfQ9V98PT3xkV1U4dDHKTeRHusJVhWenofPT7k
XDJ55J0wZXU45eqA/m7T
=YMzj
-----END PGP SIGNATURE-----
On 07/23/2015 10:49 AM, Tim Graham wrote:
> The admin login only allows staff users to login so it makes sense to me
> that if you wanted to add regular user login to your site, it should
> have separate URLs.
>
> As for the template issue, it seems to me the
> admin/template/registration templates should be more like
> admin/login.html and namespaced under admin so that if you want to
> implement a non-admin password reset, you don't have a conflict in the
> template names (see the ticket below for an example).
>
> https://code.djangoproject.com/ticket/20372

I agree. The auth views expose the option to pass a different template
name. I think the admin should have its own templates namespaced under
`admin/` and pass those template names to the views, rather than
overriding the default auth templates.

Carl

--
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+unsubscribe@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/55B12345.1060908%40oddbird.net.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment