Opened 13 years ago

Closed 13 years ago

Last modified 12 years ago

#829 closed defect (duplicate)

__repr__ overloaded for short_descriptions in admin interface

Reported by: aaronsw Owned by: Adrian Holovaty
Component: contrib.admin Version:
Severity: normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


The admin interface abuses repr to get its short_descriptions for listing objects. Instead, it should have a new function (perhaps short_description or something like that) to generate these things. Then, perhaps by default, repr can be '<'+classname+': '+short_description+'>' which is much more appropriate for the REPL situations in which repr is traditionally used.

If you have to use a special function, perhaps it could be str.

Change History (1)

comment:1 Changed 13 years ago by Tom Tobin <korpios@…>

Resolution: duplicate
Status: newclosed

Duplicate of #710.

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