* ui_ux: => 0
* easy: => 0
* stage: Design decision needed => Accepted
Comment:
Accepting that there should be a cleaner API for interacting with the
registry. However the third point ("provide methods to update common
`ModelAdmin` options") doesn't seem so useful.
--
Ticket URL: <https://code.djangoproject.com/ticket/9602#comment:3>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* status: new => assigned
* needs_tests: 0 => 1
* easy: 0 => 1
* owner: nobody => anonymous
* needs_docs: 0 => 1
* has_patch: 0 => 1
Comment:
useradmin = admin.site._registry.get(User, None)
if useradmin:
useradmin.list_display = useradmin.list_display + ('is_superuser',)
else:
class MyUserAdmin(AuthUserAdmin):
list_display = ('username', 'email', 'first_name', 'last_name',
'is_staff', 'is_superuser')
admin.site.register(User, MyUserAdmin)
--
Ticket URL: <https://code.djangoproject.com/ticket/9602#comment:4>
* needs_docs: 1 => 0
* has_patch: 1 => 0
* version: 1.0 => master
* easy: 1 => 0
* needs_tests: 1 => 0
--
Ticket URL: <https://code.djangoproject.com/ticket/9602#comment:5>
* owner: anonymous => Mariusz Felisiak
* has_patch: 0 => 1
Comment:
[https://github.com/django/django/pull/17049 PR]
--
Ticket URL: <https://code.djangoproject.com/ticket/9602#comment:6>
* status: assigned => closed
* resolution: => fixed
Comment:
In [changeset:"f64fd47a7627ed6ffe2df2a32ded6ee528a784eb" f64fd47]:
{{{
#!CommitTicketReference repository=""
revision="f64fd47a7627ed6ffe2df2a32ded6ee528a784eb"
Fixed #9602 -- Added AdminSite.get_model_admin().
This allows retrieving an admin class for the given model class without
using internal attributes.
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/9602#comment:7>
Comment (by GitHub <noreply@…>):
In [changeset:"2584783f46922bcb456ceb9700a3726314df65d3" 2584783]:
{{{
#!CommitTicketReference repository=""
revision="2584783f46922bcb456ceb9700a3726314df65d3"
Refs #9602 -- Moved AlreadyRegistered/NotRegistered exceptions to
django.contrib.admin.exceptions.
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/9602#comment:8>