On Aug 17, 8:06 am, Léon Dignòn <leon.dig...@gmail.com> wrote:
> Hello,
>
> I use an extended User Model and like to display these fields in the
> admin view at Auth/User. Can anybody show me how this works?
>
> Thanks
>
> -LD

Create your own admin class for your extended User model, inheriting
from the one in contrib.auth.admin. Then unregister the default one
and register yours:

from django.contrib.auth.admin import UserAdmin

class MyUserAdmin(UserAdmin(UserAdmin):
   .... extended attributes here ...

try:
    admin.site.unregister(User)
except except admin.sites.NotRegistered:
    pass
admin.site.register(User, MyUserAdmin)

--
DR.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to