Opened 11 years ago

Closed 11 years ago

#6983 closed (fixed)

error class in edit_inline objects has quotes escaped

Reported by: bbolli <me+django@…> Owned by: nobody
Component: contrib.admin Version: master
Severity: Keywords: auto-escape nfa-fixed
Cc: Triage Stage: Fixed on a branch
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


When missing to enter a required field in inline related models, the top of the forms says correctly to "fix the error below" (or similar; I'm running on a Swiss German system), but below, no errors are displayed. This is because of an auto-escaping bug in admin/views/ See the patch for a possible fix.

Attachments (2) (432 bytes) - added by bbolli <me+django@…> 11 years ago.
Auto-escaping patch
6893.diff (585 bytes) - added by dan 11 years ago.
patch to fix quoting of added classes in inline edit in oldforms-admin

Download all attachments as: .zip

Change History (7)

Changed 11 years ago by bbolli <me+django@…>

Attachment: added

Auto-escaping patch

comment:1 Changed 11 years ago by bbolli <me+django@…>

Sorry, the patch is not relative to the Django root. Please apply the patch in the directory django/django/contrib/admin/views. Thanks.

comment:2 Changed 11 years ago by Marc Fargas

Triage Stage: UnreviewedAccepted

Note that this happens with edit_inline_tabular. I'm not sure this will be fixed as there's a strong effort to get newforms-admin in trunk ASAP.

Changed 11 years ago by dan

Attachment: 6893.diff added

patch to fix quoting of added classes in inline edit in oldforms-admin

comment:3 Changed 11 years ago by dan

hm, as of r7823, this bug still occurred both with STACKED and TABULAR inline editing- and the patch, if applied to contrib/admin/views/, as i assume the intention of the submitter it seems to work alright.

I've re-rolled the patch in the project root and attached it.

comment:4 Changed 11 years ago by Karen Tracey <kmtracey@…>

Keywords: nfa-fixed added
Triage Stage: AcceptedFixed on a branch

Note this appears to be an old admin problem only; I cannot recreate on newforms-admin. If I leave out required field(s) and try to save I see the appropriate error(s) on the field(s) that fail validation. The overall error at the top is missing, but that is a different problem with its own ticket (#5628). I don't know that it is worth fixing for old admin at this point.

comment:5 Changed 11 years ago by Brian Rosner

Resolution: fixed
Status: newclosed

This is no longer a problem since the merge of newforms-admin in [7967].

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