#16762: Inline delete field
---------------------------------------+---------------------------------
Reporter: rodrigo@… | Owner: nobody
Type: Bug | Status: new
Milestone: | Component: contrib.admin
Version: 1.3 | Severity: Release blocker
Keywords: admin inline delete field | Triage Stage: Unreviewed
Has patch: 0 | Easy pickings: 0
UI/UX: 0 |
---------------------------------------+---------------------------------
Since '''StackedInline''' and '''ModularInline''' are inherited from
'''ModelAdmin''', they have also their variables and methods, but when
overriding the '''has_delete_permission''' method, it doesn't seem to
affect any how even writing something like:
{{{
class CompartilhamentoPorSetorInline(admin.TabularInline):
model = CompartilhamentoPorSetor
verbose_name = 'Compartilhamento por Setor'
verbose_name_plural = 'Compartilhamento por Setores'
extra = 1
def has_delete_permission(self, request, obj=None): # THIS! The
'delete' field on the admin form is still able.
return False
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/16762>
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 post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en.