Opened 16 years ago

Closed 16 years ago

Last modified 12 years ago

#8341 closed Uncategorized (fixed)

InlineModelAdmin is missing `can_delete` and `can_order`

Reported by: ciantic@… Owned by: nobody
Component: contrib.admin Version: dev
Severity: Normal Keywords:
Cc: dev@… Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

InlineModelAdmin causes one to override whole function (get_formset) because it is missing, can_delete and can_order from the inlineformset_factory call.

P.S. Not related to this patch: Also there should be ability to give different form for change_view and add_view without such a big overriding.

Attachments (2)

options.py (966 bytes ) - added by ciantic@… 16 years ago.
Addition of can_delete and can_order
options.diff (966 bytes ) - added by ciantic@… 16 years ago.
options.py (Is this correct diff file syntax?)

Download all attachments as: .zip

Change History (6)

by ciantic@…, 16 years ago

Attachment: options.py added

Addition of can_delete and can_order

by ciantic@…, 16 years ago

Attachment: options.diff added

options.py (Is this correct diff file syntax?)

comment:1 by Brian Rosner, 16 years ago

Triage Stage: UnreviewedAccepted

I have been meaning to add this in, but would rather do it in a subclass fashion to help prevent a million options at class-level. Some options there make sense, but more some more very formset specific bits need to be done by subclassing and providing your own kwargs to the factory function. Also your P.S, first, has nothing to do with this ticket and, two, you don't need to do "such big overriding" as the documentation clearly states you can use a form option on the ModelAdmin and InlineModelAdmin. See http://www.djangoproject.com/documentation/admin/#form

comment:2 by Brian Rosner, 16 years ago

Resolution: fixed
Status: newclosed

(In [8396]) Fixed #8341 -- Allow simpler subclassing of ModelAdmin and InlineModelAdmin when overriding get_form and get_formset and needing to pass keyword argument on to the factory functions. Thanks ciantic for the report.

comment:3 by Jacob, 13 years ago

milestone: 1.0

Milestone 1.0 deleted

comment:4 by Brillgen Developers, 12 years ago

Cc: dev@… added
Easy pickings: unset
Severity: Normal
Type: Uncategorized
UI/UX: unset
Note: See TracTickets for help on using tickets.
Back to Top