Hi,
i created an extended admin User and modified the fieldsets for the admin interface. Everything works fine, BUT how can i get the groupselection and permission fields in my admin interface?
I hope you have a short hint.
Additional Question: When i have an inline element with meta option "extra" - how can i switch of the "#1", "#2" numbers displayed in my admin interface?
Greets Dominik
--from django.contrib import adminfrom django.contrib.auth.admin import UserAdmin, GroupAdminfrom django.contrib.auth.models import User, Groupfrom members.models import Memberclass MemberInline(admin.StackedInline):model = Membercan_delete = Falseverbose_name_plural = 'Adresse'fieldsets = ((None, {'fields':('street','zipcode','city','phone','avatar')}),('Mitgliedschaft', {'fields': ('newsletter','member_since')}),)extra = 1class MyUserAdmin(UserAdmin):list_display = ('username','email','first_name','last_name')list_filter =()fieldsets = ((None, {'fields': ('username','first_name','last_name','email','password')}),)inlines = [MemberInline]admin.site.unregister(User)admin.site.register(User, MyUserAdmin)
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?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
No comments:
Post a Comment