#24185: Inline object in TabularInline.get_readonly_fields
-------------------------------+--------------------
Reporter: zachborboa | Owner: nobody
Type: Uncategorized | Status: new
Component: contrib.admin | Version: master
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------+--------------------
The `TabularInline.get_readonly_fields` method should be able to
programmatically determine the fields that will be displayed as read-only
based on the inline object passed as the keyword argument `instance_obj`.
{{{#!python
ModelAdmin.get_readonly_fields(request, obj=None)
}}}
`obj` is not the inline object, it's the parent. Ideally, both the parent
and the inline object are available:
{{{#!python
ModelAdmin.get_readonly_fields(request, obj=None, instance_obj=None)
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/24185>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/053.adea6ca1a46902c8104942f7b44a9736%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.