Opened 15 years ago

Closed 15 years ago

Last modified 15 years ago

#11709 closed (fixed)

Admin Inline with Exclude fails if two fkeys to same parent are present, despite fk_name being used

Reported by: yishaibeeri Owned by: Brian Rosner
Component: contrib.admin Version: 1.1
Severity: Keywords:
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

[ quick and dirty bug post (appears to be a small localized one); will try to add patch and tests in a short while ]

In validate_inline(), the check for excluded fkey neglects to pass the cls.fk_name arg to _get_foreign_key (line 172 in the current trunk revision) - thus the fk_name parameter given in the Inline is ignored and _get_foreign_key finds multiple fkeys to same parent - raising an exception.

Change History (4)

comment:1 by Brian Rosner, 15 years ago

Triage Stage: UnreviewedAccepted

comment:2 by Brian Rosner, 15 years ago

Owner: changed from nobody to Brian Rosner
Status: newassigned

comment:3 by Brian Rosner, 15 years ago

Resolution: fixed
Status: assignedclosed

(In [11630]) Fixed #11709 — Pass inline fk_name attribute when grabbing foreign key to test for exclusion. Thanks yishaibeeri for the report.

comment:4 by Brian Rosner, 15 years ago

(In [11632]) [1.1.X] Fixed #11709 — Pass inline fk_name attribute when grabbing foreign key to test for exclusion. Thanks yishaibeeri for the report.

Backport of [11630] from trunk

Note: See TracTickets for help on using tickets.
Back to Top